From 7a7efba872400a51460505771d8f49d26f22e129 Mon Sep 17 00:00:00 2001 From: smutel Date: Tue, 17 May 2022 08:13:35 +0000 Subject: [PATCH] ci: Autogeneration of go-netbox library --- ...ts_circuit_terminations_list_parameters.go | 341 + .../circuits_circuit_types_list_parameters.go | 403 + .../circuits_circuits_list_parameters.go | 465 + ...cuits_provider_networks_list_parameters.go | 341 + .../circuits_providers_list_parameters.go | 124 + .../dcim/dcim_cables_list_parameters.go | 186 + .../dcim/dcim_device_roles_list_parameters.go | 403 + .../dcim/dcim_device_types_list_parameters.go | 62 + .../dcim/dcim_devices_list_parameters.go | 248 + .../dcim/dcim_interfaces_list_parameters.go | 1054 + .../dcim/dcim_locations_list_parameters.go | 434 + .../dcim_manufacturers_list_parameters.go | 186 + .../dcim/dcim_platforms_list_parameters.go | 62 + .../dcim/dcim_power_panels_list_parameters.go | 124 + .../dcim_rack_reservations_list_parameters.go | 341 + .../dcim/dcim_rack_roles_list_parameters.go | 403 + .../client/dcim/dcim_racks_list_parameters.go | 124 + .../dcim/dcim_regions_list_parameters.go | 186 + .../dcim/dcim_site_groups_list_parameters.go | 186 + .../client/dcim/dcim_sites_list_parameters.go | 527 + .../extras_config_contexts_list_parameters.go | 62 + .../extras_custom_fields_list_parameters.go | 341 + ...extras_export_templates_list_parameters.go | 341 + .../extras/extras_tags_list_parameters.go | 341 + .../ipam/ipam_aggregates_list_parameters.go | 341 + .../ipam/ipam_asns_bulk_delete_parameters.go | 141 + .../ipam/ipam_asns_bulk_delete_responses.go | 68 + ...pam_asns_bulk_partial_update_parameters.go | 163 + ...ipam_asns_bulk_partial_update_responses.go | 82 + .../ipam/ipam_asns_bulk_update_parameters.go | 163 + .../ipam/ipam_asns_bulk_update_responses.go | 82 + .../ipam/ipam_asns_create_parameters.go | 163 + .../client/ipam/ipam_asns_create_responses.go | 82 + .../ipam/ipam_asns_delete_parameters.go | 165 + .../client/ipam/ipam_asns_delete_responses.go | 68 + .../client/ipam/ipam_asns_list_parameters.go | 1637 + .../client/ipam/ipam_asns_list_responses.go | 247 + .../ipam_asns_partial_update_parameters.go | 186 + .../ipam_asns_partial_update_responses.go | 82 + .../client/ipam/ipam_asns_read_parameters.go | 165 + .../client/ipam/ipam_asns_read_responses.go | 82 + .../ipam/ipam_asns_update_parameters.go | 186 + .../client/ipam/ipam_asns_update_responses.go | 82 + netbox/client/ipam/ipam_client.go | 1543 +- ...roup_assignments_bulk_delete_parameters.go | 141 + ...group_assignments_bulk_delete_responses.go | 68 + ...ignments_bulk_partial_update_parameters.go | 163 + ...signments_bulk_partial_update_responses.go | 82 + ...roup_assignments_bulk_update_parameters.go | 163 + ...group_assignments_bulk_update_responses.go | 82 + ...hrp_group_assignments_create_parameters.go | 163 + ...fhrp_group_assignments_create_responses.go | 82 + ...hrp_group_assignments_delete_parameters.go | 165 + ...fhrp_group_assignments_delete_responses.go | 68 + ..._fhrp_group_assignments_list_parameters.go | 1079 + ...m_fhrp_group_assignments_list_responses.go | 247 + ...p_assignments_partial_update_parameters.go | 186 + ...up_assignments_partial_update_responses.go | 82 + ..._fhrp_group_assignments_read_parameters.go | 165 + ...m_fhrp_group_assignments_read_responses.go | 82 + ...hrp_group_assignments_update_parameters.go | 186 + ...fhrp_group_assignments_update_responses.go | 82 + ...ipam_fhrp_groups_bulk_delete_parameters.go | 141 + .../ipam_fhrp_groups_bulk_delete_responses.go | 68 + ...p_groups_bulk_partial_update_parameters.go | 163 + ...rp_groups_bulk_partial_update_responses.go | 82 + ...ipam_fhrp_groups_bulk_update_parameters.go | 163 + .../ipam_fhrp_groups_bulk_update_responses.go | 82 + .../ipam_fhrp_groups_create_parameters.go | 163 + .../ipam/ipam_fhrp_groups_create_responses.go | 82 + .../ipam_fhrp_groups_delete_parameters.go | 165 + .../ipam/ipam_fhrp_groups_delete_responses.go | 68 + .../ipam/ipam_fhrp_groups_list_parameters.go | 1358 + .../ipam/ipam_fhrp_groups_list_responses.go | 247 + ...m_fhrp_groups_partial_update_parameters.go | 186 + ...am_fhrp_groups_partial_update_responses.go | 82 + .../ipam/ipam_fhrp_groups_read_parameters.go | 165 + .../ipam/ipam_fhrp_groups_read_responses.go | 82 + .../ipam_fhrp_groups_update_parameters.go | 186 + .../ipam/ipam_fhrp_groups_update_responses.go | 82 + ..._ranges_available_ips_create_parameters.go | 8 +- ...p_ranges_available_ips_create_responses.go | 4 +- ...p_ranges_available_ips_list_parameters.go} | 74 +- ...ip_ranges_available_ips_list_responses.go} | 28 +- .../ipam/ipam_ip_ranges_list_parameters.go | 341 + ...refixes_available_ips_create_parameters.go | 8 +- ...prefixes_available_ips_create_responses.go | 4 +- ...prefixes_available_ips_list_parameters.go} | 74 +- ..._prefixes_available_ips_list_responses.go} | 28 +- ...xes_available_prefixes_create_responses.go | 8 +- ...xes_available_prefixes_list_parameters.go} | 72 +- ...ixes_available_prefixes_list_responses.go} | 28 +- .../ipam/ipam_prefixes_list_parameters.go | 496 + .../client/ipam/ipam_rirs_list_parameters.go | 62 + .../client/ipam/ipam_roles_list_parameters.go | 403 + .../ipam_route_targets_list_parameters.go | 341 + .../ipam/ipam_services_list_parameters.go | 341 + .../ipam/ipam_vlan_groups_list_parameters.go | 62 + .../client/ipam/ipam_vlans_list_parameters.go | 341 + .../client/ipam/ipam_vrfs_list_parameters.go | 341 + netbox/client/net_box_api_client.go | 5 + netbox/client/tenancy/tenancy_client.go | 1476 + ...tact_assignments_bulk_delete_parameters.go | 141 + ...ntact_assignments_bulk_delete_responses.go | 68 + ...ignments_bulk_partial_update_parameters.go | 163 + ...signments_bulk_partial_update_responses.go | 82 + ...tact_assignments_bulk_update_parameters.go | 163 + ...ntact_assignments_bulk_update_responses.go | 82 + ...y_contact_assignments_create_parameters.go | 163 + ...cy_contact_assignments_create_responses.go | 82 + ...y_contact_assignments_delete_parameters.go | 165 + ...cy_contact_assignments_delete_responses.go | 68 + ...ncy_contact_assignments_list_parameters.go | 1141 + ...ancy_contact_assignments_list_responses.go | 247 + ...t_assignments_partial_update_parameters.go | 186 + ...ct_assignments_partial_update_responses.go | 82 + ...ncy_contact_assignments_read_parameters.go | 165 + ...ancy_contact_assignments_read_responses.go | 82 + ...y_contact_assignments_update_parameters.go | 186 + ...cy_contact_assignments_update_responses.go | 82 + ...y_contact_groups_bulk_delete_parameters.go | 141 + ...cy_contact_groups_bulk_delete_responses.go | 68 + ...t_groups_bulk_partial_update_parameters.go | 163 + ...ct_groups_bulk_partial_update_responses.go | 82 + ...y_contact_groups_bulk_update_parameters.go | 163 + ...cy_contact_groups_bulk_update_responses.go | 82 + ...enancy_contact_groups_create_parameters.go | 163 + ...tenancy_contact_groups_create_responses.go | 82 + ...enancy_contact_groups_delete_parameters.go | 165 + ...tenancy_contact_groups_delete_responses.go | 68 + .../tenancy_contact_groups_list_parameters.go | 1823 + .../tenancy_contact_groups_list_responses.go | 247 + ...ontact_groups_partial_update_parameters.go | 186 + ...contact_groups_partial_update_responses.go | 82 + .../tenancy_contact_groups_read_parameters.go | 165 + .../tenancy_contact_groups_read_responses.go | 82 + ...enancy_contact_groups_update_parameters.go | 186 + ...tenancy_contact_groups_update_responses.go | 82 + ...cy_contact_roles_bulk_delete_parameters.go | 141 + ...ncy_contact_roles_bulk_delete_responses.go | 68 + ...ct_roles_bulk_partial_update_parameters.go | 163 + ...act_roles_bulk_partial_update_responses.go | 82 + ...cy_contact_roles_bulk_update_parameters.go | 163 + ...ncy_contact_roles_bulk_update_responses.go | 82 + ...tenancy_contact_roles_create_parameters.go | 163 + .../tenancy_contact_roles_create_responses.go | 82 + ...tenancy_contact_roles_delete_parameters.go | 165 + .../tenancy_contact_roles_delete_responses.go | 68 + .../tenancy_contact_roles_list_parameters.go | 1699 + .../tenancy_contact_roles_list_responses.go | 247 + ...contact_roles_partial_update_parameters.go | 186 + ..._contact_roles_partial_update_responses.go | 82 + .../tenancy_contact_roles_read_parameters.go | 165 + .../tenancy_contact_roles_read_responses.go | 82 + ...tenancy_contact_roles_update_parameters.go | 186 + .../tenancy_contact_roles_update_responses.go | 82 + ...tenancy_contacts_bulk_delete_parameters.go | 141 + .../tenancy_contacts_bulk_delete_responses.go | 68 + ...contacts_bulk_partial_update_parameters.go | 163 + ..._contacts_bulk_partial_update_responses.go | 82 + ...tenancy_contacts_bulk_update_parameters.go | 163 + .../tenancy_contacts_bulk_update_responses.go | 82 + .../tenancy_contacts_create_parameters.go | 163 + .../tenancy_contacts_create_responses.go | 82 + .../tenancy_contacts_delete_parameters.go | 165 + .../tenancy_contacts_delete_responses.go | 68 + .../tenancy_contacts_list_parameters.go | 2505 + .../tenancy_contacts_list_responses.go | 247 + ...ancy_contacts_partial_update_parameters.go | 186 + ...nancy_contacts_partial_update_responses.go | 82 + .../tenancy_contacts_read_parameters.go | 165 + .../tenancy_contacts_read_responses.go | 82 + .../tenancy_contacts_update_parameters.go | 186 + .../tenancy_contacts_update_responses.go | 82 + .../tenancy_tenant_groups_list_parameters.go | 62 + .../tenancy_tenants_list_parameters.go | 465 + .../users_permissions_list_parameters.go | 341 + .../users/users_tokens_list_parameters.go | 341 + ...lization_cluster_groups_list_parameters.go | 186 + ...alization_cluster_types_list_parameters.go | 62 + ...virtualization_clusters_list_parameters.go | 124 + ...rtualization_interfaces_list_parameters.go | 403 + ...zation_virtual_machines_list_parameters.go | 124 + netbox/client/wireless/wireless_client.go | 1161 + ...eless_lan_groups_bulk_delete_parameters.go | 141 + ...reless_lan_groups_bulk_delete_responses.go | 68 + ...n_groups_bulk_partial_update_parameters.go | 163 + ...an_groups_bulk_partial_update_responses.go | 82 + ...eless_lan_groups_bulk_update_parameters.go | 163 + ...reless_lan_groups_bulk_update_responses.go | 82 + ...s_wireless_lan_groups_create_parameters.go | 163 + ...ss_wireless_lan_groups_create_responses.go | 82 + ...s_wireless_lan_groups_delete_parameters.go | 165 + ...ss_wireless_lan_groups_delete_responses.go | 68 + ...ess_wireless_lan_groups_list_parameters.go | 1823 + ...less_wireless_lan_groups_list_responses.go | 247 + ...ss_lan_groups_partial_update_parameters.go | 186 + ...ess_lan_groups_partial_update_responses.go | 82 + ...ess_wireless_lan_groups_read_parameters.go | 165 + ...less_wireless_lan_groups_read_responses.go | 82 + ...s_wireless_lan_groups_update_parameters.go | 186 + ...ss_wireless_lan_groups_update_responses.go | 82 + ...ss_wireless_lans_bulk_delete_parameters.go | 141 + ...ess_wireless_lans_bulk_delete_responses.go | 68 + ...ess_lans_bulk_partial_update_parameters.go | 163 + ...less_lans_bulk_partial_update_responses.go | 82 + ...ss_wireless_lans_bulk_update_parameters.go | 163 + ...ess_wireless_lans_bulk_update_responses.go | 82 + ...ireless_wireless_lans_create_parameters.go | 163 + ...wireless_wireless_lans_create_responses.go | 82 + ...ireless_wireless_lans_delete_parameters.go | 165 + ...wireless_wireless_lans_delete_responses.go | 68 + .../wireless_wireless_lans_list_parameters.go | 2009 + .../wireless_wireless_lans_list_responses.go | 247 + ...wireless_lans_partial_update_parameters.go | 186 + ..._wireless_lans_partial_update_responses.go | 82 + .../wireless_wireless_lans_read_parameters.go | 165 + .../wireless_wireless_lans_read_responses.go | 82 + ...ireless_wireless_lans_update_parameters.go | 186 + ...wireless_wireless_lans_update_responses.go | 82 + ...s_wireless_links_bulk_delete_parameters.go | 141 + ...ss_wireless_links_bulk_delete_responses.go | 68 + ...ss_links_bulk_partial_update_parameters.go | 163 + ...ess_links_bulk_partial_update_responses.go | 82 + ...s_wireless_links_bulk_update_parameters.go | 163 + ...ss_wireless_links_bulk_update_responses.go | 82 + ...reless_wireless_links_create_parameters.go | 163 + ...ireless_wireless_links_create_responses.go | 82 + ...reless_wireless_links_delete_parameters.go | 165 + ...ireless_wireless_links_delete_responses.go | 68 + ...wireless_wireless_links_list_parameters.go | 2257 + .../wireless_wireless_links_list_responses.go | 247 + ...ireless_links_partial_update_parameters.go | 186 + ...wireless_links_partial_update_responses.go | 82 + ...wireless_wireless_links_read_parameters.go | 165 + .../wireless_wireless_links_read_responses.go | 82 + ...reless_wireless_links_update_parameters.go | 186 + ...ireless_wireless_links_update_responses.go | 82 + netbox/models/a_s_n.go | 400 + netbox/models/cable.go | 114 + netbox/models/circuit_termination.go | 130 +- netbox/models/circuit_type.go | 58 + netbox/models/cluster_group.go | 58 + netbox/models/cluster_type.go | 58 + netbox/models/console_port.go | 68 +- netbox/models/console_server_port.go | 68 +- netbox/models/contact.go | 432 + netbox/models/contact_assignment.go | 563 + netbox/models/contact_group.go | 430 + netbox/models/contact_role.go | 350 + netbox/models/custom_field.go | 101 +- netbox/models/custom_link.go | 68 + netbox/models/device.go | 228 +- netbox/models/device_role.go | 58 + netbox/models/device_type.go | 213 + netbox/models/device_with_config_context.go | 228 +- netbox/models/export_template.go | 68 + netbox/models/f_h_r_p_group.go | 518 + netbox/models/f_h_r_p_group_assignment.go | 342 + netbox/models/front_port.go | 110 +- netbox/models/front_port_template.go | 44 +- netbox/models/image_attachment.go | 34 + netbox/models/interface.go | 1891 +- netbox/models/interface_template.go | 42 +- netbox/models/ip_address.go | 4 +- netbox/models/location.go | 104 + netbox/models/manufacturer.go | 58 + netbox/models/nested_a_s_n.go | 171 + netbox/models/nested_contact.go | 169 + netbox/models/nested_contact_group.go | 235 + netbox/models/nested_contact_role.go | 201 + netbox/models/nested_f_h_r_p_group.go | 237 + netbox/models/nested_wireless_l_a_n.go | 169 + netbox/models/nested_wireless_l_a_n_group.go | 235 + netbox/models/nested_wireless_link.go | 162 + netbox/models/platform.go | 58 + netbox/models/power_feed.go | 68 +- netbox/models/power_outlet.go | 88 +- netbox/models/power_outlet_template.go | 20 +- netbox/models/power_panel.go | 68 + netbox/models/power_port.go | 82 +- netbox/models/power_port_template.go | 14 +- netbox/models/r_i_r.go | 58 + netbox/models/rack.go | 2 - netbox/models/rack_reservation.go | 34 + netbox/models/rack_role.go | 58 + netbox/models/rear_port.go | 110 +- netbox/models/rear_port_template.go | 44 +- netbox/models/region.go | 58 + netbox/models/role.go | 58 + netbox/models/service.go | 14 +- netbox/models/site.go | 62 + netbox/models/site_group.go | 58 + netbox/models/tag.go | 68 + netbox/models/tenant_group.go | 58 + netbox/models/v_l_a_n_group.go | 71 +- netbox/models/virtual_chassis.go | 68 + netbox/models/vm_interface.go | 63 + netbox/models/webhook.go | 73 + netbox/models/wireless_l_a_n.go | 827 + netbox/models/wireless_l_a_n_group.go | 430 + netbox/models/wireless_link.go | 1019 + netbox/models/writable_a_s_n.go | 357 + netbox/models/writable_available_ip.go | 125 + netbox/models/writable_cable.go | 71 + netbox/models/writable_circuit_termination.go | 114 +- netbox/models/writable_cluster.go | 32 +- netbox/models/writable_console_port.go | 68 +- netbox/models/writable_console_server_port.go | 68 +- netbox/models/writable_contact.go | 403 + netbox/models/writable_contact_assignment.go | 360 + netbox/models/writable_contact_group.go | 401 + netbox/models/writable_custom_field.go | 91 +- netbox/models/writable_device_type.go | 62 + .../writable_device_with_config_context.go | 129 +- .../writable_f_h_r_p_group_assignment.go | 311 + netbox/models/writable_front_port.go | 86 +- netbox/models/writable_front_port_template.go | 22 +- netbox/models/writable_interface.go | 851 +- netbox/models/writable_interface_template.go | 23 +- netbox/models/writable_ip_address.go | 4 +- netbox/models/writable_location.go | 61 + netbox/models/writable_platform.go | 58 + netbox/models/writable_power_feed.go | 68 +- netbox/models/writable_power_outlet.go | 78 +- .../models/writable_power_outlet_template.go | 10 +- netbox/models/writable_power_panel.go | 68 + netbox/models/writable_power_port.go | 75 +- netbox/models/writable_power_port_template.go | 7 +- netbox/models/writable_rack.go | 18 +- netbox/models/writable_rack_reservation.go | 34 + netbox/models/writable_rear_port.go | 86 +- netbox/models/writable_rear_port_template.go | 22 +- netbox/models/writable_region.go | 58 + netbox/models/writable_service.go | 7 +- netbox/models/writable_site.go | 20 + netbox/models/writable_site_group.go | 58 + netbox/models/writable_tenant_group.go | 58 + netbox/models/writable_v_l_a_n.go | 16 +- netbox/models/writable_virtual_chassis.go | 68 + netbox/models/writable_vm_interface.go | 20 + netbox/models/writable_wireless_l_a_n.go | 454 + .../models/writable_wireless_l_a_n_group.go | 401 + netbox/models/writable_wireless_link.go | 528 + ...gger-v3.0.11.json => swagger-v3.1.11.json} | 30356 ++++--- swagger/swagger-v3.1.11.json | 65699 ++++++++++++++++ 346 files changed, 159482 insertions(+), 10858 deletions(-) create mode 100644 netbox/client/ipam/ipam_asns_bulk_delete_parameters.go create mode 100644 netbox/client/ipam/ipam_asns_bulk_delete_responses.go create mode 100644 netbox/client/ipam/ipam_asns_bulk_partial_update_parameters.go create mode 100644 netbox/client/ipam/ipam_asns_bulk_partial_update_responses.go create mode 100644 netbox/client/ipam/ipam_asns_bulk_update_parameters.go create mode 100644 netbox/client/ipam/ipam_asns_bulk_update_responses.go create mode 100644 netbox/client/ipam/ipam_asns_create_parameters.go create mode 100644 netbox/client/ipam/ipam_asns_create_responses.go create mode 100644 netbox/client/ipam/ipam_asns_delete_parameters.go create mode 100644 netbox/client/ipam/ipam_asns_delete_responses.go create mode 100644 netbox/client/ipam/ipam_asns_list_parameters.go create mode 100644 netbox/client/ipam/ipam_asns_list_responses.go create mode 100644 netbox/client/ipam/ipam_asns_partial_update_parameters.go create mode 100644 netbox/client/ipam/ipam_asns_partial_update_responses.go create mode 100644 netbox/client/ipam/ipam_asns_read_parameters.go create mode 100644 netbox/client/ipam/ipam_asns_read_responses.go create mode 100644 netbox/client/ipam/ipam_asns_update_parameters.go create mode 100644 netbox/client/ipam/ipam_asns_update_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_bulk_delete_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_bulk_delete_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_bulk_partial_update_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_bulk_partial_update_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_bulk_update_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_bulk_update_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_create_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_create_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_delete_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_delete_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_list_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_list_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_partial_update_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_partial_update_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_read_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_read_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_update_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_group_assignments_update_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_bulk_delete_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_bulk_delete_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_bulk_partial_update_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_bulk_partial_update_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_bulk_update_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_bulk_update_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_create_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_create_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_delete_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_delete_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_list_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_list_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_partial_update_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_partial_update_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_read_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_read_responses.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_update_parameters.go create mode 100644 netbox/client/ipam/ipam_fhrp_groups_update_responses.go rename netbox/client/ipam/{ipam_ip_ranges_available_ips_read_parameters.go => ipam_ip_ranges_available_ips_list_parameters.go} (56%) rename netbox/client/ipam/{ipam_ip_ranges_available_ips_read_responses.go => ipam_ip_ranges_available_ips_list_responses.go} (69%) rename netbox/client/ipam/{ipam_prefixes_available_ips_read_parameters.go => ipam_prefixes_available_ips_list_parameters.go} (56%) rename netbox/client/ipam/{ipam_prefixes_available_ips_read_responses.go => ipam_prefixes_available_ips_list_responses.go} (69%) rename netbox/client/ipam/{ipam_prefixes_available_prefixes_read_parameters.go => ipam_prefixes_available_prefixes_list_parameters.go} (55%) rename netbox/client/ipam/{ipam_prefixes_available_prefixes_read_responses.go => ipam_prefixes_available_prefixes_list_responses.go} (68%) create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_bulk_delete_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_bulk_delete_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_bulk_partial_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_bulk_partial_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_bulk_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_bulk_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_create_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_create_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_delete_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_delete_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_list_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_list_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_partial_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_partial_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_read_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_read_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_assignments_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_bulk_delete_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_bulk_delete_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_bulk_partial_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_bulk_partial_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_bulk_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_bulk_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_create_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_create_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_delete_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_delete_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_list_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_list_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_partial_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_partial_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_read_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_read_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_groups_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_bulk_delete_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_bulk_delete_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_bulk_partial_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_bulk_partial_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_bulk_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_bulk_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_create_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_create_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_delete_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_delete_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_list_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_list_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_partial_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_partial_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_read_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_read_responses.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contact_roles_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contacts_bulk_delete_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contacts_bulk_delete_responses.go create mode 100644 netbox/client/tenancy/tenancy_contacts_bulk_partial_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contacts_bulk_partial_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contacts_bulk_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contacts_bulk_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contacts_create_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contacts_create_responses.go create mode 100644 netbox/client/tenancy/tenancy_contacts_delete_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contacts_delete_responses.go create mode 100644 netbox/client/tenancy/tenancy_contacts_list_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contacts_list_responses.go create mode 100644 netbox/client/tenancy/tenancy_contacts_partial_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contacts_partial_update_responses.go create mode 100644 netbox/client/tenancy/tenancy_contacts_read_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contacts_read_responses.go create mode 100644 netbox/client/tenancy/tenancy_contacts_update_parameters.go create mode 100644 netbox/client/tenancy/tenancy_contacts_update_responses.go create mode 100644 netbox/client/wireless/wireless_client.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_bulk_delete_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_bulk_delete_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_bulk_partial_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_bulk_partial_update_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_bulk_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_bulk_update_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_create_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_create_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_delete_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_delete_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_list_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_list_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_partial_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_partial_update_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_read_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_read_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lan_groups_update_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_bulk_delete_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_bulk_delete_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_bulk_partial_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_bulk_partial_update_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_bulk_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_bulk_update_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_create_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_create_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_delete_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_delete_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_list_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_list_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_partial_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_partial_update_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_read_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_read_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_lans_update_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_links_bulk_delete_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_links_bulk_delete_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_links_bulk_partial_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_links_bulk_partial_update_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_links_bulk_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_links_bulk_update_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_links_create_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_links_create_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_links_delete_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_links_delete_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_links_list_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_links_list_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_links_partial_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_links_partial_update_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_links_read_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_links_read_responses.go create mode 100644 netbox/client/wireless/wireless_wireless_links_update_parameters.go create mode 100644 netbox/client/wireless/wireless_wireless_links_update_responses.go create mode 100644 netbox/models/a_s_n.go create mode 100644 netbox/models/contact.go create mode 100644 netbox/models/contact_assignment.go create mode 100644 netbox/models/contact_group.go create mode 100644 netbox/models/contact_role.go create mode 100644 netbox/models/f_h_r_p_group.go create mode 100644 netbox/models/f_h_r_p_group_assignment.go create mode 100644 netbox/models/nested_a_s_n.go create mode 100644 netbox/models/nested_contact.go create mode 100644 netbox/models/nested_contact_group.go create mode 100644 netbox/models/nested_contact_role.go create mode 100644 netbox/models/nested_f_h_r_p_group.go create mode 100644 netbox/models/nested_wireless_l_a_n.go create mode 100644 netbox/models/nested_wireless_l_a_n_group.go create mode 100644 netbox/models/nested_wireless_link.go create mode 100644 netbox/models/wireless_l_a_n.go create mode 100644 netbox/models/wireless_l_a_n_group.go create mode 100644 netbox/models/wireless_link.go create mode 100644 netbox/models/writable_a_s_n.go create mode 100644 netbox/models/writable_available_ip.go create mode 100644 netbox/models/writable_contact.go create mode 100644 netbox/models/writable_contact_assignment.go create mode 100644 netbox/models/writable_contact_group.go create mode 100644 netbox/models/writable_f_h_r_p_group_assignment.go create mode 100644 netbox/models/writable_wireless_l_a_n.go create mode 100644 netbox/models/writable_wireless_l_a_n_group.go create mode 100644 netbox/models/writable_wireless_link.go rename netbox/{swagger-v3.0.11.json => swagger-v3.1.11.json} (83%) create mode 100644 swagger/swagger-v3.1.11.json diff --git a/netbox/client/circuits/circuits_circuit_terminations_list_parameters.go b/netbox/client/circuits/circuits_circuit_terminations_list_parameters.go index 2186514c..34ac9148 100644 --- a/netbox/client/circuits/circuits_circuit_terminations_list_parameters.go +++ b/netbox/client/circuits/circuits_circuit_terminations_list_parameters.go @@ -93,6 +93,39 @@ type CircuitsCircuitTerminationsListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // ID. ID *string @@ -347,6 +380,127 @@ func (o *CircuitsCircuitTerminationsListParams) SetCreatedLte(createdLte *string o.CreatedLte = createdLte } +// WithDescription adds the description to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) WithDescription(description *string) *CircuitsCircuitTerminationsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) WithDescriptionEmpty(descriptionEmpty *string) *CircuitsCircuitTerminationsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) WithDescriptionIc(descriptionIc *string) *CircuitsCircuitTerminationsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) WithDescriptionIe(descriptionIe *string) *CircuitsCircuitTerminationsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) WithDescriptionIew(descriptionIew *string) *CircuitsCircuitTerminationsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) WithDescriptionIsw(descriptionIsw *string) *CircuitsCircuitTerminationsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) WithDescriptionn(descriptionn *string) *CircuitsCircuitTerminationsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) WithDescriptionNic(descriptionNic *string) *CircuitsCircuitTerminationsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) WithDescriptionNie(descriptionNie *string) *CircuitsCircuitTerminationsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) WithDescriptionNiew(descriptionNiew *string) *CircuitsCircuitTerminationsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) WithDescriptionNisw(descriptionNisw *string) *CircuitsCircuitTerminationsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the circuits circuit terminations list params +func (o *CircuitsCircuitTerminationsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithID adds the id to the circuits circuit terminations list params func (o *CircuitsCircuitTerminationsListParams) WithID(id *string) *CircuitsCircuitTerminationsListParams { o.SetID(id) @@ -930,6 +1084,193 @@ func (o *CircuitsCircuitTerminationsListParams) WriteToRequest(r runtime.ClientR } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.ID != nil { // query param id diff --git a/netbox/client/circuits/circuits_circuit_types_list_parameters.go b/netbox/client/circuits/circuits_circuit_types_list_parameters.go index b845f256..00a3bd8d 100644 --- a/netbox/client/circuits/circuits_circuit_types_list_parameters.go +++ b/netbox/client/circuits/circuits_circuit_types_list_parameters.go @@ -84,6 +84,39 @@ type CircuitsCircuitTypesListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // ID. ID *string @@ -192,6 +225,12 @@ type CircuitsCircuitTypesListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -278,6 +317,127 @@ func (o *CircuitsCircuitTypesListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithDescription(description *string) *CircuitsCircuitTypesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithDescriptionEmpty(descriptionEmpty *string) *CircuitsCircuitTypesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithDescriptionIc(descriptionIc *string) *CircuitsCircuitTypesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithDescriptionIe(descriptionIe *string) *CircuitsCircuitTypesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithDescriptionIew(descriptionIew *string) *CircuitsCircuitTypesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithDescriptionIsw(descriptionIsw *string) *CircuitsCircuitTypesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithDescriptionn(descriptionn *string) *CircuitsCircuitTypesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithDescriptionNic(descriptionNic *string) *CircuitsCircuitTypesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithDescriptionNie(descriptionNie *string) *CircuitsCircuitTypesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithDescriptionNiew(descriptionNiew *string) *CircuitsCircuitTypesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithDescriptionNisw(descriptionNisw *string) *CircuitsCircuitTypesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithID adds the id to the circuits circuit types list params func (o *CircuitsCircuitTypesListParams) WithID(id *string) *CircuitsCircuitTypesListParams { o.SetID(id) @@ -652,6 +812,28 @@ func (o *CircuitsCircuitTypesListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithTag(tag *string) *CircuitsCircuitTypesListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) WithTagn(tagn *string) *CircuitsCircuitTypesListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the circuits circuit types list params +func (o *CircuitsCircuitTypesListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *CircuitsCircuitTypesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -711,6 +893,193 @@ func (o *CircuitsCircuitTypesListParams) WriteToRequest(r runtime.ClientRequest, } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.ID != nil { // query param id @@ -1289,6 +1658,40 @@ func (o *CircuitsCircuitTypesListParams) WriteToRequest(r runtime.ClientRequest, } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/circuits/circuits_circuits_list_parameters.go b/netbox/client/circuits/circuits_circuits_list_parameters.go index 427c4a24..5dc84340 100644 --- a/netbox/client/circuits/circuits_circuits_list_parameters.go +++ b/netbox/client/circuits/circuits_circuits_list_parameters.go @@ -126,6 +126,18 @@ type CircuitsCircuitsListParams struct { // CommitRaten. CommitRaten *string + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -135,6 +147,39 @@ type CircuitsCircuitsListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // ID. ID *string @@ -537,6 +582,50 @@ func (o *CircuitsCircuitsListParams) SetCommitRaten(commitRaten *string) { o.CommitRaten = commitRaten } +// WithContact adds the contact to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithContact(contact *string) *CircuitsCircuitsListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithContactn(contactn *string) *CircuitsCircuitsListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithContactRole(contactRole *string) *CircuitsCircuitsListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithContactRolen(contactRolen *string) *CircuitsCircuitsListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the circuits circuits list params func (o *CircuitsCircuitsListParams) WithCreated(created *string) *CircuitsCircuitsListParams { o.SetCreated(created) @@ -570,6 +659,127 @@ func (o *CircuitsCircuitsListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithDescription(description *string) *CircuitsCircuitsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithDescriptionEmpty(descriptionEmpty *string) *CircuitsCircuitsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithDescriptionIc(descriptionIc *string) *CircuitsCircuitsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithDescriptionIe(descriptionIe *string) *CircuitsCircuitsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithDescriptionIew(descriptionIew *string) *CircuitsCircuitsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithDescriptionIsw(descriptionIsw *string) *CircuitsCircuitsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithDescriptionn(descriptionn *string) *CircuitsCircuitsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithDescriptionNic(descriptionNic *string) *CircuitsCircuitsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithDescriptionNie(descriptionNie *string) *CircuitsCircuitsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithDescriptionNiew(descriptionNiew *string) *CircuitsCircuitsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the circuits circuits list params +func (o *CircuitsCircuitsListParams) WithDescriptionNisw(descriptionNisw *string) *CircuitsCircuitsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the circuits circuits list params +func (o *CircuitsCircuitsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithID adds the id to the circuits circuits list params func (o *CircuitsCircuitsListParams) WithID(id *string) *CircuitsCircuitsListParams { o.SetID(id) @@ -1439,6 +1649,74 @@ func (o *CircuitsCircuitsListParams) WriteToRequest(r runtime.ClientRequest, reg } } + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created @@ -1490,6 +1768,193 @@ func (o *CircuitsCircuitsListParams) WriteToRequest(r runtime.ClientRequest, reg } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.ID != nil { // query param id diff --git a/netbox/client/circuits/circuits_provider_networks_list_parameters.go b/netbox/client/circuits/circuits_provider_networks_list_parameters.go index 520f2b2c..3fc16ea8 100644 --- a/netbox/client/circuits/circuits_provider_networks_list_parameters.go +++ b/netbox/client/circuits/circuits_provider_networks_list_parameters.go @@ -84,6 +84,39 @@ type CircuitsProviderNetworksListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // ID. ID *string @@ -263,6 +296,127 @@ func (o *CircuitsProviderNetworksListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) WithDescription(description *string) *CircuitsProviderNetworksListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) WithDescriptionEmpty(descriptionEmpty *string) *CircuitsProviderNetworksListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) WithDescriptionIc(descriptionIc *string) *CircuitsProviderNetworksListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) WithDescriptionIe(descriptionIe *string) *CircuitsProviderNetworksListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) WithDescriptionIew(descriptionIew *string) *CircuitsProviderNetworksListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) WithDescriptionIsw(descriptionIsw *string) *CircuitsProviderNetworksListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) WithDescriptionn(descriptionn *string) *CircuitsProviderNetworksListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) WithDescriptionNic(descriptionNic *string) *CircuitsProviderNetworksListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) WithDescriptionNie(descriptionNie *string) *CircuitsProviderNetworksListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) WithDescriptionNiew(descriptionNiew *string) *CircuitsProviderNetworksListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) WithDescriptionNisw(descriptionNisw *string) *CircuitsProviderNetworksListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the circuits provider networks list params +func (o *CircuitsProviderNetworksListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithID adds the id to the circuits provider networks list params func (o *CircuitsProviderNetworksListParams) WithID(id *string) *CircuitsProviderNetworksListParams { o.SetID(id) @@ -641,6 +795,193 @@ func (o *CircuitsProviderNetworksListParams) WriteToRequest(r runtime.ClientRequ } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.ID != nil { // query param id diff --git a/netbox/client/circuits/circuits_providers_list_parameters.go b/netbox/client/circuits/circuits_providers_list_parameters.go index bc40499f..ee9f7c71 100644 --- a/netbox/client/circuits/circuits_providers_list_parameters.go +++ b/netbox/client/circuits/circuits_providers_list_parameters.go @@ -126,6 +126,18 @@ type CircuitsProvidersListParams struct { // Asnn. Asnn *string + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -525,6 +537,50 @@ func (o *CircuitsProvidersListParams) SetAsnn(asnn *string) { o.Asnn = asnn } +// WithContact adds the contact to the circuits providers list params +func (o *CircuitsProvidersListParams) WithContact(contact *string) *CircuitsProvidersListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the circuits providers list params +func (o *CircuitsProvidersListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the circuits providers list params +func (o *CircuitsProvidersListParams) WithContactn(contactn *string) *CircuitsProvidersListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the circuits providers list params +func (o *CircuitsProvidersListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the circuits providers list params +func (o *CircuitsProvidersListParams) WithContactRole(contactRole *string) *CircuitsProvidersListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the circuits providers list params +func (o *CircuitsProvidersListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the circuits providers list params +func (o *CircuitsProvidersListParams) WithContactRolen(contactRolen *string) *CircuitsProvidersListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the circuits providers list params +func (o *CircuitsProvidersListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the circuits providers list params func (o *CircuitsProvidersListParams) WithCreated(created *string) *CircuitsProvidersListParams { o.SetCreated(created) @@ -1383,6 +1439,74 @@ func (o *CircuitsProvidersListParams) WriteToRequest(r runtime.ClientRequest, re } } + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created diff --git a/netbox/client/dcim/dcim_cables_list_parameters.go b/netbox/client/dcim/dcim_cables_list_parameters.go index 7df677f4..dec08657 100644 --- a/netbox/client/dcim/dcim_cables_list_parameters.go +++ b/netbox/client/dcim/dcim_cables_list_parameters.go @@ -222,9 +222,27 @@ type DcimCablesListParams struct { // Tenant. Tenant *string + // Tenantn. + Tenantn *string + + // TenantGroup. + TenantGroup *string + + // TenantGroupn. + TenantGroupn *string + + // TenantGroupID. + TenantGroupID *string + + // TenantGroupIDn. + TenantGroupIDn *string + // TenantID. TenantID *string + // TenantIDn. + TenantIDn *string + // TerminationaID. TerminationaID *string @@ -849,6 +867,61 @@ func (o *DcimCablesListParams) SetTenant(tenant *string) { o.Tenant = tenant } +// WithTenantn adds the tenantn to the dcim cables list params +func (o *DcimCablesListParams) WithTenantn(tenantn *string) *DcimCablesListParams { + o.SetTenantn(tenantn) + return o +} + +// SetTenantn adds the tenantN to the dcim cables list params +func (o *DcimCablesListParams) SetTenantn(tenantn *string) { + o.Tenantn = tenantn +} + +// WithTenantGroup adds the tenantGroup to the dcim cables list params +func (o *DcimCablesListParams) WithTenantGroup(tenantGroup *string) *DcimCablesListParams { + o.SetTenantGroup(tenantGroup) + return o +} + +// SetTenantGroup adds the tenantGroup to the dcim cables list params +func (o *DcimCablesListParams) SetTenantGroup(tenantGroup *string) { + o.TenantGroup = tenantGroup +} + +// WithTenantGroupn adds the tenantGroupn to the dcim cables list params +func (o *DcimCablesListParams) WithTenantGroupn(tenantGroupn *string) *DcimCablesListParams { + o.SetTenantGroupn(tenantGroupn) + return o +} + +// SetTenantGroupn adds the tenantGroupN to the dcim cables list params +func (o *DcimCablesListParams) SetTenantGroupn(tenantGroupn *string) { + o.TenantGroupn = tenantGroupn +} + +// WithTenantGroupID adds the tenantGroupID to the dcim cables list params +func (o *DcimCablesListParams) WithTenantGroupID(tenantGroupID *string) *DcimCablesListParams { + o.SetTenantGroupID(tenantGroupID) + return o +} + +// SetTenantGroupID adds the tenantGroupId to the dcim cables list params +func (o *DcimCablesListParams) SetTenantGroupID(tenantGroupID *string) { + o.TenantGroupID = tenantGroupID +} + +// WithTenantGroupIDn adds the tenantGroupIDn to the dcim cables list params +func (o *DcimCablesListParams) WithTenantGroupIDn(tenantGroupIDn *string) *DcimCablesListParams { + o.SetTenantGroupIDn(tenantGroupIDn) + return o +} + +// SetTenantGroupIDn adds the tenantGroupIdN to the dcim cables list params +func (o *DcimCablesListParams) SetTenantGroupIDn(tenantGroupIDn *string) { + o.TenantGroupIDn = tenantGroupIDn +} + // WithTenantID adds the tenantID to the dcim cables list params func (o *DcimCablesListParams) WithTenantID(tenantID *string) *DcimCablesListParams { o.SetTenantID(tenantID) @@ -860,6 +933,17 @@ func (o *DcimCablesListParams) SetTenantID(tenantID *string) { o.TenantID = tenantID } +// WithTenantIDn adds the tenantIDn to the dcim cables list params +func (o *DcimCablesListParams) WithTenantIDn(tenantIDn *string) *DcimCablesListParams { + o.SetTenantIDn(tenantIDn) + return o +} + +// SetTenantIDn adds the tenantIdN to the dcim cables list params +func (o *DcimCablesListParams) SetTenantIDn(tenantIDn *string) { + o.TenantIDn = tenantIDn +} + // WithTerminationaID adds the terminationaID to the dcim cables list params func (o *DcimCablesListParams) WithTerminationaID(terminationaID *string) *DcimCablesListParams { o.SetTerminationaID(terminationaID) @@ -1865,6 +1949,91 @@ func (o *DcimCablesListParams) WriteToRequest(r runtime.ClientRequest, reg strfm } } + if o.Tenantn != nil { + + // query param tenant__n + var qrTenantn string + + if o.Tenantn != nil { + qrTenantn = *o.Tenantn + } + qTenantn := qrTenantn + if qTenantn != "" { + + if err := r.SetQueryParam("tenant__n", qTenantn); err != nil { + return err + } + } + } + + if o.TenantGroup != nil { + + // query param tenant_group + var qrTenantGroup string + + if o.TenantGroup != nil { + qrTenantGroup = *o.TenantGroup + } + qTenantGroup := qrTenantGroup + if qTenantGroup != "" { + + if err := r.SetQueryParam("tenant_group", qTenantGroup); err != nil { + return err + } + } + } + + if o.TenantGroupn != nil { + + // query param tenant_group__n + var qrTenantGroupn string + + if o.TenantGroupn != nil { + qrTenantGroupn = *o.TenantGroupn + } + qTenantGroupn := qrTenantGroupn + if qTenantGroupn != "" { + + if err := r.SetQueryParam("tenant_group__n", qTenantGroupn); err != nil { + return err + } + } + } + + if o.TenantGroupID != nil { + + // query param tenant_group_id + var qrTenantGroupID string + + if o.TenantGroupID != nil { + qrTenantGroupID = *o.TenantGroupID + } + qTenantGroupID := qrTenantGroupID + if qTenantGroupID != "" { + + if err := r.SetQueryParam("tenant_group_id", qTenantGroupID); err != nil { + return err + } + } + } + + if o.TenantGroupIDn != nil { + + // query param tenant_group_id__n + var qrTenantGroupIDn string + + if o.TenantGroupIDn != nil { + qrTenantGroupIDn = *o.TenantGroupIDn + } + qTenantGroupIDn := qrTenantGroupIDn + if qTenantGroupIDn != "" { + + if err := r.SetQueryParam("tenant_group_id__n", qTenantGroupIDn); err != nil { + return err + } + } + } + if o.TenantID != nil { // query param tenant_id @@ -1882,6 +2051,23 @@ func (o *DcimCablesListParams) WriteToRequest(r runtime.ClientRequest, reg strfm } } + if o.TenantIDn != nil { + + // query param tenant_id__n + var qrTenantIDn string + + if o.TenantIDn != nil { + qrTenantIDn = *o.TenantIDn + } + qTenantIDn := qrTenantIDn + if qTenantIDn != "" { + + if err := r.SetQueryParam("tenant_id__n", qTenantIDn); err != nil { + return err + } + } + } + if o.TerminationaID != nil { // query param termination_a_id diff --git a/netbox/client/dcim/dcim_device_roles_list_parameters.go b/netbox/client/dcim/dcim_device_roles_list_parameters.go index c63708c0..b4162714 100644 --- a/netbox/client/dcim/dcim_device_roles_list_parameters.go +++ b/netbox/client/dcim/dcim_device_roles_list_parameters.go @@ -117,6 +117,39 @@ type DcimDeviceRolesListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // ID. ID *string @@ -225,6 +258,12 @@ type DcimDeviceRolesListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + // VMRole. VMRole *string @@ -435,6 +474,127 @@ func (o *DcimDeviceRolesListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithDescription(description *string) *DcimDeviceRolesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithDescriptionEmpty(descriptionEmpty *string) *DcimDeviceRolesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithDescriptionIc(descriptionIc *string) *DcimDeviceRolesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithDescriptionIe(descriptionIe *string) *DcimDeviceRolesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithDescriptionIew(descriptionIew *string) *DcimDeviceRolesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithDescriptionIsw(descriptionIsw *string) *DcimDeviceRolesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithDescriptionn(descriptionn *string) *DcimDeviceRolesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithDescriptionNic(descriptionNic *string) *DcimDeviceRolesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithDescriptionNie(descriptionNie *string) *DcimDeviceRolesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithDescriptionNiew(descriptionNiew *string) *DcimDeviceRolesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithDescriptionNisw(descriptionNisw *string) *DcimDeviceRolesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithID adds the id to the dcim device roles list params func (o *DcimDeviceRolesListParams) WithID(id *string) *DcimDeviceRolesListParams { o.SetID(id) @@ -809,6 +969,28 @@ func (o *DcimDeviceRolesListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithTag(tag *string) *DcimDeviceRolesListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the dcim device roles list params +func (o *DcimDeviceRolesListParams) WithTagn(tagn *string) *DcimDeviceRolesListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the dcim device roles list params +func (o *DcimDeviceRolesListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WithVMRole adds the vMRole to the dcim device roles list params func (o *DcimDeviceRolesListParams) WithVMRole(vMRole *string) *DcimDeviceRolesListParams { o.SetVMRole(vMRole) @@ -1066,6 +1248,193 @@ func (o *DcimDeviceRolesListParams) WriteToRequest(r runtime.ClientRequest, reg } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.ID != nil { // query param id @@ -1644,6 +2013,40 @@ func (o *DcimDeviceRolesListParams) WriteToRequest(r runtime.ClientRequest, reg } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if o.VMRole != nil { // query param vm_role diff --git a/netbox/client/dcim/dcim_device_types_list_parameters.go b/netbox/client/dcim/dcim_device_types_list_parameters.go index b261929f..70f044f1 100644 --- a/netbox/client/dcim/dcim_device_types_list_parameters.go +++ b/netbox/client/dcim/dcim_device_types_list_parameters.go @@ -75,6 +75,12 @@ func NewDcimDeviceTypesListParamsWithHTTPClient(client *http.Client) *DcimDevice */ type DcimDeviceTypesListParams struct { + // Airflow. + Airflow *string + + // Airflown. + Airflown *string + // ConsolePorts. ConsolePorts *string @@ -344,6 +350,28 @@ func (o *DcimDeviceTypesListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithAirflow adds the airflow to the dcim device types list params +func (o *DcimDeviceTypesListParams) WithAirflow(airflow *string) *DcimDeviceTypesListParams { + o.SetAirflow(airflow) + return o +} + +// SetAirflow adds the airflow to the dcim device types list params +func (o *DcimDeviceTypesListParams) SetAirflow(airflow *string) { + o.Airflow = airflow +} + +// WithAirflown adds the airflown to the dcim device types list params +func (o *DcimDeviceTypesListParams) WithAirflown(airflown *string) *DcimDeviceTypesListParams { + o.SetAirflown(airflown) + return o +} + +// SetAirflown adds the airflowN to the dcim device types list params +func (o *DcimDeviceTypesListParams) SetAirflown(airflown *string) { + o.Airflown = airflown +} + // WithConsolePorts adds the consolePorts to the dcim device types list params func (o *DcimDeviceTypesListParams) WithConsolePorts(consolePorts *string) *DcimDeviceTypesListParams { o.SetConsolePorts(consolePorts) @@ -1122,6 +1150,40 @@ func (o *DcimDeviceTypesListParams) WriteToRequest(r runtime.ClientRequest, reg } var res []error + if o.Airflow != nil { + + // query param airflow + var qrAirflow string + + if o.Airflow != nil { + qrAirflow = *o.Airflow + } + qAirflow := qrAirflow + if qAirflow != "" { + + if err := r.SetQueryParam("airflow", qAirflow); err != nil { + return err + } + } + } + + if o.Airflown != nil { + + // query param airflow__n + var qrAirflown string + + if o.Airflown != nil { + qrAirflown = *o.Airflown + } + qAirflown := qrAirflown + if qAirflown != "" { + + if err := r.SetQueryParam("airflow__n", qAirflown); err != nil { + return err + } + } + } + if o.ConsolePorts != nil { // query param console_ports diff --git a/netbox/client/dcim/dcim_devices_list_parameters.go b/netbox/client/dcim/dcim_devices_list_parameters.go index ec9f651f..b81ce4d9 100644 --- a/netbox/client/dcim/dcim_devices_list_parameters.go +++ b/netbox/client/dcim/dcim_devices_list_parameters.go @@ -75,6 +75,12 @@ func NewDcimDevicesListParamsWithHTTPClient(client *http.Client) *DcimDevicesLis */ type DcimDevicesListParams struct { + // Airflow. + Airflow *string + + // Airflown. + Airflown *string + // AssetTag. AssetTag *string @@ -120,6 +126,18 @@ type DcimDevicesListParams struct { // ConsoleServerPorts. ConsoleServerPorts *string + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -282,6 +300,12 @@ type DcimDevicesListParams struct { */ Offset *int64 + // ParentDeviceID. + ParentDeviceID *string + + // ParentDeviceIDn. + ParentDeviceIDn *string + // PassThroughPorts. PassThroughPorts *string @@ -515,6 +539,28 @@ func (o *DcimDevicesListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithAirflow adds the airflow to the dcim devices list params +func (o *DcimDevicesListParams) WithAirflow(airflow *string) *DcimDevicesListParams { + o.SetAirflow(airflow) + return o +} + +// SetAirflow adds the airflow to the dcim devices list params +func (o *DcimDevicesListParams) SetAirflow(airflow *string) { + o.Airflow = airflow +} + +// WithAirflown adds the airflown to the dcim devices list params +func (o *DcimDevicesListParams) WithAirflown(airflown *string) *DcimDevicesListParams { + o.SetAirflown(airflown) + return o +} + +// SetAirflown adds the airflowN to the dcim devices list params +func (o *DcimDevicesListParams) SetAirflown(airflown *string) { + o.Airflown = airflown +} + // WithAssetTag adds the assetTag to the dcim devices list params func (o *DcimDevicesListParams) WithAssetTag(assetTag *string) *DcimDevicesListParams { o.SetAssetTag(assetTag) @@ -680,6 +726,50 @@ func (o *DcimDevicesListParams) SetConsoleServerPorts(consoleServerPorts *string o.ConsoleServerPorts = consoleServerPorts } +// WithContact adds the contact to the dcim devices list params +func (o *DcimDevicesListParams) WithContact(contact *string) *DcimDevicesListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the dcim devices list params +func (o *DcimDevicesListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the dcim devices list params +func (o *DcimDevicesListParams) WithContactn(contactn *string) *DcimDevicesListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the dcim devices list params +func (o *DcimDevicesListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the dcim devices list params +func (o *DcimDevicesListParams) WithContactRole(contactRole *string) *DcimDevicesListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the dcim devices list params +func (o *DcimDevicesListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the dcim devices list params +func (o *DcimDevicesListParams) WithContactRolen(contactRolen *string) *DcimDevicesListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the dcim devices list params +func (o *DcimDevicesListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the dcim devices list params func (o *DcimDevicesListParams) WithCreated(created *string) *DcimDevicesListParams { o.SetCreated(created) @@ -1252,6 +1342,28 @@ func (o *DcimDevicesListParams) SetOffset(offset *int64) { o.Offset = offset } +// WithParentDeviceID adds the parentDeviceID to the dcim devices list params +func (o *DcimDevicesListParams) WithParentDeviceID(parentDeviceID *string) *DcimDevicesListParams { + o.SetParentDeviceID(parentDeviceID) + return o +} + +// SetParentDeviceID adds the parentDeviceId to the dcim devices list params +func (o *DcimDevicesListParams) SetParentDeviceID(parentDeviceID *string) { + o.ParentDeviceID = parentDeviceID +} + +// WithParentDeviceIDn adds the parentDeviceIDn to the dcim devices list params +func (o *DcimDevicesListParams) WithParentDeviceIDn(parentDeviceIDn *string) *DcimDevicesListParams { + o.SetParentDeviceIDn(parentDeviceIDn) + return o +} + +// SetParentDeviceIDn adds the parentDeviceIdN to the dcim devices list params +func (o *DcimDevicesListParams) SetParentDeviceIDn(parentDeviceIDn *string) { + o.ParentDeviceIDn = parentDeviceIDn +} + // WithPassThroughPorts adds the passThroughPorts to the dcim devices list params func (o *DcimDevicesListParams) WithPassThroughPorts(passThroughPorts *string) *DcimDevicesListParams { o.SetPassThroughPorts(passThroughPorts) @@ -1920,6 +2032,40 @@ func (o *DcimDevicesListParams) WriteToRequest(r runtime.ClientRequest, reg strf } var res []error + if o.Airflow != nil { + + // query param airflow + var qrAirflow string + + if o.Airflow != nil { + qrAirflow = *o.Airflow + } + qAirflow := qrAirflow + if qAirflow != "" { + + if err := r.SetQueryParam("airflow", qAirflow); err != nil { + return err + } + } + } + + if o.Airflown != nil { + + // query param airflow__n + var qrAirflown string + + if o.Airflown != nil { + qrAirflown = *o.Airflown + } + qAirflown := qrAirflown + if qAirflown != "" { + + if err := r.SetQueryParam("airflow__n", qAirflown); err != nil { + return err + } + } + } + if o.AssetTag != nil { // query param asset_tag @@ -2175,6 +2321,74 @@ func (o *DcimDevicesListParams) WriteToRequest(r runtime.ClientRequest, reg strf } } + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created @@ -3059,6 +3273,40 @@ func (o *DcimDevicesListParams) WriteToRequest(r runtime.ClientRequest, reg strf } } + if o.ParentDeviceID != nil { + + // query param parent_device_id + var qrParentDeviceID string + + if o.ParentDeviceID != nil { + qrParentDeviceID = *o.ParentDeviceID + } + qParentDeviceID := qrParentDeviceID + if qParentDeviceID != "" { + + if err := r.SetQueryParam("parent_device_id", qParentDeviceID); err != nil { + return err + } + } + } + + if o.ParentDeviceIDn != nil { + + // query param parent_device_id__n + var qrParentDeviceIDn string + + if o.ParentDeviceIDn != nil { + qrParentDeviceIDn = *o.ParentDeviceIDn + } + qParentDeviceIDn := qrParentDeviceIDn + if qParentDeviceIDn != "" { + + if err := r.SetQueryParam("parent_device_id__n", qParentDeviceIDn); err != nil { + return err + } + } + } + if o.PassThroughPorts != nil { // query param pass_through_ports diff --git a/netbox/client/dcim/dcim_interfaces_list_parameters.go b/netbox/client/dcim/dcim_interfaces_list_parameters.go index ca1a4d88..32f26788 100644 --- a/netbox/client/dcim/dcim_interfaces_list_parameters.go +++ b/netbox/client/dcim/dcim_interfaces_list_parameters.go @@ -75,6 +75,12 @@ func NewDcimInterfacesListParamsWithHTTPClient(client *http.Client) *DcimInterfa */ type DcimInterfacesListParams struct { + // BridgeID. + BridgeID *string + + // BridgeIDn. + BridgeIDn *string + // Cabled. Cabled *string @@ -336,6 +342,54 @@ type DcimInterfacesListParams struct { // RegionIDn. RegionIDn *string + // RfChannel. + RfChannel *string + + // RfChanneln. + RfChanneln *string + + // RfChannelFrequency. + RfChannelFrequency *string + + // RfChannelFrequencyGt. + RfChannelFrequencyGt *string + + // RfChannelFrequencyGte. + RfChannelFrequencyGte *string + + // RfChannelFrequencyLt. + RfChannelFrequencyLt *string + + // RfChannelFrequencyLte. + RfChannelFrequencyLte *string + + // RfChannelFrequencyn. + RfChannelFrequencyn *string + + // RfChannelWidth. + RfChannelWidth *string + + // RfChannelWidthGt. + RfChannelWidthGt *string + + // RfChannelWidthGte. + RfChannelWidthGte *string + + // RfChannelWidthLt. + RfChannelWidthLt *string + + // RfChannelWidthLte. + RfChannelWidthLte *string + + // RfChannelWidthn. + RfChannelWidthn *string + + // RfRole. + RfRole *string + + // RfRolen. + RfRolen *string + // Site. Site *string @@ -366,6 +420,24 @@ type DcimInterfacesListParams struct { // Tagn. Tagn *string + // TxPower. + TxPower *string + + // TxPowerGt. + TxPowerGt *string + + // TxPowerGte. + TxPowerGte *string + + // TxPowerLt. + TxPowerLt *string + + // TxPowerLte. + TxPowerLte *string + + // TxPowern. + TxPowern *string + // Type. Type *string @@ -390,6 +462,36 @@ type DcimInterfacesListParams struct { // VlanID. VlanID *string + // Wwn. + Wwn *string + + // WwnIc. + WwnIc *string + + // WwnIe. + WwnIe *string + + // WwnIew. + WwnIew *string + + // WwnIsw. + WwnIsw *string + + // Wwnn. + Wwnn *string + + // WwnNic. + WwnNic *string + + // WwnNie. + WwnNie *string + + // WwnNiew. + WwnNiew *string + + // WwnNisw. + WwnNisw *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -443,6 +545,28 @@ func (o *DcimInterfacesListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithBridgeID adds the bridgeID to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithBridgeID(bridgeID *string) *DcimInterfacesListParams { + o.SetBridgeID(bridgeID) + return o +} + +// SetBridgeID adds the bridgeId to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetBridgeID(bridgeID *string) { + o.BridgeID = bridgeID +} + +// WithBridgeIDn adds the bridgeIDn to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithBridgeIDn(bridgeIDn *string) *DcimInterfacesListParams { + o.SetBridgeIDn(bridgeIDn) + return o +} + +// SetBridgeIDn adds the bridgeIdN to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetBridgeIDn(bridgeIDn *string) { + o.BridgeIDn = bridgeIDn +} + // WithCabled adds the cabled to the dcim interfaces list params func (o *DcimInterfacesListParams) WithCabled(cabled *string) *DcimInterfacesListParams { o.SetCabled(cabled) @@ -1378,6 +1502,182 @@ func (o *DcimInterfacesListParams) SetRegionIDn(regionIDn *string) { o.RegionIDn = regionIDn } +// WithRfChannel adds the rfChannel to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannel(rfChannel *string) *DcimInterfacesListParams { + o.SetRfChannel(rfChannel) + return o +} + +// SetRfChannel adds the rfChannel to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannel(rfChannel *string) { + o.RfChannel = rfChannel +} + +// WithRfChanneln adds the rfChanneln to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChanneln(rfChanneln *string) *DcimInterfacesListParams { + o.SetRfChanneln(rfChanneln) + return o +} + +// SetRfChanneln adds the rfChannelN to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChanneln(rfChanneln *string) { + o.RfChanneln = rfChanneln +} + +// WithRfChannelFrequency adds the rfChannelFrequency to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelFrequency(rfChannelFrequency *string) *DcimInterfacesListParams { + o.SetRfChannelFrequency(rfChannelFrequency) + return o +} + +// SetRfChannelFrequency adds the rfChannelFrequency to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelFrequency(rfChannelFrequency *string) { + o.RfChannelFrequency = rfChannelFrequency +} + +// WithRfChannelFrequencyGt adds the rfChannelFrequencyGt to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelFrequencyGt(rfChannelFrequencyGt *string) *DcimInterfacesListParams { + o.SetRfChannelFrequencyGt(rfChannelFrequencyGt) + return o +} + +// SetRfChannelFrequencyGt adds the rfChannelFrequencyGt to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelFrequencyGt(rfChannelFrequencyGt *string) { + o.RfChannelFrequencyGt = rfChannelFrequencyGt +} + +// WithRfChannelFrequencyGte adds the rfChannelFrequencyGte to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelFrequencyGte(rfChannelFrequencyGte *string) *DcimInterfacesListParams { + o.SetRfChannelFrequencyGte(rfChannelFrequencyGte) + return o +} + +// SetRfChannelFrequencyGte adds the rfChannelFrequencyGte to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelFrequencyGte(rfChannelFrequencyGte *string) { + o.RfChannelFrequencyGte = rfChannelFrequencyGte +} + +// WithRfChannelFrequencyLt adds the rfChannelFrequencyLt to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelFrequencyLt(rfChannelFrequencyLt *string) *DcimInterfacesListParams { + o.SetRfChannelFrequencyLt(rfChannelFrequencyLt) + return o +} + +// SetRfChannelFrequencyLt adds the rfChannelFrequencyLt to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelFrequencyLt(rfChannelFrequencyLt *string) { + o.RfChannelFrequencyLt = rfChannelFrequencyLt +} + +// WithRfChannelFrequencyLte adds the rfChannelFrequencyLte to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelFrequencyLte(rfChannelFrequencyLte *string) *DcimInterfacesListParams { + o.SetRfChannelFrequencyLte(rfChannelFrequencyLte) + return o +} + +// SetRfChannelFrequencyLte adds the rfChannelFrequencyLte to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelFrequencyLte(rfChannelFrequencyLte *string) { + o.RfChannelFrequencyLte = rfChannelFrequencyLte +} + +// WithRfChannelFrequencyn adds the rfChannelFrequencyn to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelFrequencyn(rfChannelFrequencyn *string) *DcimInterfacesListParams { + o.SetRfChannelFrequencyn(rfChannelFrequencyn) + return o +} + +// SetRfChannelFrequencyn adds the rfChannelFrequencyN to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelFrequencyn(rfChannelFrequencyn *string) { + o.RfChannelFrequencyn = rfChannelFrequencyn +} + +// WithRfChannelWidth adds the rfChannelWidth to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelWidth(rfChannelWidth *string) *DcimInterfacesListParams { + o.SetRfChannelWidth(rfChannelWidth) + return o +} + +// SetRfChannelWidth adds the rfChannelWidth to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelWidth(rfChannelWidth *string) { + o.RfChannelWidth = rfChannelWidth +} + +// WithRfChannelWidthGt adds the rfChannelWidthGt to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelWidthGt(rfChannelWidthGt *string) *DcimInterfacesListParams { + o.SetRfChannelWidthGt(rfChannelWidthGt) + return o +} + +// SetRfChannelWidthGt adds the rfChannelWidthGt to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelWidthGt(rfChannelWidthGt *string) { + o.RfChannelWidthGt = rfChannelWidthGt +} + +// WithRfChannelWidthGte adds the rfChannelWidthGte to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelWidthGte(rfChannelWidthGte *string) *DcimInterfacesListParams { + o.SetRfChannelWidthGte(rfChannelWidthGte) + return o +} + +// SetRfChannelWidthGte adds the rfChannelWidthGte to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelWidthGte(rfChannelWidthGte *string) { + o.RfChannelWidthGte = rfChannelWidthGte +} + +// WithRfChannelWidthLt adds the rfChannelWidthLt to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelWidthLt(rfChannelWidthLt *string) *DcimInterfacesListParams { + o.SetRfChannelWidthLt(rfChannelWidthLt) + return o +} + +// SetRfChannelWidthLt adds the rfChannelWidthLt to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelWidthLt(rfChannelWidthLt *string) { + o.RfChannelWidthLt = rfChannelWidthLt +} + +// WithRfChannelWidthLte adds the rfChannelWidthLte to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelWidthLte(rfChannelWidthLte *string) *DcimInterfacesListParams { + o.SetRfChannelWidthLte(rfChannelWidthLte) + return o +} + +// SetRfChannelWidthLte adds the rfChannelWidthLte to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelWidthLte(rfChannelWidthLte *string) { + o.RfChannelWidthLte = rfChannelWidthLte +} + +// WithRfChannelWidthn adds the rfChannelWidthn to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfChannelWidthn(rfChannelWidthn *string) *DcimInterfacesListParams { + o.SetRfChannelWidthn(rfChannelWidthn) + return o +} + +// SetRfChannelWidthn adds the rfChannelWidthN to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfChannelWidthn(rfChannelWidthn *string) { + o.RfChannelWidthn = rfChannelWidthn +} + +// WithRfRole adds the rfRole to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfRole(rfRole *string) *DcimInterfacesListParams { + o.SetRfRole(rfRole) + return o +} + +// SetRfRole adds the rfRole to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfRole(rfRole *string) { + o.RfRole = rfRole +} + +// WithRfRolen adds the rfRolen to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithRfRolen(rfRolen *string) *DcimInterfacesListParams { + o.SetRfRolen(rfRolen) + return o +} + +// SetRfRolen adds the rfRoleN to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetRfRolen(rfRolen *string) { + o.RfRolen = rfRolen +} + // WithSite adds the site to the dcim interfaces list params func (o *DcimInterfacesListParams) WithSite(site *string) *DcimInterfacesListParams { o.SetSite(site) @@ -1488,6 +1788,72 @@ func (o *DcimInterfacesListParams) SetTagn(tagn *string) { o.Tagn = tagn } +// WithTxPower adds the txPower to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithTxPower(txPower *string) *DcimInterfacesListParams { + o.SetTxPower(txPower) + return o +} + +// SetTxPower adds the txPower to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetTxPower(txPower *string) { + o.TxPower = txPower +} + +// WithTxPowerGt adds the txPowerGt to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithTxPowerGt(txPowerGt *string) *DcimInterfacesListParams { + o.SetTxPowerGt(txPowerGt) + return o +} + +// SetTxPowerGt adds the txPowerGt to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetTxPowerGt(txPowerGt *string) { + o.TxPowerGt = txPowerGt +} + +// WithTxPowerGte adds the txPowerGte to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithTxPowerGte(txPowerGte *string) *DcimInterfacesListParams { + o.SetTxPowerGte(txPowerGte) + return o +} + +// SetTxPowerGte adds the txPowerGte to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetTxPowerGte(txPowerGte *string) { + o.TxPowerGte = txPowerGte +} + +// WithTxPowerLt adds the txPowerLt to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithTxPowerLt(txPowerLt *string) *DcimInterfacesListParams { + o.SetTxPowerLt(txPowerLt) + return o +} + +// SetTxPowerLt adds the txPowerLt to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetTxPowerLt(txPowerLt *string) { + o.TxPowerLt = txPowerLt +} + +// WithTxPowerLte adds the txPowerLte to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithTxPowerLte(txPowerLte *string) *DcimInterfacesListParams { + o.SetTxPowerLte(txPowerLte) + return o +} + +// SetTxPowerLte adds the txPowerLte to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetTxPowerLte(txPowerLte *string) { + o.TxPowerLte = txPowerLte +} + +// WithTxPowern adds the txPowern to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithTxPowern(txPowern *string) *DcimInterfacesListParams { + o.SetTxPowern(txPowern) + return o +} + +// SetTxPowern adds the txPowerN to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetTxPowern(txPowern *string) { + o.TxPowern = txPowern +} + // WithType adds the typeVar to the dcim interfaces list params func (o *DcimInterfacesListParams) WithType(typeVar *string) *DcimInterfacesListParams { o.SetType(typeVar) @@ -1576,6 +1942,116 @@ func (o *DcimInterfacesListParams) SetVlanID(vlanID *string) { o.VlanID = vlanID } +// WithWwn adds the wwn to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithWwn(wwn *string) *DcimInterfacesListParams { + o.SetWwn(wwn) + return o +} + +// SetWwn adds the wwn to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetWwn(wwn *string) { + o.Wwn = wwn +} + +// WithWwnIc adds the wwnIc to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithWwnIc(wwnIc *string) *DcimInterfacesListParams { + o.SetWwnIc(wwnIc) + return o +} + +// SetWwnIc adds the wwnIc to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetWwnIc(wwnIc *string) { + o.WwnIc = wwnIc +} + +// WithWwnIe adds the wwnIe to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithWwnIe(wwnIe *string) *DcimInterfacesListParams { + o.SetWwnIe(wwnIe) + return o +} + +// SetWwnIe adds the wwnIe to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetWwnIe(wwnIe *string) { + o.WwnIe = wwnIe +} + +// WithWwnIew adds the wwnIew to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithWwnIew(wwnIew *string) *DcimInterfacesListParams { + o.SetWwnIew(wwnIew) + return o +} + +// SetWwnIew adds the wwnIew to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetWwnIew(wwnIew *string) { + o.WwnIew = wwnIew +} + +// WithWwnIsw adds the wwnIsw to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithWwnIsw(wwnIsw *string) *DcimInterfacesListParams { + o.SetWwnIsw(wwnIsw) + return o +} + +// SetWwnIsw adds the wwnIsw to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetWwnIsw(wwnIsw *string) { + o.WwnIsw = wwnIsw +} + +// WithWwnn adds the wwnn to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithWwnn(wwnn *string) *DcimInterfacesListParams { + o.SetWwnn(wwnn) + return o +} + +// SetWwnn adds the wwnN to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetWwnn(wwnn *string) { + o.Wwnn = wwnn +} + +// WithWwnNic adds the wwnNic to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithWwnNic(wwnNic *string) *DcimInterfacesListParams { + o.SetWwnNic(wwnNic) + return o +} + +// SetWwnNic adds the wwnNic to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetWwnNic(wwnNic *string) { + o.WwnNic = wwnNic +} + +// WithWwnNie adds the wwnNie to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithWwnNie(wwnNie *string) *DcimInterfacesListParams { + o.SetWwnNie(wwnNie) + return o +} + +// SetWwnNie adds the wwnNie to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetWwnNie(wwnNie *string) { + o.WwnNie = wwnNie +} + +// WithWwnNiew adds the wwnNiew to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithWwnNiew(wwnNiew *string) *DcimInterfacesListParams { + o.SetWwnNiew(wwnNiew) + return o +} + +// SetWwnNiew adds the wwnNiew to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetWwnNiew(wwnNiew *string) { + o.WwnNiew = wwnNiew +} + +// WithWwnNisw adds the wwnNisw to the dcim interfaces list params +func (o *DcimInterfacesListParams) WithWwnNisw(wwnNisw *string) *DcimInterfacesListParams { + o.SetWwnNisw(wwnNisw) + return o +} + +// SetWwnNisw adds the wwnNisw to the dcim interfaces list params +func (o *DcimInterfacesListParams) SetWwnNisw(wwnNisw *string) { + o.WwnNisw = wwnNisw +} + // WriteToRequest writes these params to a swagger request func (o *DcimInterfacesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -1584,6 +2060,40 @@ func (o *DcimInterfacesListParams) WriteToRequest(r runtime.ClientRequest, reg s } var res []error + if o.BridgeID != nil { + + // query param bridge_id + var qrBridgeID string + + if o.BridgeID != nil { + qrBridgeID = *o.BridgeID + } + qBridgeID := qrBridgeID + if qBridgeID != "" { + + if err := r.SetQueryParam("bridge_id", qBridgeID); err != nil { + return err + } + } + } + + if o.BridgeIDn != nil { + + // query param bridge_id__n + var qrBridgeIDn string + + if o.BridgeIDn != nil { + qrBridgeIDn = *o.BridgeIDn + } + qBridgeIDn := qrBridgeIDn + if qBridgeIDn != "" { + + if err := r.SetQueryParam("bridge_id__n", qBridgeIDn); err != nil { + return err + } + } + } + if o.Cabled != nil { // query param cabled @@ -3029,6 +3539,278 @@ func (o *DcimInterfacesListParams) WriteToRequest(r runtime.ClientRequest, reg s } } + if o.RfChannel != nil { + + // query param rf_channel + var qrRfChannel string + + if o.RfChannel != nil { + qrRfChannel = *o.RfChannel + } + qRfChannel := qrRfChannel + if qRfChannel != "" { + + if err := r.SetQueryParam("rf_channel", qRfChannel); err != nil { + return err + } + } + } + + if o.RfChanneln != nil { + + // query param rf_channel__n + var qrRfChanneln string + + if o.RfChanneln != nil { + qrRfChanneln = *o.RfChanneln + } + qRfChanneln := qrRfChanneln + if qRfChanneln != "" { + + if err := r.SetQueryParam("rf_channel__n", qRfChanneln); err != nil { + return err + } + } + } + + if o.RfChannelFrequency != nil { + + // query param rf_channel_frequency + var qrRfChannelFrequency string + + if o.RfChannelFrequency != nil { + qrRfChannelFrequency = *o.RfChannelFrequency + } + qRfChannelFrequency := qrRfChannelFrequency + if qRfChannelFrequency != "" { + + if err := r.SetQueryParam("rf_channel_frequency", qRfChannelFrequency); err != nil { + return err + } + } + } + + if o.RfChannelFrequencyGt != nil { + + // query param rf_channel_frequency__gt + var qrRfChannelFrequencyGt string + + if o.RfChannelFrequencyGt != nil { + qrRfChannelFrequencyGt = *o.RfChannelFrequencyGt + } + qRfChannelFrequencyGt := qrRfChannelFrequencyGt + if qRfChannelFrequencyGt != "" { + + if err := r.SetQueryParam("rf_channel_frequency__gt", qRfChannelFrequencyGt); err != nil { + return err + } + } + } + + if o.RfChannelFrequencyGte != nil { + + // query param rf_channel_frequency__gte + var qrRfChannelFrequencyGte string + + if o.RfChannelFrequencyGte != nil { + qrRfChannelFrequencyGte = *o.RfChannelFrequencyGte + } + qRfChannelFrequencyGte := qrRfChannelFrequencyGte + if qRfChannelFrequencyGte != "" { + + if err := r.SetQueryParam("rf_channel_frequency__gte", qRfChannelFrequencyGte); err != nil { + return err + } + } + } + + if o.RfChannelFrequencyLt != nil { + + // query param rf_channel_frequency__lt + var qrRfChannelFrequencyLt string + + if o.RfChannelFrequencyLt != nil { + qrRfChannelFrequencyLt = *o.RfChannelFrequencyLt + } + qRfChannelFrequencyLt := qrRfChannelFrequencyLt + if qRfChannelFrequencyLt != "" { + + if err := r.SetQueryParam("rf_channel_frequency__lt", qRfChannelFrequencyLt); err != nil { + return err + } + } + } + + if o.RfChannelFrequencyLte != nil { + + // query param rf_channel_frequency__lte + var qrRfChannelFrequencyLte string + + if o.RfChannelFrequencyLte != nil { + qrRfChannelFrequencyLte = *o.RfChannelFrequencyLte + } + qRfChannelFrequencyLte := qrRfChannelFrequencyLte + if qRfChannelFrequencyLte != "" { + + if err := r.SetQueryParam("rf_channel_frequency__lte", qRfChannelFrequencyLte); err != nil { + return err + } + } + } + + if o.RfChannelFrequencyn != nil { + + // query param rf_channel_frequency__n + var qrRfChannelFrequencyn string + + if o.RfChannelFrequencyn != nil { + qrRfChannelFrequencyn = *o.RfChannelFrequencyn + } + qRfChannelFrequencyn := qrRfChannelFrequencyn + if qRfChannelFrequencyn != "" { + + if err := r.SetQueryParam("rf_channel_frequency__n", qRfChannelFrequencyn); err != nil { + return err + } + } + } + + if o.RfChannelWidth != nil { + + // query param rf_channel_width + var qrRfChannelWidth string + + if o.RfChannelWidth != nil { + qrRfChannelWidth = *o.RfChannelWidth + } + qRfChannelWidth := qrRfChannelWidth + if qRfChannelWidth != "" { + + if err := r.SetQueryParam("rf_channel_width", qRfChannelWidth); err != nil { + return err + } + } + } + + if o.RfChannelWidthGt != nil { + + // query param rf_channel_width__gt + var qrRfChannelWidthGt string + + if o.RfChannelWidthGt != nil { + qrRfChannelWidthGt = *o.RfChannelWidthGt + } + qRfChannelWidthGt := qrRfChannelWidthGt + if qRfChannelWidthGt != "" { + + if err := r.SetQueryParam("rf_channel_width__gt", qRfChannelWidthGt); err != nil { + return err + } + } + } + + if o.RfChannelWidthGte != nil { + + // query param rf_channel_width__gte + var qrRfChannelWidthGte string + + if o.RfChannelWidthGte != nil { + qrRfChannelWidthGte = *o.RfChannelWidthGte + } + qRfChannelWidthGte := qrRfChannelWidthGte + if qRfChannelWidthGte != "" { + + if err := r.SetQueryParam("rf_channel_width__gte", qRfChannelWidthGte); err != nil { + return err + } + } + } + + if o.RfChannelWidthLt != nil { + + // query param rf_channel_width__lt + var qrRfChannelWidthLt string + + if o.RfChannelWidthLt != nil { + qrRfChannelWidthLt = *o.RfChannelWidthLt + } + qRfChannelWidthLt := qrRfChannelWidthLt + if qRfChannelWidthLt != "" { + + if err := r.SetQueryParam("rf_channel_width__lt", qRfChannelWidthLt); err != nil { + return err + } + } + } + + if o.RfChannelWidthLte != nil { + + // query param rf_channel_width__lte + var qrRfChannelWidthLte string + + if o.RfChannelWidthLte != nil { + qrRfChannelWidthLte = *o.RfChannelWidthLte + } + qRfChannelWidthLte := qrRfChannelWidthLte + if qRfChannelWidthLte != "" { + + if err := r.SetQueryParam("rf_channel_width__lte", qRfChannelWidthLte); err != nil { + return err + } + } + } + + if o.RfChannelWidthn != nil { + + // query param rf_channel_width__n + var qrRfChannelWidthn string + + if o.RfChannelWidthn != nil { + qrRfChannelWidthn = *o.RfChannelWidthn + } + qRfChannelWidthn := qrRfChannelWidthn + if qRfChannelWidthn != "" { + + if err := r.SetQueryParam("rf_channel_width__n", qRfChannelWidthn); err != nil { + return err + } + } + } + + if o.RfRole != nil { + + // query param rf_role + var qrRfRole string + + if o.RfRole != nil { + qrRfRole = *o.RfRole + } + qRfRole := qrRfRole + if qRfRole != "" { + + if err := r.SetQueryParam("rf_role", qRfRole); err != nil { + return err + } + } + } + + if o.RfRolen != nil { + + // query param rf_role__n + var qrRfRolen string + + if o.RfRolen != nil { + qrRfRolen = *o.RfRolen + } + qRfRolen := qrRfRolen + if qRfRolen != "" { + + if err := r.SetQueryParam("rf_role__n", qRfRolen); err != nil { + return err + } + } + } + if o.Site != nil { // query param site @@ -3199,6 +3981,108 @@ func (o *DcimInterfacesListParams) WriteToRequest(r runtime.ClientRequest, reg s } } + if o.TxPower != nil { + + // query param tx_power + var qrTxPower string + + if o.TxPower != nil { + qrTxPower = *o.TxPower + } + qTxPower := qrTxPower + if qTxPower != "" { + + if err := r.SetQueryParam("tx_power", qTxPower); err != nil { + return err + } + } + } + + if o.TxPowerGt != nil { + + // query param tx_power__gt + var qrTxPowerGt string + + if o.TxPowerGt != nil { + qrTxPowerGt = *o.TxPowerGt + } + qTxPowerGt := qrTxPowerGt + if qTxPowerGt != "" { + + if err := r.SetQueryParam("tx_power__gt", qTxPowerGt); err != nil { + return err + } + } + } + + if o.TxPowerGte != nil { + + // query param tx_power__gte + var qrTxPowerGte string + + if o.TxPowerGte != nil { + qrTxPowerGte = *o.TxPowerGte + } + qTxPowerGte := qrTxPowerGte + if qTxPowerGte != "" { + + if err := r.SetQueryParam("tx_power__gte", qTxPowerGte); err != nil { + return err + } + } + } + + if o.TxPowerLt != nil { + + // query param tx_power__lt + var qrTxPowerLt string + + if o.TxPowerLt != nil { + qrTxPowerLt = *o.TxPowerLt + } + qTxPowerLt := qrTxPowerLt + if qTxPowerLt != "" { + + if err := r.SetQueryParam("tx_power__lt", qTxPowerLt); err != nil { + return err + } + } + } + + if o.TxPowerLte != nil { + + // query param tx_power__lte + var qrTxPowerLte string + + if o.TxPowerLte != nil { + qrTxPowerLte = *o.TxPowerLte + } + qTxPowerLte := qrTxPowerLte + if qTxPowerLte != "" { + + if err := r.SetQueryParam("tx_power__lte", qTxPowerLte); err != nil { + return err + } + } + } + + if o.TxPowern != nil { + + // query param tx_power__n + var qrTxPowern string + + if o.TxPowern != nil { + qrTxPowern = *o.TxPowern + } + qTxPowern := qrTxPowern + if qTxPowern != "" { + + if err := r.SetQueryParam("tx_power__n", qTxPowern); err != nil { + return err + } + } + } + if o.Type != nil { // query param type @@ -3335,6 +4219,176 @@ func (o *DcimInterfacesListParams) WriteToRequest(r runtime.ClientRequest, reg s } } + if o.Wwn != nil { + + // query param wwn + var qrWwn string + + if o.Wwn != nil { + qrWwn = *o.Wwn + } + qWwn := qrWwn + if qWwn != "" { + + if err := r.SetQueryParam("wwn", qWwn); err != nil { + return err + } + } + } + + if o.WwnIc != nil { + + // query param wwn__ic + var qrWwnIc string + + if o.WwnIc != nil { + qrWwnIc = *o.WwnIc + } + qWwnIc := qrWwnIc + if qWwnIc != "" { + + if err := r.SetQueryParam("wwn__ic", qWwnIc); err != nil { + return err + } + } + } + + if o.WwnIe != nil { + + // query param wwn__ie + var qrWwnIe string + + if o.WwnIe != nil { + qrWwnIe = *o.WwnIe + } + qWwnIe := qrWwnIe + if qWwnIe != "" { + + if err := r.SetQueryParam("wwn__ie", qWwnIe); err != nil { + return err + } + } + } + + if o.WwnIew != nil { + + // query param wwn__iew + var qrWwnIew string + + if o.WwnIew != nil { + qrWwnIew = *o.WwnIew + } + qWwnIew := qrWwnIew + if qWwnIew != "" { + + if err := r.SetQueryParam("wwn__iew", qWwnIew); err != nil { + return err + } + } + } + + if o.WwnIsw != nil { + + // query param wwn__isw + var qrWwnIsw string + + if o.WwnIsw != nil { + qrWwnIsw = *o.WwnIsw + } + qWwnIsw := qrWwnIsw + if qWwnIsw != "" { + + if err := r.SetQueryParam("wwn__isw", qWwnIsw); err != nil { + return err + } + } + } + + if o.Wwnn != nil { + + // query param wwn__n + var qrWwnn string + + if o.Wwnn != nil { + qrWwnn = *o.Wwnn + } + qWwnn := qrWwnn + if qWwnn != "" { + + if err := r.SetQueryParam("wwn__n", qWwnn); err != nil { + return err + } + } + } + + if o.WwnNic != nil { + + // query param wwn__nic + var qrWwnNic string + + if o.WwnNic != nil { + qrWwnNic = *o.WwnNic + } + qWwnNic := qrWwnNic + if qWwnNic != "" { + + if err := r.SetQueryParam("wwn__nic", qWwnNic); err != nil { + return err + } + } + } + + if o.WwnNie != nil { + + // query param wwn__nie + var qrWwnNie string + + if o.WwnNie != nil { + qrWwnNie = *o.WwnNie + } + qWwnNie := qrWwnNie + if qWwnNie != "" { + + if err := r.SetQueryParam("wwn__nie", qWwnNie); err != nil { + return err + } + } + } + + if o.WwnNiew != nil { + + // query param wwn__niew + var qrWwnNiew string + + if o.WwnNiew != nil { + qrWwnNiew = *o.WwnNiew + } + qWwnNiew := qrWwnNiew + if qWwnNiew != "" { + + if err := r.SetQueryParam("wwn__niew", qWwnNiew); err != nil { + return err + } + } + } + + if o.WwnNisw != nil { + + // query param wwn__nisw + var qrWwnNisw string + + if o.WwnNisw != nil { + qrWwnNisw = *o.WwnNisw + } + qWwnNisw := qrWwnNisw + if qWwnNisw != "" { + + if err := r.SetQueryParam("wwn__nisw", qWwnNisw); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/dcim/dcim_locations_list_parameters.go b/netbox/client/dcim/dcim_locations_list_parameters.go index bf0ae72a..7bec7aef 100644 --- a/netbox/client/dcim/dcim_locations_list_parameters.go +++ b/netbox/client/dcim/dcim_locations_list_parameters.go @@ -75,6 +75,18 @@ func NewDcimLocationsListParamsWithHTTPClient(client *http.Client) *DcimLocation */ type DcimLocationsListParams struct { + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -273,6 +285,36 @@ type DcimLocationsListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + + // Tenant. + Tenant *string + + // Tenantn. + Tenantn *string + + // TenantGroup. + TenantGroup *string + + // TenantGroupn. + TenantGroupn *string + + // TenantGroupID. + TenantGroupID *string + + // TenantGroupIDn. + TenantGroupIDn *string + + // TenantID. + TenantID *string + + // TenantIDn. + TenantIDn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -326,6 +368,50 @@ func (o *DcimLocationsListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithContact adds the contact to the dcim locations list params +func (o *DcimLocationsListParams) WithContact(contact *string) *DcimLocationsListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the dcim locations list params +func (o *DcimLocationsListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the dcim locations list params +func (o *DcimLocationsListParams) WithContactn(contactn *string) *DcimLocationsListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the dcim locations list params +func (o *DcimLocationsListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the dcim locations list params +func (o *DcimLocationsListParams) WithContactRole(contactRole *string) *DcimLocationsListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the dcim locations list params +func (o *DcimLocationsListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the dcim locations list params +func (o *DcimLocationsListParams) WithContactRolen(contactRolen *string) *DcimLocationsListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the dcim locations list params +func (o *DcimLocationsListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the dcim locations list params func (o *DcimLocationsListParams) WithCreated(created *string) *DcimLocationsListParams { o.SetCreated(created) @@ -1030,6 +1116,116 @@ func (o *DcimLocationsListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the dcim locations list params +func (o *DcimLocationsListParams) WithTag(tag *string) *DcimLocationsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the dcim locations list params +func (o *DcimLocationsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the dcim locations list params +func (o *DcimLocationsListParams) WithTagn(tagn *string) *DcimLocationsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the dcim locations list params +func (o *DcimLocationsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + +// WithTenant adds the tenant to the dcim locations list params +func (o *DcimLocationsListParams) WithTenant(tenant *string) *DcimLocationsListParams { + o.SetTenant(tenant) + return o +} + +// SetTenant adds the tenant to the dcim locations list params +func (o *DcimLocationsListParams) SetTenant(tenant *string) { + o.Tenant = tenant +} + +// WithTenantn adds the tenantn to the dcim locations list params +func (o *DcimLocationsListParams) WithTenantn(tenantn *string) *DcimLocationsListParams { + o.SetTenantn(tenantn) + return o +} + +// SetTenantn adds the tenantN to the dcim locations list params +func (o *DcimLocationsListParams) SetTenantn(tenantn *string) { + o.Tenantn = tenantn +} + +// WithTenantGroup adds the tenantGroup to the dcim locations list params +func (o *DcimLocationsListParams) WithTenantGroup(tenantGroup *string) *DcimLocationsListParams { + o.SetTenantGroup(tenantGroup) + return o +} + +// SetTenantGroup adds the tenantGroup to the dcim locations list params +func (o *DcimLocationsListParams) SetTenantGroup(tenantGroup *string) { + o.TenantGroup = tenantGroup +} + +// WithTenantGroupn adds the tenantGroupn to the dcim locations list params +func (o *DcimLocationsListParams) WithTenantGroupn(tenantGroupn *string) *DcimLocationsListParams { + o.SetTenantGroupn(tenantGroupn) + return o +} + +// SetTenantGroupn adds the tenantGroupN to the dcim locations list params +func (o *DcimLocationsListParams) SetTenantGroupn(tenantGroupn *string) { + o.TenantGroupn = tenantGroupn +} + +// WithTenantGroupID adds the tenantGroupID to the dcim locations list params +func (o *DcimLocationsListParams) WithTenantGroupID(tenantGroupID *string) *DcimLocationsListParams { + o.SetTenantGroupID(tenantGroupID) + return o +} + +// SetTenantGroupID adds the tenantGroupId to the dcim locations list params +func (o *DcimLocationsListParams) SetTenantGroupID(tenantGroupID *string) { + o.TenantGroupID = tenantGroupID +} + +// WithTenantGroupIDn adds the tenantGroupIDn to the dcim locations list params +func (o *DcimLocationsListParams) WithTenantGroupIDn(tenantGroupIDn *string) *DcimLocationsListParams { + o.SetTenantGroupIDn(tenantGroupIDn) + return o +} + +// SetTenantGroupIDn adds the tenantGroupIdN to the dcim locations list params +func (o *DcimLocationsListParams) SetTenantGroupIDn(tenantGroupIDn *string) { + o.TenantGroupIDn = tenantGroupIDn +} + +// WithTenantID adds the tenantID to the dcim locations list params +func (o *DcimLocationsListParams) WithTenantID(tenantID *string) *DcimLocationsListParams { + o.SetTenantID(tenantID) + return o +} + +// SetTenantID adds the tenantId to the dcim locations list params +func (o *DcimLocationsListParams) SetTenantID(tenantID *string) { + o.TenantID = tenantID +} + +// WithTenantIDn adds the tenantIDn to the dcim locations list params +func (o *DcimLocationsListParams) WithTenantIDn(tenantIDn *string) *DcimLocationsListParams { + o.SetTenantIDn(tenantIDn) + return o +} + +// SetTenantIDn adds the tenantIdN to the dcim locations list params +func (o *DcimLocationsListParams) SetTenantIDn(tenantIDn *string) { + o.TenantIDn = tenantIDn +} + // WriteToRequest writes these params to a swagger request func (o *DcimLocationsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -1038,6 +1234,74 @@ func (o *DcimLocationsListParams) WriteToRequest(r runtime.ClientRequest, reg st } var res []error + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created @@ -2126,6 +2390,176 @@ func (o *DcimLocationsListParams) WriteToRequest(r runtime.ClientRequest, reg st } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + + if o.Tenant != nil { + + // query param tenant + var qrTenant string + + if o.Tenant != nil { + qrTenant = *o.Tenant + } + qTenant := qrTenant + if qTenant != "" { + + if err := r.SetQueryParam("tenant", qTenant); err != nil { + return err + } + } + } + + if o.Tenantn != nil { + + // query param tenant__n + var qrTenantn string + + if o.Tenantn != nil { + qrTenantn = *o.Tenantn + } + qTenantn := qrTenantn + if qTenantn != "" { + + if err := r.SetQueryParam("tenant__n", qTenantn); err != nil { + return err + } + } + } + + if o.TenantGroup != nil { + + // query param tenant_group + var qrTenantGroup string + + if o.TenantGroup != nil { + qrTenantGroup = *o.TenantGroup + } + qTenantGroup := qrTenantGroup + if qTenantGroup != "" { + + if err := r.SetQueryParam("tenant_group", qTenantGroup); err != nil { + return err + } + } + } + + if o.TenantGroupn != nil { + + // query param tenant_group__n + var qrTenantGroupn string + + if o.TenantGroupn != nil { + qrTenantGroupn = *o.TenantGroupn + } + qTenantGroupn := qrTenantGroupn + if qTenantGroupn != "" { + + if err := r.SetQueryParam("tenant_group__n", qTenantGroupn); err != nil { + return err + } + } + } + + if o.TenantGroupID != nil { + + // query param tenant_group_id + var qrTenantGroupID string + + if o.TenantGroupID != nil { + qrTenantGroupID = *o.TenantGroupID + } + qTenantGroupID := qrTenantGroupID + if qTenantGroupID != "" { + + if err := r.SetQueryParam("tenant_group_id", qTenantGroupID); err != nil { + return err + } + } + } + + if o.TenantGroupIDn != nil { + + // query param tenant_group_id__n + var qrTenantGroupIDn string + + if o.TenantGroupIDn != nil { + qrTenantGroupIDn = *o.TenantGroupIDn + } + qTenantGroupIDn := qrTenantGroupIDn + if qTenantGroupIDn != "" { + + if err := r.SetQueryParam("tenant_group_id__n", qTenantGroupIDn); err != nil { + return err + } + } + } + + if o.TenantID != nil { + + // query param tenant_id + var qrTenantID string + + if o.TenantID != nil { + qrTenantID = *o.TenantID + } + qTenantID := qrTenantID + if qTenantID != "" { + + if err := r.SetQueryParam("tenant_id", qTenantID); err != nil { + return err + } + } + } + + if o.TenantIDn != nil { + + // query param tenant_id__n + var qrTenantIDn string + + if o.TenantIDn != nil { + qrTenantIDn = *o.TenantIDn + } + qTenantIDn := qrTenantIDn + if qTenantIDn != "" { + + if err := r.SetQueryParam("tenant_id__n", qTenantIDn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/dcim/dcim_manufacturers_list_parameters.go b/netbox/client/dcim/dcim_manufacturers_list_parameters.go index 5bcd23b3..44c7f0f1 100644 --- a/netbox/client/dcim/dcim_manufacturers_list_parameters.go +++ b/netbox/client/dcim/dcim_manufacturers_list_parameters.go @@ -75,6 +75,18 @@ func NewDcimManufacturersListParamsWithHTTPClient(client *http.Client) *DcimManu */ type DcimManufacturersListParams struct { + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -225,6 +237,12 @@ type DcimManufacturersListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -278,6 +296,50 @@ func (o *DcimManufacturersListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithContact adds the contact to the dcim manufacturers list params +func (o *DcimManufacturersListParams) WithContact(contact *string) *DcimManufacturersListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the dcim manufacturers list params +func (o *DcimManufacturersListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the dcim manufacturers list params +func (o *DcimManufacturersListParams) WithContactn(contactn *string) *DcimManufacturersListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the dcim manufacturers list params +func (o *DcimManufacturersListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the dcim manufacturers list params +func (o *DcimManufacturersListParams) WithContactRole(contactRole *string) *DcimManufacturersListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the dcim manufacturers list params +func (o *DcimManufacturersListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the dcim manufacturers list params +func (o *DcimManufacturersListParams) WithContactRolen(contactRolen *string) *DcimManufacturersListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the dcim manufacturers list params +func (o *DcimManufacturersListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the dcim manufacturers list params func (o *DcimManufacturersListParams) WithCreated(created *string) *DcimManufacturersListParams { o.SetCreated(created) @@ -806,6 +868,28 @@ func (o *DcimManufacturersListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the dcim manufacturers list params +func (o *DcimManufacturersListParams) WithTag(tag *string) *DcimManufacturersListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the dcim manufacturers list params +func (o *DcimManufacturersListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the dcim manufacturers list params +func (o *DcimManufacturersListParams) WithTagn(tagn *string) *DcimManufacturersListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the dcim manufacturers list params +func (o *DcimManufacturersListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *DcimManufacturersListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -814,6 +898,74 @@ func (o *DcimManufacturersListParams) WriteToRequest(r runtime.ClientRequest, re } var res []error + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created @@ -1630,6 +1782,40 @@ func (o *DcimManufacturersListParams) WriteToRequest(r runtime.ClientRequest, re } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/dcim/dcim_platforms_list_parameters.go b/netbox/client/dcim/dcim_platforms_list_parameters.go index 9d587cc1..6e507a8b 100644 --- a/netbox/client/dcim/dcim_platforms_list_parameters.go +++ b/netbox/client/dcim/dcim_platforms_list_parameters.go @@ -270,6 +270,12 @@ type DcimPlatformsListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -1016,6 +1022,28 @@ func (o *DcimPlatformsListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the dcim platforms list params +func (o *DcimPlatformsListParams) WithTag(tag *string) *DcimPlatformsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the dcim platforms list params +func (o *DcimPlatformsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the dcim platforms list params +func (o *DcimPlatformsListParams) WithTagn(tagn *string) *DcimPlatformsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the dcim platforms list params +func (o *DcimPlatformsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *DcimPlatformsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -2095,6 +2123,40 @@ func (o *DcimPlatformsListParams) WriteToRequest(r runtime.ClientRequest, reg st } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/dcim/dcim_power_panels_list_parameters.go b/netbox/client/dcim/dcim_power_panels_list_parameters.go index a0742661..15dbb514 100644 --- a/netbox/client/dcim/dcim_power_panels_list_parameters.go +++ b/netbox/client/dcim/dcim_power_panels_list_parameters.go @@ -75,6 +75,18 @@ func NewDcimPowerPanelsListParamsWithHTTPClient(client *http.Client) *DcimPowerP */ type DcimPowerPanelsListParams struct { + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -260,6 +272,50 @@ func (o *DcimPowerPanelsListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithContact adds the contact to the dcim power panels list params +func (o *DcimPowerPanelsListParams) WithContact(contact *string) *DcimPowerPanelsListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the dcim power panels list params +func (o *DcimPowerPanelsListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the dcim power panels list params +func (o *DcimPowerPanelsListParams) WithContactn(contactn *string) *DcimPowerPanelsListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the dcim power panels list params +func (o *DcimPowerPanelsListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the dcim power panels list params +func (o *DcimPowerPanelsListParams) WithContactRole(contactRole *string) *DcimPowerPanelsListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the dcim power panels list params +func (o *DcimPowerPanelsListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the dcim power panels list params +func (o *DcimPowerPanelsListParams) WithContactRolen(contactRolen *string) *DcimPowerPanelsListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the dcim power panels list params +func (o *DcimPowerPanelsListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the dcim power panels list params func (o *DcimPowerPanelsListParams) WithCreated(created *string) *DcimPowerPanelsListParams { o.SetCreated(created) @@ -730,6 +786,74 @@ func (o *DcimPowerPanelsListParams) WriteToRequest(r runtime.ClientRequest, reg } var res []error + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created diff --git a/netbox/client/dcim/dcim_rack_reservations_list_parameters.go b/netbox/client/dcim/dcim_rack_reservations_list_parameters.go index 7226ca8b..17bb090a 100644 --- a/netbox/client/dcim/dcim_rack_reservations_list_parameters.go +++ b/netbox/client/dcim/dcim_rack_reservations_list_parameters.go @@ -84,6 +84,39 @@ type DcimRackReservationsListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // ID. ID *string @@ -284,6 +317,127 @@ func (o *DcimRackReservationsListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) WithDescription(description *string) *DcimRackReservationsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) WithDescriptionEmpty(descriptionEmpty *string) *DcimRackReservationsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) WithDescriptionIc(descriptionIc *string) *DcimRackReservationsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) WithDescriptionIe(descriptionIe *string) *DcimRackReservationsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) WithDescriptionIew(descriptionIew *string) *DcimRackReservationsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) WithDescriptionIsw(descriptionIsw *string) *DcimRackReservationsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) WithDescriptionn(descriptionn *string) *DcimRackReservationsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) WithDescriptionNic(descriptionNic *string) *DcimRackReservationsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) WithDescriptionNie(descriptionNie *string) *DcimRackReservationsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) WithDescriptionNiew(descriptionNiew *string) *DcimRackReservationsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) WithDescriptionNisw(descriptionNisw *string) *DcimRackReservationsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the dcim rack reservations list params +func (o *DcimRackReservationsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithID adds the id to the dcim rack reservations list params func (o *DcimRackReservationsListParams) WithID(id *string) *DcimRackReservationsListParams { o.SetID(id) @@ -739,6 +893,193 @@ func (o *DcimRackReservationsListParams) WriteToRequest(r runtime.ClientRequest, } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.ID != nil { // query param id diff --git a/netbox/client/dcim/dcim_rack_roles_list_parameters.go b/netbox/client/dcim/dcim_rack_roles_list_parameters.go index fca2c19f..3d5149ac 100644 --- a/netbox/client/dcim/dcim_rack_roles_list_parameters.go +++ b/netbox/client/dcim/dcim_rack_roles_list_parameters.go @@ -117,6 +117,39 @@ type DcimRackRolesListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // ID. ID *string @@ -225,6 +258,12 @@ type DcimRackRolesListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -432,6 +471,127 @@ func (o *DcimRackRolesListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithDescription(description *string) *DcimRackRolesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithDescriptionEmpty(descriptionEmpty *string) *DcimRackRolesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithDescriptionIc(descriptionIc *string) *DcimRackRolesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithDescriptionIe(descriptionIe *string) *DcimRackRolesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithDescriptionIew(descriptionIew *string) *DcimRackRolesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithDescriptionIsw(descriptionIsw *string) *DcimRackRolesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithDescriptionn(descriptionn *string) *DcimRackRolesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithDescriptionNic(descriptionNic *string) *DcimRackRolesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithDescriptionNie(descriptionNie *string) *DcimRackRolesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithDescriptionNiew(descriptionNiew *string) *DcimRackRolesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithDescriptionNisw(descriptionNisw *string) *DcimRackRolesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithID adds the id to the dcim rack roles list params func (o *DcimRackRolesListParams) WithID(id *string) *DcimRackRolesListParams { o.SetID(id) @@ -806,6 +966,28 @@ func (o *DcimRackRolesListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithTag(tag *string) *DcimRackRolesListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the dcim rack roles list params +func (o *DcimRackRolesListParams) WithTagn(tagn *string) *DcimRackRolesListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the dcim rack roles list params +func (o *DcimRackRolesListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *DcimRackRolesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -1052,6 +1234,193 @@ func (o *DcimRackRolesListParams) WriteToRequest(r runtime.ClientRequest, reg st } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.ID != nil { // query param id @@ -1630,6 +1999,40 @@ func (o *DcimRackRolesListParams) WriteToRequest(r runtime.ClientRequest, reg st } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/dcim/dcim_racks_list_parameters.go b/netbox/client/dcim/dcim_racks_list_parameters.go index dd063c9a..bc84b4c5 100644 --- a/netbox/client/dcim/dcim_racks_list_parameters.go +++ b/netbox/client/dcim/dcim_racks_list_parameters.go @@ -108,6 +108,18 @@ type DcimRacksListParams struct { // AssetTagNisw. AssetTagNisw *string + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -573,6 +585,50 @@ func (o *DcimRacksListParams) SetAssetTagNisw(assetTagNisw *string) { o.AssetTagNisw = assetTagNisw } +// WithContact adds the contact to the dcim racks list params +func (o *DcimRacksListParams) WithContact(contact *string) *DcimRacksListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the dcim racks list params +func (o *DcimRacksListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the dcim racks list params +func (o *DcimRacksListParams) WithContactn(contactn *string) *DcimRacksListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the dcim racks list params +func (o *DcimRacksListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the dcim racks list params +func (o *DcimRacksListParams) WithContactRole(contactRole *string) *DcimRacksListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the dcim racks list params +func (o *DcimRacksListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the dcim racks list params +func (o *DcimRacksListParams) WithContactRolen(contactRolen *string) *DcimRacksListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the dcim racks list params +func (o *DcimRacksListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the dcim racks list params func (o *DcimRacksListParams) WithCreated(created *string) *DcimRacksListParams { o.SetCreated(created) @@ -1813,6 +1869,74 @@ func (o *DcimRacksListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt } } + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created diff --git a/netbox/client/dcim/dcim_regions_list_parameters.go b/netbox/client/dcim/dcim_regions_list_parameters.go index 83de7ac3..22ddc82a 100644 --- a/netbox/client/dcim/dcim_regions_list_parameters.go +++ b/netbox/client/dcim/dcim_regions_list_parameters.go @@ -75,6 +75,18 @@ func NewDcimRegionsListParamsWithHTTPClient(client *http.Client) *DcimRegionsLis */ type DcimRegionsListParams struct { + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -237,6 +249,12 @@ type DcimRegionsListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -290,6 +308,50 @@ func (o *DcimRegionsListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithContact adds the contact to the dcim regions list params +func (o *DcimRegionsListParams) WithContact(contact *string) *DcimRegionsListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the dcim regions list params +func (o *DcimRegionsListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the dcim regions list params +func (o *DcimRegionsListParams) WithContactn(contactn *string) *DcimRegionsListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the dcim regions list params +func (o *DcimRegionsListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the dcim regions list params +func (o *DcimRegionsListParams) WithContactRole(contactRole *string) *DcimRegionsListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the dcim regions list params +func (o *DcimRegionsListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the dcim regions list params +func (o *DcimRegionsListParams) WithContactRolen(contactRolen *string) *DcimRegionsListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the dcim regions list params +func (o *DcimRegionsListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the dcim regions list params func (o *DcimRegionsListParams) WithCreated(created *string) *DcimRegionsListParams { o.SetCreated(created) @@ -862,6 +924,28 @@ func (o *DcimRegionsListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the dcim regions list params +func (o *DcimRegionsListParams) WithTag(tag *string) *DcimRegionsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the dcim regions list params +func (o *DcimRegionsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the dcim regions list params +func (o *DcimRegionsListParams) WithTagn(tagn *string) *DcimRegionsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the dcim regions list params +func (o *DcimRegionsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *DcimRegionsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -870,6 +954,74 @@ func (o *DcimRegionsListParams) WriteToRequest(r runtime.ClientRequest, reg strf } var res []error + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created @@ -1754,6 +1906,40 @@ func (o *DcimRegionsListParams) WriteToRequest(r runtime.ClientRequest, reg strf } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/dcim/dcim_site_groups_list_parameters.go b/netbox/client/dcim/dcim_site_groups_list_parameters.go index e9210cab..756832e3 100644 --- a/netbox/client/dcim/dcim_site_groups_list_parameters.go +++ b/netbox/client/dcim/dcim_site_groups_list_parameters.go @@ -75,6 +75,18 @@ func NewDcimSiteGroupsListParamsWithHTTPClient(client *http.Client) *DcimSiteGro */ type DcimSiteGroupsListParams struct { + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -237,6 +249,12 @@ type DcimSiteGroupsListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -290,6 +308,50 @@ func (o *DcimSiteGroupsListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithContact adds the contact to the dcim site groups list params +func (o *DcimSiteGroupsListParams) WithContact(contact *string) *DcimSiteGroupsListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the dcim site groups list params +func (o *DcimSiteGroupsListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the dcim site groups list params +func (o *DcimSiteGroupsListParams) WithContactn(contactn *string) *DcimSiteGroupsListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the dcim site groups list params +func (o *DcimSiteGroupsListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the dcim site groups list params +func (o *DcimSiteGroupsListParams) WithContactRole(contactRole *string) *DcimSiteGroupsListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the dcim site groups list params +func (o *DcimSiteGroupsListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the dcim site groups list params +func (o *DcimSiteGroupsListParams) WithContactRolen(contactRolen *string) *DcimSiteGroupsListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the dcim site groups list params +func (o *DcimSiteGroupsListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the dcim site groups list params func (o *DcimSiteGroupsListParams) WithCreated(created *string) *DcimSiteGroupsListParams { o.SetCreated(created) @@ -862,6 +924,28 @@ func (o *DcimSiteGroupsListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the dcim site groups list params +func (o *DcimSiteGroupsListParams) WithTag(tag *string) *DcimSiteGroupsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the dcim site groups list params +func (o *DcimSiteGroupsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the dcim site groups list params +func (o *DcimSiteGroupsListParams) WithTagn(tagn *string) *DcimSiteGroupsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the dcim site groups list params +func (o *DcimSiteGroupsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *DcimSiteGroupsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -870,6 +954,74 @@ func (o *DcimSiteGroupsListParams) WriteToRequest(r runtime.ClientRequest, reg s } var res []error + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created @@ -1754,6 +1906,40 @@ func (o *DcimSiteGroupsListParams) WriteToRequest(r runtime.ClientRequest, reg s } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/dcim/dcim_sites_list_parameters.go b/netbox/client/dcim/dcim_sites_list_parameters.go index fef32775..48ef2d44 100644 --- a/netbox/client/dcim/dcim_sites_list_parameters.go +++ b/netbox/client/dcim/dcim_sites_list_parameters.go @@ -93,6 +93,18 @@ type DcimSitesListParams struct { // Asnn. Asnn *string + // AsnID. + AsnID *string + + // AsnIDn. + AsnIDn *string + + // Contact. + Contact *string + + // Contactn. + Contactn *string + // ContactEmail. ContactEmail *string @@ -192,6 +204,12 @@ type DcimSitesListParams struct { // ContactPhoneNisw. ContactPhoneNisw *string + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -201,6 +219,39 @@ type DcimSitesListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // Facility. Facility *string @@ -557,6 +608,50 @@ func (o *DcimSitesListParams) SetAsnn(asnn *string) { o.Asnn = asnn } +// WithAsnID adds the asnID to the dcim sites list params +func (o *DcimSitesListParams) WithAsnID(asnID *string) *DcimSitesListParams { + o.SetAsnID(asnID) + return o +} + +// SetAsnID adds the asnId to the dcim sites list params +func (o *DcimSitesListParams) SetAsnID(asnID *string) { + o.AsnID = asnID +} + +// WithAsnIDn adds the asnIDn to the dcim sites list params +func (o *DcimSitesListParams) WithAsnIDn(asnIDn *string) *DcimSitesListParams { + o.SetAsnIDn(asnIDn) + return o +} + +// SetAsnIDn adds the asnIdN to the dcim sites list params +func (o *DcimSitesListParams) SetAsnIDn(asnIDn *string) { + o.AsnIDn = asnIDn +} + +// WithContact adds the contact to the dcim sites list params +func (o *DcimSitesListParams) WithContact(contact *string) *DcimSitesListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the dcim sites list params +func (o *DcimSitesListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the dcim sites list params +func (o *DcimSitesListParams) WithContactn(contactn *string) *DcimSitesListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the dcim sites list params +func (o *DcimSitesListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + // WithContactEmail adds the contactEmail to the dcim sites list params func (o *DcimSitesListParams) WithContactEmail(contactEmail *string) *DcimSitesListParams { o.SetContactEmail(contactEmail) @@ -920,6 +1015,28 @@ func (o *DcimSitesListParams) SetContactPhoneNisw(contactPhoneNisw *string) { o.ContactPhoneNisw = contactPhoneNisw } +// WithContactRole adds the contactRole to the dcim sites list params +func (o *DcimSitesListParams) WithContactRole(contactRole *string) *DcimSitesListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the dcim sites list params +func (o *DcimSitesListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the dcim sites list params +func (o *DcimSitesListParams) WithContactRolen(contactRolen *string) *DcimSitesListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the dcim sites list params +func (o *DcimSitesListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the dcim sites list params func (o *DcimSitesListParams) WithCreated(created *string) *DcimSitesListParams { o.SetCreated(created) @@ -953,6 +1070,127 @@ func (o *DcimSitesListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the dcim sites list params +func (o *DcimSitesListParams) WithDescription(description *string) *DcimSitesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the dcim sites list params +func (o *DcimSitesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the dcim sites list params +func (o *DcimSitesListParams) WithDescriptionEmpty(descriptionEmpty *string) *DcimSitesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the dcim sites list params +func (o *DcimSitesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the dcim sites list params +func (o *DcimSitesListParams) WithDescriptionIc(descriptionIc *string) *DcimSitesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the dcim sites list params +func (o *DcimSitesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the dcim sites list params +func (o *DcimSitesListParams) WithDescriptionIe(descriptionIe *string) *DcimSitesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the dcim sites list params +func (o *DcimSitesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the dcim sites list params +func (o *DcimSitesListParams) WithDescriptionIew(descriptionIew *string) *DcimSitesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the dcim sites list params +func (o *DcimSitesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the dcim sites list params +func (o *DcimSitesListParams) WithDescriptionIsw(descriptionIsw *string) *DcimSitesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the dcim sites list params +func (o *DcimSitesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the dcim sites list params +func (o *DcimSitesListParams) WithDescriptionn(descriptionn *string) *DcimSitesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the dcim sites list params +func (o *DcimSitesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the dcim sites list params +func (o *DcimSitesListParams) WithDescriptionNic(descriptionNic *string) *DcimSitesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the dcim sites list params +func (o *DcimSitesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the dcim sites list params +func (o *DcimSitesListParams) WithDescriptionNie(descriptionNie *string) *DcimSitesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the dcim sites list params +func (o *DcimSitesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the dcim sites list params +func (o *DcimSitesListParams) WithDescriptionNiew(descriptionNiew *string) *DcimSitesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the dcim sites list params +func (o *DcimSitesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the dcim sites list params +func (o *DcimSitesListParams) WithDescriptionNisw(descriptionNisw *string) *DcimSitesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the dcim sites list params +func (o *DcimSitesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithFacility adds the facility to the dcim sites list params func (o *DcimSitesListParams) WithFacility(facility *string) *DcimSitesListParams { o.SetFacility(facility) @@ -1910,6 +2148,74 @@ func (o *DcimSitesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt } } + if o.AsnID != nil { + + // query param asn_id + var qrAsnID string + + if o.AsnID != nil { + qrAsnID = *o.AsnID + } + qAsnID := qrAsnID + if qAsnID != "" { + + if err := r.SetQueryParam("asn_id", qAsnID); err != nil { + return err + } + } + } + + if o.AsnIDn != nil { + + // query param asn_id__n + var qrAsnIDn string + + if o.AsnIDn != nil { + qrAsnIDn = *o.AsnIDn + } + qAsnIDn := qrAsnIDn + if qAsnIDn != "" { + + if err := r.SetQueryParam("asn_id__n", qAsnIDn); err != nil { + return err + } + } + } + + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + if o.ContactEmail != nil { // query param contact_email @@ -2471,6 +2777,40 @@ func (o *DcimSitesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt } } + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created @@ -2522,6 +2862,193 @@ func (o *DcimSitesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.Facility != nil { // query param facility diff --git a/netbox/client/extras/extras_config_contexts_list_parameters.go b/netbox/client/extras/extras_config_contexts_list_parameters.go index 4b5f95e1..9b4ccdd2 100644 --- a/netbox/client/extras/extras_config_contexts_list_parameters.go +++ b/netbox/client/extras/extras_config_contexts_list_parameters.go @@ -252,6 +252,12 @@ type ExtrasConfigContextsListParams struct { // Tagn. Tagn *string + // TagID. + TagID *string + + // TagIDn. + TagIDn *string + // Tenant. Tenant *string @@ -956,6 +962,28 @@ func (o *ExtrasConfigContextsListParams) SetTagn(tagn *string) { o.Tagn = tagn } +// WithTagID adds the tagID to the extras config contexts list params +func (o *ExtrasConfigContextsListParams) WithTagID(tagID *string) *ExtrasConfigContextsListParams { + o.SetTagID(tagID) + return o +} + +// SetTagID adds the tagId to the extras config contexts list params +func (o *ExtrasConfigContextsListParams) SetTagID(tagID *string) { + o.TagID = tagID +} + +// WithTagIDn adds the tagIDn to the extras config contexts list params +func (o *ExtrasConfigContextsListParams) WithTagIDn(tagIDn *string) *ExtrasConfigContextsListParams { + o.SetTagIDn(tagIDn) + return o +} + +// SetTagIDn adds the tagIdN to the extras config contexts list params +func (o *ExtrasConfigContextsListParams) SetTagIDn(tagIDn *string) { + o.TagIDn = tagIDn +} + // WithTenant adds the tenant to the extras config contexts list params func (o *ExtrasConfigContextsListParams) WithTenant(tenant *string) *ExtrasConfigContextsListParams { o.SetTenant(tenant) @@ -2021,6 +2049,40 @@ func (o *ExtrasConfigContextsListParams) WriteToRequest(r runtime.ClientRequest, } } + if o.TagID != nil { + + // query param tag_id + var qrTagID string + + if o.TagID != nil { + qrTagID = *o.TagID + } + qTagID := qrTagID + if qTagID != "" { + + if err := r.SetQueryParam("tag_id", qTagID); err != nil { + return err + } + } + } + + if o.TagIDn != nil { + + // query param tag_id__n + var qrTagIDn string + + if o.TagIDn != nil { + qrTagIDn = *o.TagIDn + } + qTagIDn := qrTagIDn + if qTagIDn != "" { + + if err := r.SetQueryParam("tag_id__n", qTagIDn); err != nil { + return err + } + } + } + if o.Tenant != nil { // query param tenant diff --git a/netbox/client/extras/extras_custom_fields_list_parameters.go b/netbox/client/extras/extras_custom_fields_list_parameters.go index a84a62c5..115919b0 100644 --- a/netbox/client/extras/extras_custom_fields_list_parameters.go +++ b/netbox/client/extras/extras_custom_fields_list_parameters.go @@ -105,6 +105,39 @@ type ExtrasCustomFieldsListParams struct { // ContentTypesNisw. ContentTypesNisw *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // FilterLogic. FilterLogic *string @@ -361,6 +394,127 @@ func (o *ExtrasCustomFieldsListParams) SetContentTypesNisw(contentTypesNisw *str o.ContentTypesNisw = contentTypesNisw } +// WithDescription adds the description to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) WithDescription(description *string) *ExtrasCustomFieldsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) WithDescriptionEmpty(descriptionEmpty *string) *ExtrasCustomFieldsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) WithDescriptionIc(descriptionIc *string) *ExtrasCustomFieldsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) WithDescriptionIe(descriptionIe *string) *ExtrasCustomFieldsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) WithDescriptionIew(descriptionIew *string) *ExtrasCustomFieldsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) WithDescriptionIsw(descriptionIsw *string) *ExtrasCustomFieldsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) WithDescriptionn(descriptionn *string) *ExtrasCustomFieldsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) WithDescriptionNic(descriptionNic *string) *ExtrasCustomFieldsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) WithDescriptionNie(descriptionNie *string) *ExtrasCustomFieldsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) WithDescriptionNiew(descriptionNiew *string) *ExtrasCustomFieldsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) WithDescriptionNisw(descriptionNisw *string) *ExtrasCustomFieldsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the extras custom fields list params +func (o *ExtrasCustomFieldsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithFilterLogic adds the filterLogic to the extras custom fields list params func (o *ExtrasCustomFieldsListParams) WithFilterLogic(filterLogic *string) *ExtrasCustomFieldsListParams { o.SetFilterLogic(filterLogic) @@ -858,6 +1012,193 @@ func (o *ExtrasCustomFieldsListParams) WriteToRequest(r runtime.ClientRequest, r } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.FilterLogic != nil { // query param filter_logic diff --git a/netbox/client/extras/extras_export_templates_list_parameters.go b/netbox/client/extras/extras_export_templates_list_parameters.go index 9a604811..70d923a5 100644 --- a/netbox/client/extras/extras_export_templates_list_parameters.go +++ b/netbox/client/extras/extras_export_templates_list_parameters.go @@ -81,6 +81,39 @@ type ExtrasExportTemplatesListParams struct { // ContentTypen. ContentTypen *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // ID. ID *string @@ -222,6 +255,127 @@ func (o *ExtrasExportTemplatesListParams) SetContentTypen(contentTypen *string) o.ContentTypen = contentTypen } +// WithDescription adds the description to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) WithDescription(description *string) *ExtrasExportTemplatesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) WithDescriptionEmpty(descriptionEmpty *string) *ExtrasExportTemplatesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) WithDescriptionIc(descriptionIc *string) *ExtrasExportTemplatesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) WithDescriptionIe(descriptionIe *string) *ExtrasExportTemplatesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) WithDescriptionIew(descriptionIew *string) *ExtrasExportTemplatesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) WithDescriptionIsw(descriptionIsw *string) *ExtrasExportTemplatesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) WithDescriptionn(descriptionn *string) *ExtrasExportTemplatesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) WithDescriptionNic(descriptionNic *string) *ExtrasExportTemplatesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) WithDescriptionNie(descriptionNie *string) *ExtrasExportTemplatesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) WithDescriptionNiew(descriptionNiew *string) *ExtrasExportTemplatesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) WithDescriptionNisw(descriptionNisw *string) *ExtrasExportTemplatesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the extras export templates list params +func (o *ExtrasExportTemplatesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithID adds the id to the extras export templates list params func (o *ExtrasExportTemplatesListParams) WithID(id *string) *ExtrasExportTemplatesListParams { o.SetID(id) @@ -484,6 +638,193 @@ func (o *ExtrasExportTemplatesListParams) WriteToRequest(r runtime.ClientRequest } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.ID != nil { // query param id diff --git a/netbox/client/extras/extras_tags_list_parameters.go b/netbox/client/extras/extras_tags_list_parameters.go index bd31e9cb..cfc68236 100644 --- a/netbox/client/extras/extras_tags_list_parameters.go +++ b/netbox/client/extras/extras_tags_list_parameters.go @@ -123,6 +123,39 @@ type ExtrasTagsListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // ID. ID *string @@ -460,6 +493,127 @@ func (o *ExtrasTagsListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the extras tags list params +func (o *ExtrasTagsListParams) WithDescription(description *string) *ExtrasTagsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the extras tags list params +func (o *ExtrasTagsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the extras tags list params +func (o *ExtrasTagsListParams) WithDescriptionEmpty(descriptionEmpty *string) *ExtrasTagsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the extras tags list params +func (o *ExtrasTagsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the extras tags list params +func (o *ExtrasTagsListParams) WithDescriptionIc(descriptionIc *string) *ExtrasTagsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the extras tags list params +func (o *ExtrasTagsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the extras tags list params +func (o *ExtrasTagsListParams) WithDescriptionIe(descriptionIe *string) *ExtrasTagsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the extras tags list params +func (o *ExtrasTagsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the extras tags list params +func (o *ExtrasTagsListParams) WithDescriptionIew(descriptionIew *string) *ExtrasTagsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the extras tags list params +func (o *ExtrasTagsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the extras tags list params +func (o *ExtrasTagsListParams) WithDescriptionIsw(descriptionIsw *string) *ExtrasTagsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the extras tags list params +func (o *ExtrasTagsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the extras tags list params +func (o *ExtrasTagsListParams) WithDescriptionn(descriptionn *string) *ExtrasTagsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the extras tags list params +func (o *ExtrasTagsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the extras tags list params +func (o *ExtrasTagsListParams) WithDescriptionNic(descriptionNic *string) *ExtrasTagsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the extras tags list params +func (o *ExtrasTagsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the extras tags list params +func (o *ExtrasTagsListParams) WithDescriptionNie(descriptionNie *string) *ExtrasTagsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the extras tags list params +func (o *ExtrasTagsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the extras tags list params +func (o *ExtrasTagsListParams) WithDescriptionNiew(descriptionNiew *string) *ExtrasTagsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the extras tags list params +func (o *ExtrasTagsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the extras tags list params +func (o *ExtrasTagsListParams) WithDescriptionNisw(descriptionNisw *string) *ExtrasTagsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the extras tags list params +func (o *ExtrasTagsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithID adds the id to the extras tags list params func (o *ExtrasTagsListParams) WithID(id *string) *ExtrasTagsListParams { o.SetID(id) @@ -1114,6 +1268,193 @@ func (o *ExtrasTagsListParams) WriteToRequest(r runtime.ClientRequest, reg strfm } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.ID != nil { // query param id diff --git a/netbox/client/ipam/ipam_aggregates_list_parameters.go b/netbox/client/ipam/ipam_aggregates_list_parameters.go index e0f7edb0..592f05d5 100644 --- a/netbox/client/ipam/ipam_aggregates_list_parameters.go +++ b/netbox/client/ipam/ipam_aggregates_list_parameters.go @@ -102,6 +102,39 @@ type IpamAggregatesListParams struct { // DateAddedn. DateAddedn *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // Family. Family *float64 @@ -344,6 +377,127 @@ func (o *IpamAggregatesListParams) SetDateAddedn(dateAddedn *string) { o.DateAddedn = dateAddedn } +// WithDescription adds the description to the ipam aggregates list params +func (o *IpamAggregatesListParams) WithDescription(description *string) *IpamAggregatesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the ipam aggregates list params +func (o *IpamAggregatesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the ipam aggregates list params +func (o *IpamAggregatesListParams) WithDescriptionEmpty(descriptionEmpty *string) *IpamAggregatesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the ipam aggregates list params +func (o *IpamAggregatesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the ipam aggregates list params +func (o *IpamAggregatesListParams) WithDescriptionIc(descriptionIc *string) *IpamAggregatesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the ipam aggregates list params +func (o *IpamAggregatesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the ipam aggregates list params +func (o *IpamAggregatesListParams) WithDescriptionIe(descriptionIe *string) *IpamAggregatesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the ipam aggregates list params +func (o *IpamAggregatesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the ipam aggregates list params +func (o *IpamAggregatesListParams) WithDescriptionIew(descriptionIew *string) *IpamAggregatesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the ipam aggregates list params +func (o *IpamAggregatesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the ipam aggregates list params +func (o *IpamAggregatesListParams) WithDescriptionIsw(descriptionIsw *string) *IpamAggregatesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the ipam aggregates list params +func (o *IpamAggregatesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the ipam aggregates list params +func (o *IpamAggregatesListParams) WithDescriptionn(descriptionn *string) *IpamAggregatesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the ipam aggregates list params +func (o *IpamAggregatesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the ipam aggregates list params +func (o *IpamAggregatesListParams) WithDescriptionNic(descriptionNic *string) *IpamAggregatesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the ipam aggregates list params +func (o *IpamAggregatesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the ipam aggregates list params +func (o *IpamAggregatesListParams) WithDescriptionNie(descriptionNie *string) *IpamAggregatesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the ipam aggregates list params +func (o *IpamAggregatesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the ipam aggregates list params +func (o *IpamAggregatesListParams) WithDescriptionNiew(descriptionNiew *string) *IpamAggregatesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the ipam aggregates list params +func (o *IpamAggregatesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the ipam aggregates list params +func (o *IpamAggregatesListParams) WithDescriptionNisw(descriptionNisw *string) *IpamAggregatesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the ipam aggregates list params +func (o *IpamAggregatesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithFamily adds the family to the ipam aggregates list params func (o *IpamAggregatesListParams) WithFamily(family *float64) *IpamAggregatesListParams { o.SetFamily(family) @@ -813,6 +967,193 @@ func (o *IpamAggregatesListParams) WriteToRequest(r runtime.ClientRequest, reg s } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.Family != nil { // query param family diff --git a/netbox/client/ipam/ipam_asns_bulk_delete_parameters.go b/netbox/client/ipam/ipam_asns_bulk_delete_parameters.go new file mode 100644 index 00000000..6368d187 --- /dev/null +++ b/netbox/client/ipam/ipam_asns_bulk_delete_parameters.go @@ -0,0 +1,141 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewIpamAsnsBulkDeleteParams creates a new IpamAsnsBulkDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamAsnsBulkDeleteParams() *IpamAsnsBulkDeleteParams { + return &IpamAsnsBulkDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamAsnsBulkDeleteParamsWithTimeout creates a new IpamAsnsBulkDeleteParams object +// with the ability to set a timeout on a request. +func NewIpamAsnsBulkDeleteParamsWithTimeout(timeout time.Duration) *IpamAsnsBulkDeleteParams { + return &IpamAsnsBulkDeleteParams{ + timeout: timeout, + } +} + +// NewIpamAsnsBulkDeleteParamsWithContext creates a new IpamAsnsBulkDeleteParams object +// with the ability to set a context for a request. +func NewIpamAsnsBulkDeleteParamsWithContext(ctx context.Context) *IpamAsnsBulkDeleteParams { + return &IpamAsnsBulkDeleteParams{ + Context: ctx, + } +} + +// NewIpamAsnsBulkDeleteParamsWithHTTPClient creates a new IpamAsnsBulkDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamAsnsBulkDeleteParamsWithHTTPClient(client *http.Client) *IpamAsnsBulkDeleteParams { + return &IpamAsnsBulkDeleteParams{ + HTTPClient: client, + } +} + +/* IpamAsnsBulkDeleteParams contains all the parameters to send to the API endpoint + for the ipam asns bulk delete operation. + + Typically these are written to a http.Request. +*/ +type IpamAsnsBulkDeleteParams struct { + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam asns bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsBulkDeleteParams) WithDefaults() *IpamAsnsBulkDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam asns bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsBulkDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam asns bulk delete params +func (o *IpamAsnsBulkDeleteParams) WithTimeout(timeout time.Duration) *IpamAsnsBulkDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam asns bulk delete params +func (o *IpamAsnsBulkDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam asns bulk delete params +func (o *IpamAsnsBulkDeleteParams) WithContext(ctx context.Context) *IpamAsnsBulkDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam asns bulk delete params +func (o *IpamAsnsBulkDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam asns bulk delete params +func (o *IpamAsnsBulkDeleteParams) WithHTTPClient(client *http.Client) *IpamAsnsBulkDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam asns bulk delete params +func (o *IpamAsnsBulkDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamAsnsBulkDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_asns_bulk_delete_responses.go b/netbox/client/ipam/ipam_asns_bulk_delete_responses.go new file mode 100644 index 00000000..b2105e1a --- /dev/null +++ b/netbox/client/ipam/ipam_asns_bulk_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// IpamAsnsBulkDeleteReader is a Reader for the IpamAsnsBulkDelete structure. +type IpamAsnsBulkDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamAsnsBulkDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewIpamAsnsBulkDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamAsnsBulkDeleteNoContent creates a IpamAsnsBulkDeleteNoContent with default headers values +func NewIpamAsnsBulkDeleteNoContent() *IpamAsnsBulkDeleteNoContent { + return &IpamAsnsBulkDeleteNoContent{} +} + +/* IpamAsnsBulkDeleteNoContent describes a response with status code 204, with default header values. + +IpamAsnsBulkDeleteNoContent ipam asns bulk delete no content +*/ +type IpamAsnsBulkDeleteNoContent struct { +} + +func (o *IpamAsnsBulkDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /ipam/asns/][%d] ipamAsnsBulkDeleteNoContent ", 204) +} + +func (o *IpamAsnsBulkDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/ipam/ipam_asns_bulk_partial_update_parameters.go b/netbox/client/ipam/ipam_asns_bulk_partial_update_parameters.go new file mode 100644 index 00000000..0a7d9917 --- /dev/null +++ b/netbox/client/ipam/ipam_asns_bulk_partial_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamAsnsBulkPartialUpdateParams creates a new IpamAsnsBulkPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamAsnsBulkPartialUpdateParams() *IpamAsnsBulkPartialUpdateParams { + return &IpamAsnsBulkPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamAsnsBulkPartialUpdateParamsWithTimeout creates a new IpamAsnsBulkPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamAsnsBulkPartialUpdateParamsWithTimeout(timeout time.Duration) *IpamAsnsBulkPartialUpdateParams { + return &IpamAsnsBulkPartialUpdateParams{ + timeout: timeout, + } +} + +// NewIpamAsnsBulkPartialUpdateParamsWithContext creates a new IpamAsnsBulkPartialUpdateParams object +// with the ability to set a context for a request. +func NewIpamAsnsBulkPartialUpdateParamsWithContext(ctx context.Context) *IpamAsnsBulkPartialUpdateParams { + return &IpamAsnsBulkPartialUpdateParams{ + Context: ctx, + } +} + +// NewIpamAsnsBulkPartialUpdateParamsWithHTTPClient creates a new IpamAsnsBulkPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamAsnsBulkPartialUpdateParamsWithHTTPClient(client *http.Client) *IpamAsnsBulkPartialUpdateParams { + return &IpamAsnsBulkPartialUpdateParams{ + HTTPClient: client, + } +} + +/* IpamAsnsBulkPartialUpdateParams contains all the parameters to send to the API endpoint + for the ipam asns bulk partial update operation. + + Typically these are written to a http.Request. +*/ +type IpamAsnsBulkPartialUpdateParams struct { + + // Data. + Data *models.WritableASN + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam asns bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsBulkPartialUpdateParams) WithDefaults() *IpamAsnsBulkPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam asns bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsBulkPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam asns bulk partial update params +func (o *IpamAsnsBulkPartialUpdateParams) WithTimeout(timeout time.Duration) *IpamAsnsBulkPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam asns bulk partial update params +func (o *IpamAsnsBulkPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam asns bulk partial update params +func (o *IpamAsnsBulkPartialUpdateParams) WithContext(ctx context.Context) *IpamAsnsBulkPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam asns bulk partial update params +func (o *IpamAsnsBulkPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam asns bulk partial update params +func (o *IpamAsnsBulkPartialUpdateParams) WithHTTPClient(client *http.Client) *IpamAsnsBulkPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam asns bulk partial update params +func (o *IpamAsnsBulkPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam asns bulk partial update params +func (o *IpamAsnsBulkPartialUpdateParams) WithData(data *models.WritableASN) *IpamAsnsBulkPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam asns bulk partial update params +func (o *IpamAsnsBulkPartialUpdateParams) SetData(data *models.WritableASN) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamAsnsBulkPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_asns_bulk_partial_update_responses.go b/netbox/client/ipam/ipam_asns_bulk_partial_update_responses.go new file mode 100644 index 00000000..7154480f --- /dev/null +++ b/netbox/client/ipam/ipam_asns_bulk_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamAsnsBulkPartialUpdateReader is a Reader for the IpamAsnsBulkPartialUpdate structure. +type IpamAsnsBulkPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamAsnsBulkPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamAsnsBulkPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamAsnsBulkPartialUpdateOK creates a IpamAsnsBulkPartialUpdateOK with default headers values +func NewIpamAsnsBulkPartialUpdateOK() *IpamAsnsBulkPartialUpdateOK { + return &IpamAsnsBulkPartialUpdateOK{} +} + +/* IpamAsnsBulkPartialUpdateOK describes a response with status code 200, with default header values. + +IpamAsnsBulkPartialUpdateOK ipam asns bulk partial update o k +*/ +type IpamAsnsBulkPartialUpdateOK struct { + Payload *models.ASN +} + +func (o *IpamAsnsBulkPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /ipam/asns/][%d] ipamAsnsBulkPartialUpdateOK %+v", 200, o.Payload) +} +func (o *IpamAsnsBulkPartialUpdateOK) GetPayload() *models.ASN { + return o.Payload +} + +func (o *IpamAsnsBulkPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ASN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_asns_bulk_update_parameters.go b/netbox/client/ipam/ipam_asns_bulk_update_parameters.go new file mode 100644 index 00000000..20afc7b5 --- /dev/null +++ b/netbox/client/ipam/ipam_asns_bulk_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamAsnsBulkUpdateParams creates a new IpamAsnsBulkUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamAsnsBulkUpdateParams() *IpamAsnsBulkUpdateParams { + return &IpamAsnsBulkUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamAsnsBulkUpdateParamsWithTimeout creates a new IpamAsnsBulkUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamAsnsBulkUpdateParamsWithTimeout(timeout time.Duration) *IpamAsnsBulkUpdateParams { + return &IpamAsnsBulkUpdateParams{ + timeout: timeout, + } +} + +// NewIpamAsnsBulkUpdateParamsWithContext creates a new IpamAsnsBulkUpdateParams object +// with the ability to set a context for a request. +func NewIpamAsnsBulkUpdateParamsWithContext(ctx context.Context) *IpamAsnsBulkUpdateParams { + return &IpamAsnsBulkUpdateParams{ + Context: ctx, + } +} + +// NewIpamAsnsBulkUpdateParamsWithHTTPClient creates a new IpamAsnsBulkUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamAsnsBulkUpdateParamsWithHTTPClient(client *http.Client) *IpamAsnsBulkUpdateParams { + return &IpamAsnsBulkUpdateParams{ + HTTPClient: client, + } +} + +/* IpamAsnsBulkUpdateParams contains all the parameters to send to the API endpoint + for the ipam asns bulk update operation. + + Typically these are written to a http.Request. +*/ +type IpamAsnsBulkUpdateParams struct { + + // Data. + Data *models.WritableASN + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam asns bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsBulkUpdateParams) WithDefaults() *IpamAsnsBulkUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam asns bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsBulkUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam asns bulk update params +func (o *IpamAsnsBulkUpdateParams) WithTimeout(timeout time.Duration) *IpamAsnsBulkUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam asns bulk update params +func (o *IpamAsnsBulkUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam asns bulk update params +func (o *IpamAsnsBulkUpdateParams) WithContext(ctx context.Context) *IpamAsnsBulkUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam asns bulk update params +func (o *IpamAsnsBulkUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam asns bulk update params +func (o *IpamAsnsBulkUpdateParams) WithHTTPClient(client *http.Client) *IpamAsnsBulkUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam asns bulk update params +func (o *IpamAsnsBulkUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam asns bulk update params +func (o *IpamAsnsBulkUpdateParams) WithData(data *models.WritableASN) *IpamAsnsBulkUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam asns bulk update params +func (o *IpamAsnsBulkUpdateParams) SetData(data *models.WritableASN) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamAsnsBulkUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_asns_bulk_update_responses.go b/netbox/client/ipam/ipam_asns_bulk_update_responses.go new file mode 100644 index 00000000..500e19cd --- /dev/null +++ b/netbox/client/ipam/ipam_asns_bulk_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamAsnsBulkUpdateReader is a Reader for the IpamAsnsBulkUpdate structure. +type IpamAsnsBulkUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamAsnsBulkUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamAsnsBulkUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamAsnsBulkUpdateOK creates a IpamAsnsBulkUpdateOK with default headers values +func NewIpamAsnsBulkUpdateOK() *IpamAsnsBulkUpdateOK { + return &IpamAsnsBulkUpdateOK{} +} + +/* IpamAsnsBulkUpdateOK describes a response with status code 200, with default header values. + +IpamAsnsBulkUpdateOK ipam asns bulk update o k +*/ +type IpamAsnsBulkUpdateOK struct { + Payload *models.ASN +} + +func (o *IpamAsnsBulkUpdateOK) Error() string { + return fmt.Sprintf("[PUT /ipam/asns/][%d] ipamAsnsBulkUpdateOK %+v", 200, o.Payload) +} +func (o *IpamAsnsBulkUpdateOK) GetPayload() *models.ASN { + return o.Payload +} + +func (o *IpamAsnsBulkUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ASN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_asns_create_parameters.go b/netbox/client/ipam/ipam_asns_create_parameters.go new file mode 100644 index 00000000..aa8a323a --- /dev/null +++ b/netbox/client/ipam/ipam_asns_create_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamAsnsCreateParams creates a new IpamAsnsCreateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamAsnsCreateParams() *IpamAsnsCreateParams { + return &IpamAsnsCreateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamAsnsCreateParamsWithTimeout creates a new IpamAsnsCreateParams object +// with the ability to set a timeout on a request. +func NewIpamAsnsCreateParamsWithTimeout(timeout time.Duration) *IpamAsnsCreateParams { + return &IpamAsnsCreateParams{ + timeout: timeout, + } +} + +// NewIpamAsnsCreateParamsWithContext creates a new IpamAsnsCreateParams object +// with the ability to set a context for a request. +func NewIpamAsnsCreateParamsWithContext(ctx context.Context) *IpamAsnsCreateParams { + return &IpamAsnsCreateParams{ + Context: ctx, + } +} + +// NewIpamAsnsCreateParamsWithHTTPClient creates a new IpamAsnsCreateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamAsnsCreateParamsWithHTTPClient(client *http.Client) *IpamAsnsCreateParams { + return &IpamAsnsCreateParams{ + HTTPClient: client, + } +} + +/* IpamAsnsCreateParams contains all the parameters to send to the API endpoint + for the ipam asns create operation. + + Typically these are written to a http.Request. +*/ +type IpamAsnsCreateParams struct { + + // Data. + Data *models.WritableASN + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam asns create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsCreateParams) WithDefaults() *IpamAsnsCreateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam asns create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsCreateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam asns create params +func (o *IpamAsnsCreateParams) WithTimeout(timeout time.Duration) *IpamAsnsCreateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam asns create params +func (o *IpamAsnsCreateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam asns create params +func (o *IpamAsnsCreateParams) WithContext(ctx context.Context) *IpamAsnsCreateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam asns create params +func (o *IpamAsnsCreateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam asns create params +func (o *IpamAsnsCreateParams) WithHTTPClient(client *http.Client) *IpamAsnsCreateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam asns create params +func (o *IpamAsnsCreateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam asns create params +func (o *IpamAsnsCreateParams) WithData(data *models.WritableASN) *IpamAsnsCreateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam asns create params +func (o *IpamAsnsCreateParams) SetData(data *models.WritableASN) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamAsnsCreateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_asns_create_responses.go b/netbox/client/ipam/ipam_asns_create_responses.go new file mode 100644 index 00000000..266a19d8 --- /dev/null +++ b/netbox/client/ipam/ipam_asns_create_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamAsnsCreateReader is a Reader for the IpamAsnsCreate structure. +type IpamAsnsCreateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamAsnsCreateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 201: + result := NewIpamAsnsCreateCreated() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamAsnsCreateCreated creates a IpamAsnsCreateCreated with default headers values +func NewIpamAsnsCreateCreated() *IpamAsnsCreateCreated { + return &IpamAsnsCreateCreated{} +} + +/* IpamAsnsCreateCreated describes a response with status code 201, with default header values. + +IpamAsnsCreateCreated ipam asns create created +*/ +type IpamAsnsCreateCreated struct { + Payload *models.ASN +} + +func (o *IpamAsnsCreateCreated) Error() string { + return fmt.Sprintf("[POST /ipam/asns/][%d] ipamAsnsCreateCreated %+v", 201, o.Payload) +} +func (o *IpamAsnsCreateCreated) GetPayload() *models.ASN { + return o.Payload +} + +func (o *IpamAsnsCreateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ASN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_asns_delete_parameters.go b/netbox/client/ipam/ipam_asns_delete_parameters.go new file mode 100644 index 00000000..9638f23a --- /dev/null +++ b/netbox/client/ipam/ipam_asns_delete_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewIpamAsnsDeleteParams creates a new IpamAsnsDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamAsnsDeleteParams() *IpamAsnsDeleteParams { + return &IpamAsnsDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamAsnsDeleteParamsWithTimeout creates a new IpamAsnsDeleteParams object +// with the ability to set a timeout on a request. +func NewIpamAsnsDeleteParamsWithTimeout(timeout time.Duration) *IpamAsnsDeleteParams { + return &IpamAsnsDeleteParams{ + timeout: timeout, + } +} + +// NewIpamAsnsDeleteParamsWithContext creates a new IpamAsnsDeleteParams object +// with the ability to set a context for a request. +func NewIpamAsnsDeleteParamsWithContext(ctx context.Context) *IpamAsnsDeleteParams { + return &IpamAsnsDeleteParams{ + Context: ctx, + } +} + +// NewIpamAsnsDeleteParamsWithHTTPClient creates a new IpamAsnsDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamAsnsDeleteParamsWithHTTPClient(client *http.Client) *IpamAsnsDeleteParams { + return &IpamAsnsDeleteParams{ + HTTPClient: client, + } +} + +/* IpamAsnsDeleteParams contains all the parameters to send to the API endpoint + for the ipam asns delete operation. + + Typically these are written to a http.Request. +*/ +type IpamAsnsDeleteParams struct { + + /* ID. + + A unique integer value identifying this ASN. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam asns delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsDeleteParams) WithDefaults() *IpamAsnsDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam asns delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam asns delete params +func (o *IpamAsnsDeleteParams) WithTimeout(timeout time.Duration) *IpamAsnsDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam asns delete params +func (o *IpamAsnsDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam asns delete params +func (o *IpamAsnsDeleteParams) WithContext(ctx context.Context) *IpamAsnsDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam asns delete params +func (o *IpamAsnsDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam asns delete params +func (o *IpamAsnsDeleteParams) WithHTTPClient(client *http.Client) *IpamAsnsDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam asns delete params +func (o *IpamAsnsDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the ipam asns delete params +func (o *IpamAsnsDeleteParams) WithID(id int64) *IpamAsnsDeleteParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam asns delete params +func (o *IpamAsnsDeleteParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamAsnsDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_asns_delete_responses.go b/netbox/client/ipam/ipam_asns_delete_responses.go new file mode 100644 index 00000000..25eafc37 --- /dev/null +++ b/netbox/client/ipam/ipam_asns_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// IpamAsnsDeleteReader is a Reader for the IpamAsnsDelete structure. +type IpamAsnsDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamAsnsDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewIpamAsnsDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamAsnsDeleteNoContent creates a IpamAsnsDeleteNoContent with default headers values +func NewIpamAsnsDeleteNoContent() *IpamAsnsDeleteNoContent { + return &IpamAsnsDeleteNoContent{} +} + +/* IpamAsnsDeleteNoContent describes a response with status code 204, with default header values. + +IpamAsnsDeleteNoContent ipam asns delete no content +*/ +type IpamAsnsDeleteNoContent struct { +} + +func (o *IpamAsnsDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /ipam/asns/{id}/][%d] ipamAsnsDeleteNoContent ", 204) +} + +func (o *IpamAsnsDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/ipam/ipam_asns_list_parameters.go b/netbox/client/ipam/ipam_asns_list_parameters.go new file mode 100644 index 00000000..ba572b62 --- /dev/null +++ b/netbox/client/ipam/ipam_asns_list_parameters.go @@ -0,0 +1,1637 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewIpamAsnsListParams creates a new IpamAsnsListParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamAsnsListParams() *IpamAsnsListParams { + return &IpamAsnsListParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamAsnsListParamsWithTimeout creates a new IpamAsnsListParams object +// with the ability to set a timeout on a request. +func NewIpamAsnsListParamsWithTimeout(timeout time.Duration) *IpamAsnsListParams { + return &IpamAsnsListParams{ + timeout: timeout, + } +} + +// NewIpamAsnsListParamsWithContext creates a new IpamAsnsListParams object +// with the ability to set a context for a request. +func NewIpamAsnsListParamsWithContext(ctx context.Context) *IpamAsnsListParams { + return &IpamAsnsListParams{ + Context: ctx, + } +} + +// NewIpamAsnsListParamsWithHTTPClient creates a new IpamAsnsListParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamAsnsListParamsWithHTTPClient(client *http.Client) *IpamAsnsListParams { + return &IpamAsnsListParams{ + HTTPClient: client, + } +} + +/* IpamAsnsListParams contains all the parameters to send to the API endpoint + for the ipam asns list operation. + + Typically these are written to a http.Request. +*/ +type IpamAsnsListParams struct { + + // Asn. + Asn *string + + // AsnGt. + AsnGt *string + + // AsnGte. + AsnGte *string + + // AsnLt. + AsnLt *string + + // AsnLte. + AsnLte *string + + // Asnn. + Asnn *string + + // Created. + Created *string + + // CreatedGte. + CreatedGte *string + + // CreatedLte. + CreatedLte *string + + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + + // ID. + ID *string + + // IDGt. + IDGt *string + + // IDGte. + IDGte *string + + // IDLt. + IDLt *string + + // IDLte. + IDLte *string + + // IDn. + IDn *string + + // LastUpdated. + LastUpdated *string + + // LastUpdatedGte. + LastUpdatedGte *string + + // LastUpdatedLte. + LastUpdatedLte *string + + /* Limit. + + Number of results to return per page. + */ + Limit *int64 + + /* Offset. + + The initial index from which to return the results. + */ + Offset *int64 + + // Q. + Q *string + + // Rir. + Rir *string + + // Rirn. + Rirn *string + + // RirID. + RirID *string + + // RirIDn. + RirIDn *string + + // Site. + Site *string + + // Siten. + Siten *string + + // SiteID. + SiteID *string + + // SiteIDn. + SiteIDn *string + + // Tenant. + Tenant *string + + // Tenantn. + Tenantn *string + + // TenantGroup. + TenantGroup *string + + // TenantGroupn. + TenantGroupn *string + + // TenantGroupID. + TenantGroupID *string + + // TenantGroupIDn. + TenantGroupIDn *string + + // TenantID. + TenantID *string + + // TenantIDn. + TenantIDn *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam asns list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsListParams) WithDefaults() *IpamAsnsListParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam asns list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsListParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam asns list params +func (o *IpamAsnsListParams) WithTimeout(timeout time.Duration) *IpamAsnsListParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam asns list params +func (o *IpamAsnsListParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam asns list params +func (o *IpamAsnsListParams) WithContext(ctx context.Context) *IpamAsnsListParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam asns list params +func (o *IpamAsnsListParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam asns list params +func (o *IpamAsnsListParams) WithHTTPClient(client *http.Client) *IpamAsnsListParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam asns list params +func (o *IpamAsnsListParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAsn adds the asn to the ipam asns list params +func (o *IpamAsnsListParams) WithAsn(asn *string) *IpamAsnsListParams { + o.SetAsn(asn) + return o +} + +// SetAsn adds the asn to the ipam asns list params +func (o *IpamAsnsListParams) SetAsn(asn *string) { + o.Asn = asn +} + +// WithAsnGt adds the asnGt to the ipam asns list params +func (o *IpamAsnsListParams) WithAsnGt(asnGt *string) *IpamAsnsListParams { + o.SetAsnGt(asnGt) + return o +} + +// SetAsnGt adds the asnGt to the ipam asns list params +func (o *IpamAsnsListParams) SetAsnGt(asnGt *string) { + o.AsnGt = asnGt +} + +// WithAsnGte adds the asnGte to the ipam asns list params +func (o *IpamAsnsListParams) WithAsnGte(asnGte *string) *IpamAsnsListParams { + o.SetAsnGte(asnGte) + return o +} + +// SetAsnGte adds the asnGte to the ipam asns list params +func (o *IpamAsnsListParams) SetAsnGte(asnGte *string) { + o.AsnGte = asnGte +} + +// WithAsnLt adds the asnLt to the ipam asns list params +func (o *IpamAsnsListParams) WithAsnLt(asnLt *string) *IpamAsnsListParams { + o.SetAsnLt(asnLt) + return o +} + +// SetAsnLt adds the asnLt to the ipam asns list params +func (o *IpamAsnsListParams) SetAsnLt(asnLt *string) { + o.AsnLt = asnLt +} + +// WithAsnLte adds the asnLte to the ipam asns list params +func (o *IpamAsnsListParams) WithAsnLte(asnLte *string) *IpamAsnsListParams { + o.SetAsnLte(asnLte) + return o +} + +// SetAsnLte adds the asnLte to the ipam asns list params +func (o *IpamAsnsListParams) SetAsnLte(asnLte *string) { + o.AsnLte = asnLte +} + +// WithAsnn adds the asnn to the ipam asns list params +func (o *IpamAsnsListParams) WithAsnn(asnn *string) *IpamAsnsListParams { + o.SetAsnn(asnn) + return o +} + +// SetAsnn adds the asnN to the ipam asns list params +func (o *IpamAsnsListParams) SetAsnn(asnn *string) { + o.Asnn = asnn +} + +// WithCreated adds the created to the ipam asns list params +func (o *IpamAsnsListParams) WithCreated(created *string) *IpamAsnsListParams { + o.SetCreated(created) + return o +} + +// SetCreated adds the created to the ipam asns list params +func (o *IpamAsnsListParams) SetCreated(created *string) { + o.Created = created +} + +// WithCreatedGte adds the createdGte to the ipam asns list params +func (o *IpamAsnsListParams) WithCreatedGte(createdGte *string) *IpamAsnsListParams { + o.SetCreatedGte(createdGte) + return o +} + +// SetCreatedGte adds the createdGte to the ipam asns list params +func (o *IpamAsnsListParams) SetCreatedGte(createdGte *string) { + o.CreatedGte = createdGte +} + +// WithCreatedLte adds the createdLte to the ipam asns list params +func (o *IpamAsnsListParams) WithCreatedLte(createdLte *string) *IpamAsnsListParams { + o.SetCreatedLte(createdLte) + return o +} + +// SetCreatedLte adds the createdLte to the ipam asns list params +func (o *IpamAsnsListParams) SetCreatedLte(createdLte *string) { + o.CreatedLte = createdLte +} + +// WithDescription adds the description to the ipam asns list params +func (o *IpamAsnsListParams) WithDescription(description *string) *IpamAsnsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the ipam asns list params +func (o *IpamAsnsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the ipam asns list params +func (o *IpamAsnsListParams) WithDescriptionEmpty(descriptionEmpty *string) *IpamAsnsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the ipam asns list params +func (o *IpamAsnsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the ipam asns list params +func (o *IpamAsnsListParams) WithDescriptionIc(descriptionIc *string) *IpamAsnsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the ipam asns list params +func (o *IpamAsnsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the ipam asns list params +func (o *IpamAsnsListParams) WithDescriptionIe(descriptionIe *string) *IpamAsnsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the ipam asns list params +func (o *IpamAsnsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the ipam asns list params +func (o *IpamAsnsListParams) WithDescriptionIew(descriptionIew *string) *IpamAsnsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the ipam asns list params +func (o *IpamAsnsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the ipam asns list params +func (o *IpamAsnsListParams) WithDescriptionIsw(descriptionIsw *string) *IpamAsnsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the ipam asns list params +func (o *IpamAsnsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the ipam asns list params +func (o *IpamAsnsListParams) WithDescriptionn(descriptionn *string) *IpamAsnsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the ipam asns list params +func (o *IpamAsnsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the ipam asns list params +func (o *IpamAsnsListParams) WithDescriptionNic(descriptionNic *string) *IpamAsnsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the ipam asns list params +func (o *IpamAsnsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the ipam asns list params +func (o *IpamAsnsListParams) WithDescriptionNie(descriptionNie *string) *IpamAsnsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the ipam asns list params +func (o *IpamAsnsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the ipam asns list params +func (o *IpamAsnsListParams) WithDescriptionNiew(descriptionNiew *string) *IpamAsnsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the ipam asns list params +func (o *IpamAsnsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the ipam asns list params +func (o *IpamAsnsListParams) WithDescriptionNisw(descriptionNisw *string) *IpamAsnsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the ipam asns list params +func (o *IpamAsnsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + +// WithID adds the id to the ipam asns list params +func (o *IpamAsnsListParams) WithID(id *string) *IpamAsnsListParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam asns list params +func (o *IpamAsnsListParams) SetID(id *string) { + o.ID = id +} + +// WithIDGt adds the iDGt to the ipam asns list params +func (o *IpamAsnsListParams) WithIDGt(iDGt *string) *IpamAsnsListParams { + o.SetIDGt(iDGt) + return o +} + +// SetIDGt adds the idGt to the ipam asns list params +func (o *IpamAsnsListParams) SetIDGt(iDGt *string) { + o.IDGt = iDGt +} + +// WithIDGte adds the iDGte to the ipam asns list params +func (o *IpamAsnsListParams) WithIDGte(iDGte *string) *IpamAsnsListParams { + o.SetIDGte(iDGte) + return o +} + +// SetIDGte adds the idGte to the ipam asns list params +func (o *IpamAsnsListParams) SetIDGte(iDGte *string) { + o.IDGte = iDGte +} + +// WithIDLt adds the iDLt to the ipam asns list params +func (o *IpamAsnsListParams) WithIDLt(iDLt *string) *IpamAsnsListParams { + o.SetIDLt(iDLt) + return o +} + +// SetIDLt adds the idLt to the ipam asns list params +func (o *IpamAsnsListParams) SetIDLt(iDLt *string) { + o.IDLt = iDLt +} + +// WithIDLte adds the iDLte to the ipam asns list params +func (o *IpamAsnsListParams) WithIDLte(iDLte *string) *IpamAsnsListParams { + o.SetIDLte(iDLte) + return o +} + +// SetIDLte adds the idLte to the ipam asns list params +func (o *IpamAsnsListParams) SetIDLte(iDLte *string) { + o.IDLte = iDLte +} + +// WithIDn adds the iDn to the ipam asns list params +func (o *IpamAsnsListParams) WithIDn(iDn *string) *IpamAsnsListParams { + o.SetIDn(iDn) + return o +} + +// SetIDn adds the idN to the ipam asns list params +func (o *IpamAsnsListParams) SetIDn(iDn *string) { + o.IDn = iDn +} + +// WithLastUpdated adds the lastUpdated to the ipam asns list params +func (o *IpamAsnsListParams) WithLastUpdated(lastUpdated *string) *IpamAsnsListParams { + o.SetLastUpdated(lastUpdated) + return o +} + +// SetLastUpdated adds the lastUpdated to the ipam asns list params +func (o *IpamAsnsListParams) SetLastUpdated(lastUpdated *string) { + o.LastUpdated = lastUpdated +} + +// WithLastUpdatedGte adds the lastUpdatedGte to the ipam asns list params +func (o *IpamAsnsListParams) WithLastUpdatedGte(lastUpdatedGte *string) *IpamAsnsListParams { + o.SetLastUpdatedGte(lastUpdatedGte) + return o +} + +// SetLastUpdatedGte adds the lastUpdatedGte to the ipam asns list params +func (o *IpamAsnsListParams) SetLastUpdatedGte(lastUpdatedGte *string) { + o.LastUpdatedGte = lastUpdatedGte +} + +// WithLastUpdatedLte adds the lastUpdatedLte to the ipam asns list params +func (o *IpamAsnsListParams) WithLastUpdatedLte(lastUpdatedLte *string) *IpamAsnsListParams { + o.SetLastUpdatedLte(lastUpdatedLte) + return o +} + +// SetLastUpdatedLte adds the lastUpdatedLte to the ipam asns list params +func (o *IpamAsnsListParams) SetLastUpdatedLte(lastUpdatedLte *string) { + o.LastUpdatedLte = lastUpdatedLte +} + +// WithLimit adds the limit to the ipam asns list params +func (o *IpamAsnsListParams) WithLimit(limit *int64) *IpamAsnsListParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the ipam asns list params +func (o *IpamAsnsListParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the ipam asns list params +func (o *IpamAsnsListParams) WithOffset(offset *int64) *IpamAsnsListParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the ipam asns list params +func (o *IpamAsnsListParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithQ adds the q to the ipam asns list params +func (o *IpamAsnsListParams) WithQ(q *string) *IpamAsnsListParams { + o.SetQ(q) + return o +} + +// SetQ adds the q to the ipam asns list params +func (o *IpamAsnsListParams) SetQ(q *string) { + o.Q = q +} + +// WithRir adds the rir to the ipam asns list params +func (o *IpamAsnsListParams) WithRir(rir *string) *IpamAsnsListParams { + o.SetRir(rir) + return o +} + +// SetRir adds the rir to the ipam asns list params +func (o *IpamAsnsListParams) SetRir(rir *string) { + o.Rir = rir +} + +// WithRirn adds the rirn to the ipam asns list params +func (o *IpamAsnsListParams) WithRirn(rirn *string) *IpamAsnsListParams { + o.SetRirn(rirn) + return o +} + +// SetRirn adds the rirN to the ipam asns list params +func (o *IpamAsnsListParams) SetRirn(rirn *string) { + o.Rirn = rirn +} + +// WithRirID adds the rirID to the ipam asns list params +func (o *IpamAsnsListParams) WithRirID(rirID *string) *IpamAsnsListParams { + o.SetRirID(rirID) + return o +} + +// SetRirID adds the rirId to the ipam asns list params +func (o *IpamAsnsListParams) SetRirID(rirID *string) { + o.RirID = rirID +} + +// WithRirIDn adds the rirIDn to the ipam asns list params +func (o *IpamAsnsListParams) WithRirIDn(rirIDn *string) *IpamAsnsListParams { + o.SetRirIDn(rirIDn) + return o +} + +// SetRirIDn adds the rirIdN to the ipam asns list params +func (o *IpamAsnsListParams) SetRirIDn(rirIDn *string) { + o.RirIDn = rirIDn +} + +// WithSite adds the site to the ipam asns list params +func (o *IpamAsnsListParams) WithSite(site *string) *IpamAsnsListParams { + o.SetSite(site) + return o +} + +// SetSite adds the site to the ipam asns list params +func (o *IpamAsnsListParams) SetSite(site *string) { + o.Site = site +} + +// WithSiten adds the siten to the ipam asns list params +func (o *IpamAsnsListParams) WithSiten(siten *string) *IpamAsnsListParams { + o.SetSiten(siten) + return o +} + +// SetSiten adds the siteN to the ipam asns list params +func (o *IpamAsnsListParams) SetSiten(siten *string) { + o.Siten = siten +} + +// WithSiteID adds the siteID to the ipam asns list params +func (o *IpamAsnsListParams) WithSiteID(siteID *string) *IpamAsnsListParams { + o.SetSiteID(siteID) + return o +} + +// SetSiteID adds the siteId to the ipam asns list params +func (o *IpamAsnsListParams) SetSiteID(siteID *string) { + o.SiteID = siteID +} + +// WithSiteIDn adds the siteIDn to the ipam asns list params +func (o *IpamAsnsListParams) WithSiteIDn(siteIDn *string) *IpamAsnsListParams { + o.SetSiteIDn(siteIDn) + return o +} + +// SetSiteIDn adds the siteIdN to the ipam asns list params +func (o *IpamAsnsListParams) SetSiteIDn(siteIDn *string) { + o.SiteIDn = siteIDn +} + +// WithTenant adds the tenant to the ipam asns list params +func (o *IpamAsnsListParams) WithTenant(tenant *string) *IpamAsnsListParams { + o.SetTenant(tenant) + return o +} + +// SetTenant adds the tenant to the ipam asns list params +func (o *IpamAsnsListParams) SetTenant(tenant *string) { + o.Tenant = tenant +} + +// WithTenantn adds the tenantn to the ipam asns list params +func (o *IpamAsnsListParams) WithTenantn(tenantn *string) *IpamAsnsListParams { + o.SetTenantn(tenantn) + return o +} + +// SetTenantn adds the tenantN to the ipam asns list params +func (o *IpamAsnsListParams) SetTenantn(tenantn *string) { + o.Tenantn = tenantn +} + +// WithTenantGroup adds the tenantGroup to the ipam asns list params +func (o *IpamAsnsListParams) WithTenantGroup(tenantGroup *string) *IpamAsnsListParams { + o.SetTenantGroup(tenantGroup) + return o +} + +// SetTenantGroup adds the tenantGroup to the ipam asns list params +func (o *IpamAsnsListParams) SetTenantGroup(tenantGroup *string) { + o.TenantGroup = tenantGroup +} + +// WithTenantGroupn adds the tenantGroupn to the ipam asns list params +func (o *IpamAsnsListParams) WithTenantGroupn(tenantGroupn *string) *IpamAsnsListParams { + o.SetTenantGroupn(tenantGroupn) + return o +} + +// SetTenantGroupn adds the tenantGroupN to the ipam asns list params +func (o *IpamAsnsListParams) SetTenantGroupn(tenantGroupn *string) { + o.TenantGroupn = tenantGroupn +} + +// WithTenantGroupID adds the tenantGroupID to the ipam asns list params +func (o *IpamAsnsListParams) WithTenantGroupID(tenantGroupID *string) *IpamAsnsListParams { + o.SetTenantGroupID(tenantGroupID) + return o +} + +// SetTenantGroupID adds the tenantGroupId to the ipam asns list params +func (o *IpamAsnsListParams) SetTenantGroupID(tenantGroupID *string) { + o.TenantGroupID = tenantGroupID +} + +// WithTenantGroupIDn adds the tenantGroupIDn to the ipam asns list params +func (o *IpamAsnsListParams) WithTenantGroupIDn(tenantGroupIDn *string) *IpamAsnsListParams { + o.SetTenantGroupIDn(tenantGroupIDn) + return o +} + +// SetTenantGroupIDn adds the tenantGroupIdN to the ipam asns list params +func (o *IpamAsnsListParams) SetTenantGroupIDn(tenantGroupIDn *string) { + o.TenantGroupIDn = tenantGroupIDn +} + +// WithTenantID adds the tenantID to the ipam asns list params +func (o *IpamAsnsListParams) WithTenantID(tenantID *string) *IpamAsnsListParams { + o.SetTenantID(tenantID) + return o +} + +// SetTenantID adds the tenantId to the ipam asns list params +func (o *IpamAsnsListParams) SetTenantID(tenantID *string) { + o.TenantID = tenantID +} + +// WithTenantIDn adds the tenantIDn to the ipam asns list params +func (o *IpamAsnsListParams) WithTenantIDn(tenantIDn *string) *IpamAsnsListParams { + o.SetTenantIDn(tenantIDn) + return o +} + +// SetTenantIDn adds the tenantIdN to the ipam asns list params +func (o *IpamAsnsListParams) SetTenantIDn(tenantIDn *string) { + o.TenantIDn = tenantIDn +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamAsnsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.Asn != nil { + + // query param asn + var qrAsn string + + if o.Asn != nil { + qrAsn = *o.Asn + } + qAsn := qrAsn + if qAsn != "" { + + if err := r.SetQueryParam("asn", qAsn); err != nil { + return err + } + } + } + + if o.AsnGt != nil { + + // query param asn__gt + var qrAsnGt string + + if o.AsnGt != nil { + qrAsnGt = *o.AsnGt + } + qAsnGt := qrAsnGt + if qAsnGt != "" { + + if err := r.SetQueryParam("asn__gt", qAsnGt); err != nil { + return err + } + } + } + + if o.AsnGte != nil { + + // query param asn__gte + var qrAsnGte string + + if o.AsnGte != nil { + qrAsnGte = *o.AsnGte + } + qAsnGte := qrAsnGte + if qAsnGte != "" { + + if err := r.SetQueryParam("asn__gte", qAsnGte); err != nil { + return err + } + } + } + + if o.AsnLt != nil { + + // query param asn__lt + var qrAsnLt string + + if o.AsnLt != nil { + qrAsnLt = *o.AsnLt + } + qAsnLt := qrAsnLt + if qAsnLt != "" { + + if err := r.SetQueryParam("asn__lt", qAsnLt); err != nil { + return err + } + } + } + + if o.AsnLte != nil { + + // query param asn__lte + var qrAsnLte string + + if o.AsnLte != nil { + qrAsnLte = *o.AsnLte + } + qAsnLte := qrAsnLte + if qAsnLte != "" { + + if err := r.SetQueryParam("asn__lte", qAsnLte); err != nil { + return err + } + } + } + + if o.Asnn != nil { + + // query param asn__n + var qrAsnn string + + if o.Asnn != nil { + qrAsnn = *o.Asnn + } + qAsnn := qrAsnn + if qAsnn != "" { + + if err := r.SetQueryParam("asn__n", qAsnn); err != nil { + return err + } + } + } + + if o.Created != nil { + + // query param created + var qrCreated string + + if o.Created != nil { + qrCreated = *o.Created + } + qCreated := qrCreated + if qCreated != "" { + + if err := r.SetQueryParam("created", qCreated); err != nil { + return err + } + } + } + + if o.CreatedGte != nil { + + // query param created__gte + var qrCreatedGte string + + if o.CreatedGte != nil { + qrCreatedGte = *o.CreatedGte + } + qCreatedGte := qrCreatedGte + if qCreatedGte != "" { + + if err := r.SetQueryParam("created__gte", qCreatedGte); err != nil { + return err + } + } + } + + if o.CreatedLte != nil { + + // query param created__lte + var qrCreatedLte string + + if o.CreatedLte != nil { + qrCreatedLte = *o.CreatedLte + } + qCreatedLte := qrCreatedLte + if qCreatedLte != "" { + + if err := r.SetQueryParam("created__lte", qCreatedLte); err != nil { + return err + } + } + } + + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + + if o.ID != nil { + + // query param id + var qrID string + + if o.ID != nil { + qrID = *o.ID + } + qID := qrID + if qID != "" { + + if err := r.SetQueryParam("id", qID); err != nil { + return err + } + } + } + + if o.IDGt != nil { + + // query param id__gt + var qrIDGt string + + if o.IDGt != nil { + qrIDGt = *o.IDGt + } + qIDGt := qrIDGt + if qIDGt != "" { + + if err := r.SetQueryParam("id__gt", qIDGt); err != nil { + return err + } + } + } + + if o.IDGte != nil { + + // query param id__gte + var qrIDGte string + + if o.IDGte != nil { + qrIDGte = *o.IDGte + } + qIDGte := qrIDGte + if qIDGte != "" { + + if err := r.SetQueryParam("id__gte", qIDGte); err != nil { + return err + } + } + } + + if o.IDLt != nil { + + // query param id__lt + var qrIDLt string + + if o.IDLt != nil { + qrIDLt = *o.IDLt + } + qIDLt := qrIDLt + if qIDLt != "" { + + if err := r.SetQueryParam("id__lt", qIDLt); err != nil { + return err + } + } + } + + if o.IDLte != nil { + + // query param id__lte + var qrIDLte string + + if o.IDLte != nil { + qrIDLte = *o.IDLte + } + qIDLte := qrIDLte + if qIDLte != "" { + + if err := r.SetQueryParam("id__lte", qIDLte); err != nil { + return err + } + } + } + + if o.IDn != nil { + + // query param id__n + var qrIDn string + + if o.IDn != nil { + qrIDn = *o.IDn + } + qIDn := qrIDn + if qIDn != "" { + + if err := r.SetQueryParam("id__n", qIDn); err != nil { + return err + } + } + } + + if o.LastUpdated != nil { + + // query param last_updated + var qrLastUpdated string + + if o.LastUpdated != nil { + qrLastUpdated = *o.LastUpdated + } + qLastUpdated := qrLastUpdated + if qLastUpdated != "" { + + if err := r.SetQueryParam("last_updated", qLastUpdated); err != nil { + return err + } + } + } + + if o.LastUpdatedGte != nil { + + // query param last_updated__gte + var qrLastUpdatedGte string + + if o.LastUpdatedGte != nil { + qrLastUpdatedGte = *o.LastUpdatedGte + } + qLastUpdatedGte := qrLastUpdatedGte + if qLastUpdatedGte != "" { + + if err := r.SetQueryParam("last_updated__gte", qLastUpdatedGte); err != nil { + return err + } + } + } + + if o.LastUpdatedLte != nil { + + // query param last_updated__lte + var qrLastUpdatedLte string + + if o.LastUpdatedLte != nil { + qrLastUpdatedLte = *o.LastUpdatedLte + } + qLastUpdatedLte := qrLastUpdatedLte + if qLastUpdatedLte != "" { + + if err := r.SetQueryParam("last_updated__lte", qLastUpdatedLte); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.Q != nil { + + // query param q + var qrQ string + + if o.Q != nil { + qrQ = *o.Q + } + qQ := qrQ + if qQ != "" { + + if err := r.SetQueryParam("q", qQ); err != nil { + return err + } + } + } + + if o.Rir != nil { + + // query param rir + var qrRir string + + if o.Rir != nil { + qrRir = *o.Rir + } + qRir := qrRir + if qRir != "" { + + if err := r.SetQueryParam("rir", qRir); err != nil { + return err + } + } + } + + if o.Rirn != nil { + + // query param rir__n + var qrRirn string + + if o.Rirn != nil { + qrRirn = *o.Rirn + } + qRirn := qrRirn + if qRirn != "" { + + if err := r.SetQueryParam("rir__n", qRirn); err != nil { + return err + } + } + } + + if o.RirID != nil { + + // query param rir_id + var qrRirID string + + if o.RirID != nil { + qrRirID = *o.RirID + } + qRirID := qrRirID + if qRirID != "" { + + if err := r.SetQueryParam("rir_id", qRirID); err != nil { + return err + } + } + } + + if o.RirIDn != nil { + + // query param rir_id__n + var qrRirIDn string + + if o.RirIDn != nil { + qrRirIDn = *o.RirIDn + } + qRirIDn := qrRirIDn + if qRirIDn != "" { + + if err := r.SetQueryParam("rir_id__n", qRirIDn); err != nil { + return err + } + } + } + + if o.Site != nil { + + // query param site + var qrSite string + + if o.Site != nil { + qrSite = *o.Site + } + qSite := qrSite + if qSite != "" { + + if err := r.SetQueryParam("site", qSite); err != nil { + return err + } + } + } + + if o.Siten != nil { + + // query param site__n + var qrSiten string + + if o.Siten != nil { + qrSiten = *o.Siten + } + qSiten := qrSiten + if qSiten != "" { + + if err := r.SetQueryParam("site__n", qSiten); err != nil { + return err + } + } + } + + if o.SiteID != nil { + + // query param site_id + var qrSiteID string + + if o.SiteID != nil { + qrSiteID = *o.SiteID + } + qSiteID := qrSiteID + if qSiteID != "" { + + if err := r.SetQueryParam("site_id", qSiteID); err != nil { + return err + } + } + } + + if o.SiteIDn != nil { + + // query param site_id__n + var qrSiteIDn string + + if o.SiteIDn != nil { + qrSiteIDn = *o.SiteIDn + } + qSiteIDn := qrSiteIDn + if qSiteIDn != "" { + + if err := r.SetQueryParam("site_id__n", qSiteIDn); err != nil { + return err + } + } + } + + if o.Tenant != nil { + + // query param tenant + var qrTenant string + + if o.Tenant != nil { + qrTenant = *o.Tenant + } + qTenant := qrTenant + if qTenant != "" { + + if err := r.SetQueryParam("tenant", qTenant); err != nil { + return err + } + } + } + + if o.Tenantn != nil { + + // query param tenant__n + var qrTenantn string + + if o.Tenantn != nil { + qrTenantn = *o.Tenantn + } + qTenantn := qrTenantn + if qTenantn != "" { + + if err := r.SetQueryParam("tenant__n", qTenantn); err != nil { + return err + } + } + } + + if o.TenantGroup != nil { + + // query param tenant_group + var qrTenantGroup string + + if o.TenantGroup != nil { + qrTenantGroup = *o.TenantGroup + } + qTenantGroup := qrTenantGroup + if qTenantGroup != "" { + + if err := r.SetQueryParam("tenant_group", qTenantGroup); err != nil { + return err + } + } + } + + if o.TenantGroupn != nil { + + // query param tenant_group__n + var qrTenantGroupn string + + if o.TenantGroupn != nil { + qrTenantGroupn = *o.TenantGroupn + } + qTenantGroupn := qrTenantGroupn + if qTenantGroupn != "" { + + if err := r.SetQueryParam("tenant_group__n", qTenantGroupn); err != nil { + return err + } + } + } + + if o.TenantGroupID != nil { + + // query param tenant_group_id + var qrTenantGroupID string + + if o.TenantGroupID != nil { + qrTenantGroupID = *o.TenantGroupID + } + qTenantGroupID := qrTenantGroupID + if qTenantGroupID != "" { + + if err := r.SetQueryParam("tenant_group_id", qTenantGroupID); err != nil { + return err + } + } + } + + if o.TenantGroupIDn != nil { + + // query param tenant_group_id__n + var qrTenantGroupIDn string + + if o.TenantGroupIDn != nil { + qrTenantGroupIDn = *o.TenantGroupIDn + } + qTenantGroupIDn := qrTenantGroupIDn + if qTenantGroupIDn != "" { + + if err := r.SetQueryParam("tenant_group_id__n", qTenantGroupIDn); err != nil { + return err + } + } + } + + if o.TenantID != nil { + + // query param tenant_id + var qrTenantID string + + if o.TenantID != nil { + qrTenantID = *o.TenantID + } + qTenantID := qrTenantID + if qTenantID != "" { + + if err := r.SetQueryParam("tenant_id", qTenantID); err != nil { + return err + } + } + } + + if o.TenantIDn != nil { + + // query param tenant_id__n + var qrTenantIDn string + + if o.TenantIDn != nil { + qrTenantIDn = *o.TenantIDn + } + qTenantIDn := qrTenantIDn + if qTenantIDn != "" { + + if err := r.SetQueryParam("tenant_id__n", qTenantIDn); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_asns_list_responses.go b/netbox/client/ipam/ipam_asns_list_responses.go new file mode 100644 index 00000000..caa12376 --- /dev/null +++ b/netbox/client/ipam/ipam_asns_list_responses.go @@ -0,0 +1,247 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamAsnsListReader is a Reader for the IpamAsnsList structure. +type IpamAsnsListReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamAsnsListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamAsnsListOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamAsnsListOK creates a IpamAsnsListOK with default headers values +func NewIpamAsnsListOK() *IpamAsnsListOK { + return &IpamAsnsListOK{} +} + +/* IpamAsnsListOK describes a response with status code 200, with default header values. + +IpamAsnsListOK ipam asns list o k +*/ +type IpamAsnsListOK struct { + Payload *IpamAsnsListOKBody +} + +func (o *IpamAsnsListOK) Error() string { + return fmt.Sprintf("[GET /ipam/asns/][%d] ipamAsnsListOK %+v", 200, o.Payload) +} +func (o *IpamAsnsListOK) GetPayload() *IpamAsnsListOKBody { + return o.Payload +} + +func (o *IpamAsnsListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(IpamAsnsListOKBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*IpamAsnsListOKBody ipam asns list o k body +swagger:model IpamAsnsListOKBody +*/ +type IpamAsnsListOKBody struct { + + // count + // Required: true + Count *int64 `json:"count"` + + // next + // Format: uri + Next *strfmt.URI `json:"next,omitempty"` + + // previous + // Format: uri + Previous *strfmt.URI `json:"previous,omitempty"` + + // results + // Required: true + Results []*models.ASN `json:"results"` +} + +// Validate validates this ipam asns list o k body +func (o *IpamAsnsListOKBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateCount(formats); err != nil { + res = append(res, err) + } + + if err := o.validateNext(formats); err != nil { + res = append(res, err) + } + + if err := o.validatePrevious(formats); err != nil { + res = append(res, err) + } + + if err := o.validateResults(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *IpamAsnsListOKBody) validateCount(formats strfmt.Registry) error { + + if err := validate.Required("ipamAsnsListOK"+"."+"count", "body", o.Count); err != nil { + return err + } + + return nil +} + +func (o *IpamAsnsListOKBody) validateNext(formats strfmt.Registry) error { + if swag.IsZero(o.Next) { // not required + return nil + } + + if err := validate.FormatOf("ipamAsnsListOK"+"."+"next", "body", "uri", o.Next.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *IpamAsnsListOKBody) validatePrevious(formats strfmt.Registry) error { + if swag.IsZero(o.Previous) { // not required + return nil + } + + if err := validate.FormatOf("ipamAsnsListOK"+"."+"previous", "body", "uri", o.Previous.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *IpamAsnsListOKBody) validateResults(formats strfmt.Registry) error { + + if err := validate.Required("ipamAsnsListOK"+"."+"results", "body", o.Results); err != nil { + return err + } + + for i := 0; i < len(o.Results); i++ { + if swag.IsZero(o.Results[i]) { // not required + continue + } + + if o.Results[i] != nil { + if err := o.Results[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("ipamAsnsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("ipamAsnsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this ipam asns list o k body based on the context it is used +func (o *IpamAsnsListOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := o.contextValidateResults(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *IpamAsnsListOKBody) contextValidateResults(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(o.Results); i++ { + + if o.Results[i] != nil { + if err := o.Results[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("ipamAsnsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("ipamAsnsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (o *IpamAsnsListOKBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *IpamAsnsListOKBody) UnmarshalBinary(b []byte) error { + var res IpamAsnsListOKBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/netbox/client/ipam/ipam_asns_partial_update_parameters.go b/netbox/client/ipam/ipam_asns_partial_update_parameters.go new file mode 100644 index 00000000..7e16f0e7 --- /dev/null +++ b/netbox/client/ipam/ipam_asns_partial_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamAsnsPartialUpdateParams creates a new IpamAsnsPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamAsnsPartialUpdateParams() *IpamAsnsPartialUpdateParams { + return &IpamAsnsPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamAsnsPartialUpdateParamsWithTimeout creates a new IpamAsnsPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamAsnsPartialUpdateParamsWithTimeout(timeout time.Duration) *IpamAsnsPartialUpdateParams { + return &IpamAsnsPartialUpdateParams{ + timeout: timeout, + } +} + +// NewIpamAsnsPartialUpdateParamsWithContext creates a new IpamAsnsPartialUpdateParams object +// with the ability to set a context for a request. +func NewIpamAsnsPartialUpdateParamsWithContext(ctx context.Context) *IpamAsnsPartialUpdateParams { + return &IpamAsnsPartialUpdateParams{ + Context: ctx, + } +} + +// NewIpamAsnsPartialUpdateParamsWithHTTPClient creates a new IpamAsnsPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamAsnsPartialUpdateParamsWithHTTPClient(client *http.Client) *IpamAsnsPartialUpdateParams { + return &IpamAsnsPartialUpdateParams{ + HTTPClient: client, + } +} + +/* IpamAsnsPartialUpdateParams contains all the parameters to send to the API endpoint + for the ipam asns partial update operation. + + Typically these are written to a http.Request. +*/ +type IpamAsnsPartialUpdateParams struct { + + // Data. + Data *models.WritableASN + + /* ID. + + A unique integer value identifying this ASN. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam asns partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsPartialUpdateParams) WithDefaults() *IpamAsnsPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam asns partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam asns partial update params +func (o *IpamAsnsPartialUpdateParams) WithTimeout(timeout time.Duration) *IpamAsnsPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam asns partial update params +func (o *IpamAsnsPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam asns partial update params +func (o *IpamAsnsPartialUpdateParams) WithContext(ctx context.Context) *IpamAsnsPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam asns partial update params +func (o *IpamAsnsPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam asns partial update params +func (o *IpamAsnsPartialUpdateParams) WithHTTPClient(client *http.Client) *IpamAsnsPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam asns partial update params +func (o *IpamAsnsPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam asns partial update params +func (o *IpamAsnsPartialUpdateParams) WithData(data *models.WritableASN) *IpamAsnsPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam asns partial update params +func (o *IpamAsnsPartialUpdateParams) SetData(data *models.WritableASN) { + o.Data = data +} + +// WithID adds the id to the ipam asns partial update params +func (o *IpamAsnsPartialUpdateParams) WithID(id int64) *IpamAsnsPartialUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam asns partial update params +func (o *IpamAsnsPartialUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamAsnsPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_asns_partial_update_responses.go b/netbox/client/ipam/ipam_asns_partial_update_responses.go new file mode 100644 index 00000000..56fc7a41 --- /dev/null +++ b/netbox/client/ipam/ipam_asns_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamAsnsPartialUpdateReader is a Reader for the IpamAsnsPartialUpdate structure. +type IpamAsnsPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamAsnsPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamAsnsPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamAsnsPartialUpdateOK creates a IpamAsnsPartialUpdateOK with default headers values +func NewIpamAsnsPartialUpdateOK() *IpamAsnsPartialUpdateOK { + return &IpamAsnsPartialUpdateOK{} +} + +/* IpamAsnsPartialUpdateOK describes a response with status code 200, with default header values. + +IpamAsnsPartialUpdateOK ipam asns partial update o k +*/ +type IpamAsnsPartialUpdateOK struct { + Payload *models.ASN +} + +func (o *IpamAsnsPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /ipam/asns/{id}/][%d] ipamAsnsPartialUpdateOK %+v", 200, o.Payload) +} +func (o *IpamAsnsPartialUpdateOK) GetPayload() *models.ASN { + return o.Payload +} + +func (o *IpamAsnsPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ASN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_asns_read_parameters.go b/netbox/client/ipam/ipam_asns_read_parameters.go new file mode 100644 index 00000000..cb164eae --- /dev/null +++ b/netbox/client/ipam/ipam_asns_read_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewIpamAsnsReadParams creates a new IpamAsnsReadParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamAsnsReadParams() *IpamAsnsReadParams { + return &IpamAsnsReadParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamAsnsReadParamsWithTimeout creates a new IpamAsnsReadParams object +// with the ability to set a timeout on a request. +func NewIpamAsnsReadParamsWithTimeout(timeout time.Duration) *IpamAsnsReadParams { + return &IpamAsnsReadParams{ + timeout: timeout, + } +} + +// NewIpamAsnsReadParamsWithContext creates a new IpamAsnsReadParams object +// with the ability to set a context for a request. +func NewIpamAsnsReadParamsWithContext(ctx context.Context) *IpamAsnsReadParams { + return &IpamAsnsReadParams{ + Context: ctx, + } +} + +// NewIpamAsnsReadParamsWithHTTPClient creates a new IpamAsnsReadParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamAsnsReadParamsWithHTTPClient(client *http.Client) *IpamAsnsReadParams { + return &IpamAsnsReadParams{ + HTTPClient: client, + } +} + +/* IpamAsnsReadParams contains all the parameters to send to the API endpoint + for the ipam asns read operation. + + Typically these are written to a http.Request. +*/ +type IpamAsnsReadParams struct { + + /* ID. + + A unique integer value identifying this ASN. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam asns read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsReadParams) WithDefaults() *IpamAsnsReadParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam asns read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsReadParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam asns read params +func (o *IpamAsnsReadParams) WithTimeout(timeout time.Duration) *IpamAsnsReadParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam asns read params +func (o *IpamAsnsReadParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam asns read params +func (o *IpamAsnsReadParams) WithContext(ctx context.Context) *IpamAsnsReadParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam asns read params +func (o *IpamAsnsReadParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam asns read params +func (o *IpamAsnsReadParams) WithHTTPClient(client *http.Client) *IpamAsnsReadParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam asns read params +func (o *IpamAsnsReadParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the ipam asns read params +func (o *IpamAsnsReadParams) WithID(id int64) *IpamAsnsReadParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam asns read params +func (o *IpamAsnsReadParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamAsnsReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_asns_read_responses.go b/netbox/client/ipam/ipam_asns_read_responses.go new file mode 100644 index 00000000..88988820 --- /dev/null +++ b/netbox/client/ipam/ipam_asns_read_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamAsnsReadReader is a Reader for the IpamAsnsRead structure. +type IpamAsnsReadReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamAsnsReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamAsnsReadOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamAsnsReadOK creates a IpamAsnsReadOK with default headers values +func NewIpamAsnsReadOK() *IpamAsnsReadOK { + return &IpamAsnsReadOK{} +} + +/* IpamAsnsReadOK describes a response with status code 200, with default header values. + +IpamAsnsReadOK ipam asns read o k +*/ +type IpamAsnsReadOK struct { + Payload *models.ASN +} + +func (o *IpamAsnsReadOK) Error() string { + return fmt.Sprintf("[GET /ipam/asns/{id}/][%d] ipamAsnsReadOK %+v", 200, o.Payload) +} +func (o *IpamAsnsReadOK) GetPayload() *models.ASN { + return o.Payload +} + +func (o *IpamAsnsReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ASN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_asns_update_parameters.go b/netbox/client/ipam/ipam_asns_update_parameters.go new file mode 100644 index 00000000..fcb6da27 --- /dev/null +++ b/netbox/client/ipam/ipam_asns_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamAsnsUpdateParams creates a new IpamAsnsUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamAsnsUpdateParams() *IpamAsnsUpdateParams { + return &IpamAsnsUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamAsnsUpdateParamsWithTimeout creates a new IpamAsnsUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamAsnsUpdateParamsWithTimeout(timeout time.Duration) *IpamAsnsUpdateParams { + return &IpamAsnsUpdateParams{ + timeout: timeout, + } +} + +// NewIpamAsnsUpdateParamsWithContext creates a new IpamAsnsUpdateParams object +// with the ability to set a context for a request. +func NewIpamAsnsUpdateParamsWithContext(ctx context.Context) *IpamAsnsUpdateParams { + return &IpamAsnsUpdateParams{ + Context: ctx, + } +} + +// NewIpamAsnsUpdateParamsWithHTTPClient creates a new IpamAsnsUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamAsnsUpdateParamsWithHTTPClient(client *http.Client) *IpamAsnsUpdateParams { + return &IpamAsnsUpdateParams{ + HTTPClient: client, + } +} + +/* IpamAsnsUpdateParams contains all the parameters to send to the API endpoint + for the ipam asns update operation. + + Typically these are written to a http.Request. +*/ +type IpamAsnsUpdateParams struct { + + // Data. + Data *models.WritableASN + + /* ID. + + A unique integer value identifying this ASN. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam asns update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsUpdateParams) WithDefaults() *IpamAsnsUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam asns update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamAsnsUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam asns update params +func (o *IpamAsnsUpdateParams) WithTimeout(timeout time.Duration) *IpamAsnsUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam asns update params +func (o *IpamAsnsUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam asns update params +func (o *IpamAsnsUpdateParams) WithContext(ctx context.Context) *IpamAsnsUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam asns update params +func (o *IpamAsnsUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam asns update params +func (o *IpamAsnsUpdateParams) WithHTTPClient(client *http.Client) *IpamAsnsUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam asns update params +func (o *IpamAsnsUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam asns update params +func (o *IpamAsnsUpdateParams) WithData(data *models.WritableASN) *IpamAsnsUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam asns update params +func (o *IpamAsnsUpdateParams) SetData(data *models.WritableASN) { + o.Data = data +} + +// WithID adds the id to the ipam asns update params +func (o *IpamAsnsUpdateParams) WithID(id int64) *IpamAsnsUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam asns update params +func (o *IpamAsnsUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamAsnsUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_asns_update_responses.go b/netbox/client/ipam/ipam_asns_update_responses.go new file mode 100644 index 00000000..4aa7e94d --- /dev/null +++ b/netbox/client/ipam/ipam_asns_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamAsnsUpdateReader is a Reader for the IpamAsnsUpdate structure. +type IpamAsnsUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamAsnsUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamAsnsUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamAsnsUpdateOK creates a IpamAsnsUpdateOK with default headers values +func NewIpamAsnsUpdateOK() *IpamAsnsUpdateOK { + return &IpamAsnsUpdateOK{} +} + +/* IpamAsnsUpdateOK describes a response with status code 200, with default header values. + +IpamAsnsUpdateOK ipam asns update o k +*/ +type IpamAsnsUpdateOK struct { + Payload *models.ASN +} + +func (o *IpamAsnsUpdateOK) Error() string { + return fmt.Sprintf("[PUT /ipam/asns/{id}/][%d] ipamAsnsUpdateOK %+v", 200, o.Payload) +} +func (o *IpamAsnsUpdateOK) GetPayload() *models.ASN { + return o.Payload +} + +func (o *IpamAsnsUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ASN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_client.go b/netbox/client/ipam/ipam_client.go index 5e08cc22..81cebf0a 100644 --- a/netbox/client/ipam/ipam_client.go +++ b/netbox/client/ipam/ipam_client.go @@ -63,6 +63,60 @@ type ClientService interface { IpamAggregatesUpdate(params *IpamAggregatesUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAggregatesUpdateOK, error) + IpamAsnsBulkDelete(params *IpamAsnsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsBulkDeleteNoContent, error) + + IpamAsnsBulkPartialUpdate(params *IpamAsnsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsBulkPartialUpdateOK, error) + + IpamAsnsBulkUpdate(params *IpamAsnsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsBulkUpdateOK, error) + + IpamAsnsCreate(params *IpamAsnsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsCreateCreated, error) + + IpamAsnsDelete(params *IpamAsnsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsDeleteNoContent, error) + + IpamAsnsList(params *IpamAsnsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsListOK, error) + + IpamAsnsPartialUpdate(params *IpamAsnsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsPartialUpdateOK, error) + + IpamAsnsRead(params *IpamAsnsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsReadOK, error) + + IpamAsnsUpdate(params *IpamAsnsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsUpdateOK, error) + + IpamFhrpGroupAssignmentsBulkDelete(params *IpamFhrpGroupAssignmentsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsBulkDeleteNoContent, error) + + IpamFhrpGroupAssignmentsBulkPartialUpdate(params *IpamFhrpGroupAssignmentsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsBulkPartialUpdateOK, error) + + IpamFhrpGroupAssignmentsBulkUpdate(params *IpamFhrpGroupAssignmentsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsBulkUpdateOK, error) + + IpamFhrpGroupAssignmentsCreate(params *IpamFhrpGroupAssignmentsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsCreateCreated, error) + + IpamFhrpGroupAssignmentsDelete(params *IpamFhrpGroupAssignmentsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsDeleteNoContent, error) + + IpamFhrpGroupAssignmentsList(params *IpamFhrpGroupAssignmentsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsListOK, error) + + IpamFhrpGroupAssignmentsPartialUpdate(params *IpamFhrpGroupAssignmentsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsPartialUpdateOK, error) + + IpamFhrpGroupAssignmentsRead(params *IpamFhrpGroupAssignmentsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsReadOK, error) + + IpamFhrpGroupAssignmentsUpdate(params *IpamFhrpGroupAssignmentsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsUpdateOK, error) + + IpamFhrpGroupsBulkDelete(params *IpamFhrpGroupsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsBulkDeleteNoContent, error) + + IpamFhrpGroupsBulkPartialUpdate(params *IpamFhrpGroupsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsBulkPartialUpdateOK, error) + + IpamFhrpGroupsBulkUpdate(params *IpamFhrpGroupsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsBulkUpdateOK, error) + + IpamFhrpGroupsCreate(params *IpamFhrpGroupsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsCreateCreated, error) + + IpamFhrpGroupsDelete(params *IpamFhrpGroupsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsDeleteNoContent, error) + + IpamFhrpGroupsList(params *IpamFhrpGroupsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsListOK, error) + + IpamFhrpGroupsPartialUpdate(params *IpamFhrpGroupsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsPartialUpdateOK, error) + + IpamFhrpGroupsRead(params *IpamFhrpGroupsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsReadOK, error) + + IpamFhrpGroupsUpdate(params *IpamFhrpGroupsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsUpdateOK, error) + IpamIPAddressesBulkDelete(params *IpamIPAddressesBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesBulkDeleteNoContent, error) IpamIPAddressesBulkPartialUpdate(params *IpamIPAddressesBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesBulkPartialUpdateOK, error) @@ -83,7 +137,7 @@ type ClientService interface { IpamIPRangesAvailableIpsCreate(params *IpamIPRangesAvailableIpsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesAvailableIpsCreateCreated, error) - IpamIPRangesAvailableIpsRead(params *IpamIPRangesAvailableIpsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesAvailableIpsReadOK, error) + IpamIPRangesAvailableIpsList(params *IpamIPRangesAvailableIpsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesAvailableIpsListOK, error) IpamIPRangesBulkDelete(params *IpamIPRangesBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesBulkDeleteNoContent, error) @@ -105,11 +159,11 @@ type ClientService interface { IpamPrefixesAvailableIpsCreate(params *IpamPrefixesAvailableIpsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailableIpsCreateCreated, error) - IpamPrefixesAvailableIpsRead(params *IpamPrefixesAvailableIpsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailableIpsReadOK, error) + IpamPrefixesAvailableIpsList(params *IpamPrefixesAvailableIpsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailableIpsListOK, error) IpamPrefixesAvailablePrefixesCreate(params *IpamPrefixesAvailablePrefixesCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailablePrefixesCreateCreated, error) - IpamPrefixesAvailablePrefixesRead(params *IpamPrefixesAvailablePrefixesReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailablePrefixesReadOK, error) + IpamPrefixesAvailablePrefixesList(params *IpamPrefixesAvailablePrefixesListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailablePrefixesListOK, error) IpamPrefixesBulkDelete(params *IpamPrefixesBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesBulkDeleteNoContent, error) @@ -610,22 +664,22 @@ func (a *Client) IpamAggregatesUpdate(params *IpamAggregatesUpdateParams, authIn } /* - IpamIPAddressesBulkDelete ipam ip addresses bulk delete API + IpamAsnsBulkDelete ipam asns bulk delete API */ -func (a *Client) IpamIPAddressesBulkDelete(params *IpamIPAddressesBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesBulkDeleteNoContent, error) { +func (a *Client) IpamAsnsBulkDelete(params *IpamAsnsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsBulkDeleteNoContent, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPAddressesBulkDeleteParams() + params = NewIpamAsnsBulkDeleteParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-addresses_bulk_delete", + ID: "ipam_asns_bulk_delete", Method: "DELETE", - PathPattern: "/ipam/ip-addresses/", + PathPattern: "/ipam/asns/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPAddressesBulkDeleteReader{formats: a.formats}, + Reader: &IpamAsnsBulkDeleteReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -638,33 +692,33 @@ func (a *Client) IpamIPAddressesBulkDelete(params *IpamIPAddressesBulkDeletePara if err != nil { return nil, err } - success, ok := result.(*IpamIPAddressesBulkDeleteNoContent) + success, ok := result.(*IpamAsnsBulkDeleteNoContent) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_asns_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPAddressesBulkPartialUpdate ipam ip addresses bulk partial update API + IpamAsnsBulkPartialUpdate ipam asns bulk partial update API */ -func (a *Client) IpamIPAddressesBulkPartialUpdate(params *IpamIPAddressesBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesBulkPartialUpdateOK, error) { +func (a *Client) IpamAsnsBulkPartialUpdate(params *IpamAsnsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsBulkPartialUpdateOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPAddressesBulkPartialUpdateParams() + params = NewIpamAsnsBulkPartialUpdateParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-addresses_bulk_partial_update", + ID: "ipam_asns_bulk_partial_update", Method: "PATCH", - PathPattern: "/ipam/ip-addresses/", + PathPattern: "/ipam/asns/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPAddressesBulkPartialUpdateReader{formats: a.formats}, + Reader: &IpamAsnsBulkPartialUpdateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -677,33 +731,33 @@ func (a *Client) IpamIPAddressesBulkPartialUpdate(params *IpamIPAddressesBulkPar if err != nil { return nil, err } - success, ok := result.(*IpamIPAddressesBulkPartialUpdateOK) + success, ok := result.(*IpamAsnsBulkPartialUpdateOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_asns_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPAddressesBulkUpdate ipam ip addresses bulk update API + IpamAsnsBulkUpdate ipam asns bulk update API */ -func (a *Client) IpamIPAddressesBulkUpdate(params *IpamIPAddressesBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesBulkUpdateOK, error) { +func (a *Client) IpamAsnsBulkUpdate(params *IpamAsnsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsBulkUpdateOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPAddressesBulkUpdateParams() + params = NewIpamAsnsBulkUpdateParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-addresses_bulk_update", + ID: "ipam_asns_bulk_update", Method: "PUT", - PathPattern: "/ipam/ip-addresses/", + PathPattern: "/ipam/asns/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPAddressesBulkUpdateReader{formats: a.formats}, + Reader: &IpamAsnsBulkUpdateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -716,33 +770,33 @@ func (a *Client) IpamIPAddressesBulkUpdate(params *IpamIPAddressesBulkUpdatePara if err != nil { return nil, err } - success, ok := result.(*IpamIPAddressesBulkUpdateOK) + success, ok := result.(*IpamAsnsBulkUpdateOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_asns_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPAddressesCreate ipam ip addresses create API + IpamAsnsCreate ipam asns create API */ -func (a *Client) IpamIPAddressesCreate(params *IpamIPAddressesCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesCreateCreated, error) { +func (a *Client) IpamAsnsCreate(params *IpamAsnsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsCreateCreated, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPAddressesCreateParams() + params = NewIpamAsnsCreateParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-addresses_create", + ID: "ipam_asns_create", Method: "POST", - PathPattern: "/ipam/ip-addresses/", + PathPattern: "/ipam/asns/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPAddressesCreateReader{formats: a.formats}, + Reader: &IpamAsnsCreateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -755,33 +809,33 @@ func (a *Client) IpamIPAddressesCreate(params *IpamIPAddressesCreateParams, auth if err != nil { return nil, err } - success, ok := result.(*IpamIPAddressesCreateCreated) + success, ok := result.(*IpamAsnsCreateCreated) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_asns_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPAddressesDelete ipam ip addresses delete API + IpamAsnsDelete ipam asns delete API */ -func (a *Client) IpamIPAddressesDelete(params *IpamIPAddressesDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesDeleteNoContent, error) { +func (a *Client) IpamAsnsDelete(params *IpamAsnsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsDeleteNoContent, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPAddressesDeleteParams() + params = NewIpamAsnsDeleteParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-addresses_delete", + ID: "ipam_asns_delete", Method: "DELETE", - PathPattern: "/ipam/ip-addresses/{id}/", + PathPattern: "/ipam/asns/{id}/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPAddressesDeleteReader{formats: a.formats}, + Reader: &IpamAsnsDeleteReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -794,33 +848,33 @@ func (a *Client) IpamIPAddressesDelete(params *IpamIPAddressesDeleteParams, auth if err != nil { return nil, err } - success, ok := result.(*IpamIPAddressesDeleteNoContent) + success, ok := result.(*IpamAsnsDeleteNoContent) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_asns_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPAddressesList Overrides ListModelMixin to allow processing ExportTemplates. + IpamAsnsList Overrides ListModelMixin to allow processing ExportTemplates. */ -func (a *Client) IpamIPAddressesList(params *IpamIPAddressesListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesListOK, error) { +func (a *Client) IpamAsnsList(params *IpamAsnsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsListOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPAddressesListParams() + params = NewIpamAsnsListParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-addresses_list", + ID: "ipam_asns_list", Method: "GET", - PathPattern: "/ipam/ip-addresses/", + PathPattern: "/ipam/asns/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPAddressesListReader{formats: a.formats}, + Reader: &IpamAsnsListReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -833,33 +887,33 @@ func (a *Client) IpamIPAddressesList(params *IpamIPAddressesListParams, authInfo if err != nil { return nil, err } - success, ok := result.(*IpamIPAddressesListOK) + success, ok := result.(*IpamAsnsListOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_asns_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPAddressesPartialUpdate ipam ip addresses partial update API + IpamAsnsPartialUpdate ipam asns partial update API */ -func (a *Client) IpamIPAddressesPartialUpdate(params *IpamIPAddressesPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesPartialUpdateOK, error) { +func (a *Client) IpamAsnsPartialUpdate(params *IpamAsnsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsPartialUpdateOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPAddressesPartialUpdateParams() + params = NewIpamAsnsPartialUpdateParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-addresses_partial_update", + ID: "ipam_asns_partial_update", Method: "PATCH", - PathPattern: "/ipam/ip-addresses/{id}/", + PathPattern: "/ipam/asns/{id}/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPAddressesPartialUpdateReader{formats: a.formats}, + Reader: &IpamAsnsPartialUpdateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -872,33 +926,33 @@ func (a *Client) IpamIPAddressesPartialUpdate(params *IpamIPAddressesPartialUpda if err != nil { return nil, err } - success, ok := result.(*IpamIPAddressesPartialUpdateOK) + success, ok := result.(*IpamAsnsPartialUpdateOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_asns_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPAddressesRead ipam ip addresses read API + IpamAsnsRead ipam asns read API */ -func (a *Client) IpamIPAddressesRead(params *IpamIPAddressesReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesReadOK, error) { +func (a *Client) IpamAsnsRead(params *IpamAsnsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsReadOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPAddressesReadParams() + params = NewIpamAsnsReadParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-addresses_read", + ID: "ipam_asns_read", Method: "GET", - PathPattern: "/ipam/ip-addresses/{id}/", + PathPattern: "/ipam/asns/{id}/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPAddressesReadReader{formats: a.formats}, + Reader: &IpamAsnsReadReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -911,33 +965,33 @@ func (a *Client) IpamIPAddressesRead(params *IpamIPAddressesReadParams, authInfo if err != nil { return nil, err } - success, ok := result.(*IpamIPAddressesReadOK) + success, ok := result.(*IpamAsnsReadOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_asns_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPAddressesUpdate ipam ip addresses update API + IpamAsnsUpdate ipam asns update API */ -func (a *Client) IpamIPAddressesUpdate(params *IpamIPAddressesUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesUpdateOK, error) { +func (a *Client) IpamAsnsUpdate(params *IpamAsnsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamAsnsUpdateOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPAddressesUpdateParams() + params = NewIpamAsnsUpdateParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-addresses_update", + ID: "ipam_asns_update", Method: "PUT", - PathPattern: "/ipam/ip-addresses/{id}/", + PathPattern: "/ipam/asns/{id}/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPAddressesUpdateReader{formats: a.formats}, + Reader: &IpamAsnsUpdateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -950,38 +1004,33 @@ func (a *Client) IpamIPAddressesUpdate(params *IpamIPAddressesUpdateParams, auth if err != nil { return nil, err } - success, ok := result.(*IpamIPAddressesUpdateOK) + success, ok := result.(*IpamAsnsUpdateOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_asns_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPRangesAvailableIpsCreate A convenience method for returning available IP addresses within a Prefix or IPRange. By default, the number of -IPs returned will be equivalent to PAGINATE_COUNT. An arbitrary limit (up to MAX_PAGE_SIZE, if set) may be -passed, however results will not be paginated. - -The advisory lock decorator uses a PostgreSQL advisory lock to prevent this API from being -invoked in parallel, which results in a race condition where multiple insertions can occur. + IpamFhrpGroupAssignmentsBulkDelete ipam fhrp group assignments bulk delete API */ -func (a *Client) IpamIPRangesAvailableIpsCreate(params *IpamIPRangesAvailableIpsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesAvailableIpsCreateCreated, error) { +func (a *Client) IpamFhrpGroupAssignmentsBulkDelete(params *IpamFhrpGroupAssignmentsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsBulkDeleteNoContent, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPRangesAvailableIpsCreateParams() + params = NewIpamFhrpGroupAssignmentsBulkDeleteParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-ranges_available-ips_create", - Method: "POST", - PathPattern: "/ipam/ip-ranges/{id}/available-ips/", + ID: "ipam_fhrp-group-assignments_bulk_delete", + Method: "DELETE", + PathPattern: "/ipam/fhrp-group-assignments/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPRangesAvailableIpsCreateReader{formats: a.formats}, + Reader: &IpamFhrpGroupAssignmentsBulkDeleteReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -994,38 +1043,33 @@ func (a *Client) IpamIPRangesAvailableIpsCreate(params *IpamIPRangesAvailableIps if err != nil { return nil, err } - success, ok := result.(*IpamIPRangesAvailableIpsCreateCreated) + success, ok := result.(*IpamFhrpGroupAssignmentsBulkDeleteNoContent) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_available-ips_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-group-assignments_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPRangesAvailableIpsRead A convenience method for returning available IP addresses within a Prefix or IPRange. By default, the number of -IPs returned will be equivalent to PAGINATE_COUNT. An arbitrary limit (up to MAX_PAGE_SIZE, if set) may be -passed, however results will not be paginated. - -The advisory lock decorator uses a PostgreSQL advisory lock to prevent this API from being -invoked in parallel, which results in a race condition where multiple insertions can occur. + IpamFhrpGroupAssignmentsBulkPartialUpdate ipam fhrp group assignments bulk partial update API */ -func (a *Client) IpamIPRangesAvailableIpsRead(params *IpamIPRangesAvailableIpsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesAvailableIpsReadOK, error) { +func (a *Client) IpamFhrpGroupAssignmentsBulkPartialUpdate(params *IpamFhrpGroupAssignmentsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsBulkPartialUpdateOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPRangesAvailableIpsReadParams() + params = NewIpamFhrpGroupAssignmentsBulkPartialUpdateParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-ranges_available-ips_read", - Method: "GET", - PathPattern: "/ipam/ip-ranges/{id}/available-ips/", + ID: "ipam_fhrp-group-assignments_bulk_partial_update", + Method: "PATCH", + PathPattern: "/ipam/fhrp-group-assignments/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPRangesAvailableIpsReadReader{formats: a.formats}, + Reader: &IpamFhrpGroupAssignmentsBulkPartialUpdateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1038,33 +1082,33 @@ func (a *Client) IpamIPRangesAvailableIpsRead(params *IpamIPRangesAvailableIpsRe if err != nil { return nil, err } - success, ok := result.(*IpamIPRangesAvailableIpsReadOK) + success, ok := result.(*IpamFhrpGroupAssignmentsBulkPartialUpdateOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_available-ips_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-group-assignments_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPRangesBulkDelete ipam ip ranges bulk delete API + IpamFhrpGroupAssignmentsBulkUpdate ipam fhrp group assignments bulk update API */ -func (a *Client) IpamIPRangesBulkDelete(params *IpamIPRangesBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesBulkDeleteNoContent, error) { +func (a *Client) IpamFhrpGroupAssignmentsBulkUpdate(params *IpamFhrpGroupAssignmentsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsBulkUpdateOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPRangesBulkDeleteParams() + params = NewIpamFhrpGroupAssignmentsBulkUpdateParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-ranges_bulk_delete", - Method: "DELETE", - PathPattern: "/ipam/ip-ranges/", + ID: "ipam_fhrp-group-assignments_bulk_update", + Method: "PUT", + PathPattern: "/ipam/fhrp-group-assignments/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPRangesBulkDeleteReader{formats: a.formats}, + Reader: &IpamFhrpGroupAssignmentsBulkUpdateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1077,33 +1121,33 @@ func (a *Client) IpamIPRangesBulkDelete(params *IpamIPRangesBulkDeleteParams, au if err != nil { return nil, err } - success, ok := result.(*IpamIPRangesBulkDeleteNoContent) + success, ok := result.(*IpamFhrpGroupAssignmentsBulkUpdateOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-group-assignments_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPRangesBulkPartialUpdate ipam ip ranges bulk partial update API + IpamFhrpGroupAssignmentsCreate ipam fhrp group assignments create API */ -func (a *Client) IpamIPRangesBulkPartialUpdate(params *IpamIPRangesBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesBulkPartialUpdateOK, error) { +func (a *Client) IpamFhrpGroupAssignmentsCreate(params *IpamFhrpGroupAssignmentsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsCreateCreated, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPRangesBulkPartialUpdateParams() + params = NewIpamFhrpGroupAssignmentsCreateParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-ranges_bulk_partial_update", - Method: "PATCH", - PathPattern: "/ipam/ip-ranges/", + ID: "ipam_fhrp-group-assignments_create", + Method: "POST", + PathPattern: "/ipam/fhrp-group-assignments/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPRangesBulkPartialUpdateReader{formats: a.formats}, + Reader: &IpamFhrpGroupAssignmentsCreateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1116,33 +1160,33 @@ func (a *Client) IpamIPRangesBulkPartialUpdate(params *IpamIPRangesBulkPartialUp if err != nil { return nil, err } - success, ok := result.(*IpamIPRangesBulkPartialUpdateOK) + success, ok := result.(*IpamFhrpGroupAssignmentsCreateCreated) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-group-assignments_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPRangesBulkUpdate ipam ip ranges bulk update API + IpamFhrpGroupAssignmentsDelete ipam fhrp group assignments delete API */ -func (a *Client) IpamIPRangesBulkUpdate(params *IpamIPRangesBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesBulkUpdateOK, error) { +func (a *Client) IpamFhrpGroupAssignmentsDelete(params *IpamFhrpGroupAssignmentsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsDeleteNoContent, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPRangesBulkUpdateParams() + params = NewIpamFhrpGroupAssignmentsDeleteParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-ranges_bulk_update", - Method: "PUT", - PathPattern: "/ipam/ip-ranges/", + ID: "ipam_fhrp-group-assignments_delete", + Method: "DELETE", + PathPattern: "/ipam/fhrp-group-assignments/{id}/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPRangesBulkUpdateReader{formats: a.formats}, + Reader: &IpamFhrpGroupAssignmentsDeleteReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1155,33 +1199,33 @@ func (a *Client) IpamIPRangesBulkUpdate(params *IpamIPRangesBulkUpdateParams, au if err != nil { return nil, err } - success, ok := result.(*IpamIPRangesBulkUpdateOK) + success, ok := result.(*IpamFhrpGroupAssignmentsDeleteNoContent) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-group-assignments_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPRangesCreate ipam ip ranges create API + IpamFhrpGroupAssignmentsList Overrides ListModelMixin to allow processing ExportTemplates. */ -func (a *Client) IpamIPRangesCreate(params *IpamIPRangesCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesCreateCreated, error) { +func (a *Client) IpamFhrpGroupAssignmentsList(params *IpamFhrpGroupAssignmentsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsListOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPRangesCreateParams() + params = NewIpamFhrpGroupAssignmentsListParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-ranges_create", - Method: "POST", - PathPattern: "/ipam/ip-ranges/", + ID: "ipam_fhrp-group-assignments_list", + Method: "GET", + PathPattern: "/ipam/fhrp-group-assignments/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPRangesCreateReader{formats: a.formats}, + Reader: &IpamFhrpGroupAssignmentsListReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1194,33 +1238,33 @@ func (a *Client) IpamIPRangesCreate(params *IpamIPRangesCreateParams, authInfo r if err != nil { return nil, err } - success, ok := result.(*IpamIPRangesCreateCreated) + success, ok := result.(*IpamFhrpGroupAssignmentsListOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-group-assignments_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPRangesDelete ipam ip ranges delete API + IpamFhrpGroupAssignmentsPartialUpdate ipam fhrp group assignments partial update API */ -func (a *Client) IpamIPRangesDelete(params *IpamIPRangesDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesDeleteNoContent, error) { +func (a *Client) IpamFhrpGroupAssignmentsPartialUpdate(params *IpamFhrpGroupAssignmentsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsPartialUpdateOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPRangesDeleteParams() + params = NewIpamFhrpGroupAssignmentsPartialUpdateParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-ranges_delete", - Method: "DELETE", - PathPattern: "/ipam/ip-ranges/{id}/", + ID: "ipam_fhrp-group-assignments_partial_update", + Method: "PATCH", + PathPattern: "/ipam/fhrp-group-assignments/{id}/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPRangesDeleteReader{formats: a.formats}, + Reader: &IpamFhrpGroupAssignmentsPartialUpdateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1233,33 +1277,33 @@ func (a *Client) IpamIPRangesDelete(params *IpamIPRangesDeleteParams, authInfo r if err != nil { return nil, err } - success, ok := result.(*IpamIPRangesDeleteNoContent) + success, ok := result.(*IpamFhrpGroupAssignmentsPartialUpdateOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-group-assignments_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPRangesList Overrides ListModelMixin to allow processing ExportTemplates. + IpamFhrpGroupAssignmentsRead ipam fhrp group assignments read API */ -func (a *Client) IpamIPRangesList(params *IpamIPRangesListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesListOK, error) { +func (a *Client) IpamFhrpGroupAssignmentsRead(params *IpamFhrpGroupAssignmentsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsReadOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPRangesListParams() + params = NewIpamFhrpGroupAssignmentsReadParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-ranges_list", + ID: "ipam_fhrp-group-assignments_read", Method: "GET", - PathPattern: "/ipam/ip-ranges/", + PathPattern: "/ipam/fhrp-group-assignments/{id}/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPRangesListReader{formats: a.formats}, + Reader: &IpamFhrpGroupAssignmentsReadReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1272,33 +1316,33 @@ func (a *Client) IpamIPRangesList(params *IpamIPRangesListParams, authInfo runti if err != nil { return nil, err } - success, ok := result.(*IpamIPRangesListOK) + success, ok := result.(*IpamFhrpGroupAssignmentsReadOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-group-assignments_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPRangesPartialUpdate ipam ip ranges partial update API + IpamFhrpGroupAssignmentsUpdate ipam fhrp group assignments update API */ -func (a *Client) IpamIPRangesPartialUpdate(params *IpamIPRangesPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesPartialUpdateOK, error) { +func (a *Client) IpamFhrpGroupAssignmentsUpdate(params *IpamFhrpGroupAssignmentsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupAssignmentsUpdateOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPRangesPartialUpdateParams() + params = NewIpamFhrpGroupAssignmentsUpdateParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-ranges_partial_update", - Method: "PATCH", - PathPattern: "/ipam/ip-ranges/{id}/", + ID: "ipam_fhrp-group-assignments_update", + Method: "PUT", + PathPattern: "/ipam/fhrp-group-assignments/{id}/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPRangesPartialUpdateReader{formats: a.formats}, + Reader: &IpamFhrpGroupAssignmentsUpdateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1311,33 +1355,33 @@ func (a *Client) IpamIPRangesPartialUpdate(params *IpamIPRangesPartialUpdatePara if err != nil { return nil, err } - success, ok := result.(*IpamIPRangesPartialUpdateOK) + success, ok := result.(*IpamFhrpGroupAssignmentsUpdateOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-group-assignments_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPRangesRead ipam ip ranges read API + IpamFhrpGroupsBulkDelete ipam fhrp groups bulk delete API */ -func (a *Client) IpamIPRangesRead(params *IpamIPRangesReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesReadOK, error) { +func (a *Client) IpamFhrpGroupsBulkDelete(params *IpamFhrpGroupsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsBulkDeleteNoContent, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPRangesReadParams() + params = NewIpamFhrpGroupsBulkDeleteParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-ranges_read", - Method: "GET", - PathPattern: "/ipam/ip-ranges/{id}/", + ID: "ipam_fhrp-groups_bulk_delete", + Method: "DELETE", + PathPattern: "/ipam/fhrp-groups/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPRangesReadReader{formats: a.formats}, + Reader: &IpamFhrpGroupsBulkDeleteReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1350,33 +1394,33 @@ func (a *Client) IpamIPRangesRead(params *IpamIPRangesReadParams, authInfo runti if err != nil { return nil, err } - success, ok := result.(*IpamIPRangesReadOK) + success, ok := result.(*IpamFhrpGroupsBulkDeleteNoContent) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-groups_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamIPRangesUpdate ipam ip ranges update API + IpamFhrpGroupsBulkPartialUpdate ipam fhrp groups bulk partial update API */ -func (a *Client) IpamIPRangesUpdate(params *IpamIPRangesUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesUpdateOK, error) { +func (a *Client) IpamFhrpGroupsBulkPartialUpdate(params *IpamFhrpGroupsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsBulkPartialUpdateOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamIPRangesUpdateParams() + params = NewIpamFhrpGroupsBulkPartialUpdateParams() } op := &runtime.ClientOperation{ - ID: "ipam_ip-ranges_update", - Method: "PUT", - PathPattern: "/ipam/ip-ranges/{id}/", + ID: "ipam_fhrp-groups_bulk_partial_update", + Method: "PATCH", + PathPattern: "/ipam/fhrp-groups/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamIPRangesUpdateReader{formats: a.formats}, + Reader: &IpamFhrpGroupsBulkPartialUpdateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1389,38 +1433,72 @@ func (a *Client) IpamIPRangesUpdate(params *IpamIPRangesUpdateParams, authInfo r if err != nil { return nil, err } - success, ok := result.(*IpamIPRangesUpdateOK) + success, ok := result.(*IpamFhrpGroupsBulkPartialUpdateOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-groups_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamPrefixesAvailableIpsCreate A convenience method for returning available IP addresses within a Prefix or IPRange. By default, the number of -IPs returned will be equivalent to PAGINATE_COUNT. An arbitrary limit (up to MAX_PAGE_SIZE, if set) may be -passed, however results will not be paginated. + IpamFhrpGroupsBulkUpdate ipam fhrp groups bulk update API +*/ +func (a *Client) IpamFhrpGroupsBulkUpdate(params *IpamFhrpGroupsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsBulkUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamFhrpGroupsBulkUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_fhrp-groups_bulk_update", + Method: "PUT", + PathPattern: "/ipam/fhrp-groups/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamFhrpGroupsBulkUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamFhrpGroupsBulkUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-groups_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} -The advisory lock decorator uses a PostgreSQL advisory lock to prevent this API from being -invoked in parallel, which results in a race condition where multiple insertions can occur. +/* + IpamFhrpGroupsCreate ipam fhrp groups create API */ -func (a *Client) IpamPrefixesAvailableIpsCreate(params *IpamPrefixesAvailableIpsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailableIpsCreateCreated, error) { +func (a *Client) IpamFhrpGroupsCreate(params *IpamFhrpGroupsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsCreateCreated, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamPrefixesAvailableIpsCreateParams() + params = NewIpamFhrpGroupsCreateParams() } op := &runtime.ClientOperation{ - ID: "ipam_prefixes_available-ips_create", + ID: "ipam_fhrp-groups_create", Method: "POST", - PathPattern: "/ipam/prefixes/{id}/available-ips/", + PathPattern: "/ipam/fhrp-groups/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamPrefixesAvailableIpsCreateReader{formats: a.formats}, + Reader: &IpamFhrpGroupsCreateReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1433,38 +1511,33 @@ func (a *Client) IpamPrefixesAvailableIpsCreate(params *IpamPrefixesAvailableIps if err != nil { return nil, err } - success, ok := result.(*IpamPrefixesAvailableIpsCreateCreated) + success, ok := result.(*IpamFhrpGroupsCreateCreated) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_prefixes_available-ips_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-groups_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamPrefixesAvailableIpsRead A convenience method for returning available IP addresses within a Prefix or IPRange. By default, the number of -IPs returned will be equivalent to PAGINATE_COUNT. An arbitrary limit (up to MAX_PAGE_SIZE, if set) may be -passed, however results will not be paginated. - -The advisory lock decorator uses a PostgreSQL advisory lock to prevent this API from being -invoked in parallel, which results in a race condition where multiple insertions can occur. + IpamFhrpGroupsDelete ipam fhrp groups delete API */ -func (a *Client) IpamPrefixesAvailableIpsRead(params *IpamPrefixesAvailableIpsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailableIpsReadOK, error) { +func (a *Client) IpamFhrpGroupsDelete(params *IpamFhrpGroupsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsDeleteNoContent, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamPrefixesAvailableIpsReadParams() + params = NewIpamFhrpGroupsDeleteParams() } op := &runtime.ClientOperation{ - ID: "ipam_prefixes_available-ips_read", - Method: "GET", - PathPattern: "/ipam/prefixes/{id}/available-ips/", + ID: "ipam_fhrp-groups_delete", + Method: "DELETE", + PathPattern: "/ipam/fhrp-groups/{id}/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamPrefixesAvailableIpsReadReader{formats: a.formats}, + Reader: &IpamFhrpGroupsDeleteReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1477,36 +1550,33 @@ func (a *Client) IpamPrefixesAvailableIpsRead(params *IpamPrefixesAvailableIpsRe if err != nil { return nil, err } - success, ok := result.(*IpamPrefixesAvailableIpsReadOK) + success, ok := result.(*IpamFhrpGroupsDeleteNoContent) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_prefixes_available-ips_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-groups_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamPrefixesAvailablePrefixesCreate as convenience method for returning available child prefixes within a parent - - The advisory lock decorator uses a PostgreSQL advisory lock to prevent this API from being -invoked in parallel, which results in a race condition where multiple insertions can occur. + IpamFhrpGroupsList Overrides ListModelMixin to allow processing ExportTemplates. */ -func (a *Client) IpamPrefixesAvailablePrefixesCreate(params *IpamPrefixesAvailablePrefixesCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailablePrefixesCreateCreated, error) { +func (a *Client) IpamFhrpGroupsList(params *IpamFhrpGroupsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsListOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamPrefixesAvailablePrefixesCreateParams() + params = NewIpamFhrpGroupsListParams() } op := &runtime.ClientOperation{ - ID: "ipam_prefixes_available-prefixes_create", - Method: "POST", - PathPattern: "/ipam/prefixes/{id}/available-prefixes/", + ID: "ipam_fhrp-groups_list", + Method: "GET", + PathPattern: "/ipam/fhrp-groups/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamPrefixesAvailablePrefixesCreateReader{formats: a.formats}, + Reader: &IpamFhrpGroupsListReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1519,36 +1589,1047 @@ func (a *Client) IpamPrefixesAvailablePrefixesCreate(params *IpamPrefixesAvailab if err != nil { return nil, err } - success, ok := result.(*IpamPrefixesAvailablePrefixesCreateCreated) + success, ok := result.(*IpamFhrpGroupsListOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_prefixes_available-prefixes_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-groups_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } /* - IpamPrefixesAvailablePrefixesRead as convenience method for returning available child prefixes within a parent - - The advisory lock decorator uses a PostgreSQL advisory lock to prevent this API from being -invoked in parallel, which results in a race condition where multiple insertions can occur. + IpamFhrpGroupsPartialUpdate ipam fhrp groups partial update API +*/ +func (a *Client) IpamFhrpGroupsPartialUpdate(params *IpamFhrpGroupsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamFhrpGroupsPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_fhrp-groups_partial_update", + Method: "PATCH", + PathPattern: "/ipam/fhrp-groups/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamFhrpGroupsPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamFhrpGroupsPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-groups_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamFhrpGroupsRead ipam fhrp groups read API +*/ +func (a *Client) IpamFhrpGroupsRead(params *IpamFhrpGroupsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsReadOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamFhrpGroupsReadParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_fhrp-groups_read", + Method: "GET", + PathPattern: "/ipam/fhrp-groups/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamFhrpGroupsReadReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamFhrpGroupsReadOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-groups_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamFhrpGroupsUpdate ipam fhrp groups update API +*/ +func (a *Client) IpamFhrpGroupsUpdate(params *IpamFhrpGroupsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamFhrpGroupsUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamFhrpGroupsUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_fhrp-groups_update", + Method: "PUT", + PathPattern: "/ipam/fhrp-groups/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamFhrpGroupsUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamFhrpGroupsUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_fhrp-groups_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPAddressesBulkDelete ipam ip addresses bulk delete API +*/ +func (a *Client) IpamIPAddressesBulkDelete(params *IpamIPAddressesBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesBulkDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPAddressesBulkDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-addresses_bulk_delete", + Method: "DELETE", + PathPattern: "/ipam/ip-addresses/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPAddressesBulkDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPAddressesBulkDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPAddressesBulkPartialUpdate ipam ip addresses bulk partial update API +*/ +func (a *Client) IpamIPAddressesBulkPartialUpdate(params *IpamIPAddressesBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesBulkPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPAddressesBulkPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-addresses_bulk_partial_update", + Method: "PATCH", + PathPattern: "/ipam/ip-addresses/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPAddressesBulkPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPAddressesBulkPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPAddressesBulkUpdate ipam ip addresses bulk update API +*/ +func (a *Client) IpamIPAddressesBulkUpdate(params *IpamIPAddressesBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesBulkUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPAddressesBulkUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-addresses_bulk_update", + Method: "PUT", + PathPattern: "/ipam/ip-addresses/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPAddressesBulkUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPAddressesBulkUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPAddressesCreate ipam ip addresses create API +*/ +func (a *Client) IpamIPAddressesCreate(params *IpamIPAddressesCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPAddressesCreateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-addresses_create", + Method: "POST", + PathPattern: "/ipam/ip-addresses/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPAddressesCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPAddressesCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPAddressesDelete ipam ip addresses delete API +*/ +func (a *Client) IpamIPAddressesDelete(params *IpamIPAddressesDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPAddressesDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-addresses_delete", + Method: "DELETE", + PathPattern: "/ipam/ip-addresses/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPAddressesDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPAddressesDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPAddressesList Overrides ListModelMixin to allow processing ExportTemplates. +*/ +func (a *Client) IpamIPAddressesList(params *IpamIPAddressesListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesListOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPAddressesListParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-addresses_list", + Method: "GET", + PathPattern: "/ipam/ip-addresses/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPAddressesListReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPAddressesListOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPAddressesPartialUpdate ipam ip addresses partial update API +*/ +func (a *Client) IpamIPAddressesPartialUpdate(params *IpamIPAddressesPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPAddressesPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-addresses_partial_update", + Method: "PATCH", + PathPattern: "/ipam/ip-addresses/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPAddressesPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPAddressesPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPAddressesRead ipam ip addresses read API +*/ +func (a *Client) IpamIPAddressesRead(params *IpamIPAddressesReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesReadOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPAddressesReadParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-addresses_read", + Method: "GET", + PathPattern: "/ipam/ip-addresses/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPAddressesReadReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPAddressesReadOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPAddressesUpdate ipam ip addresses update API +*/ +func (a *Client) IpamIPAddressesUpdate(params *IpamIPAddressesUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPAddressesUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPAddressesUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-addresses_update", + Method: "PUT", + PathPattern: "/ipam/ip-addresses/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPAddressesUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPAddressesUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-addresses_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPRangesAvailableIpsCreate ipam ip ranges available ips create API +*/ +func (a *Client) IpamIPRangesAvailableIpsCreate(params *IpamIPRangesAvailableIpsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesAvailableIpsCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPRangesAvailableIpsCreateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-ranges_available-ips_create", + Method: "POST", + PathPattern: "/ipam/ip-ranges/{id}/available-ips/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPRangesAvailableIpsCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPRangesAvailableIpsCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_available-ips_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPRangesAvailableIpsList ipam ip ranges available ips list API +*/ +func (a *Client) IpamIPRangesAvailableIpsList(params *IpamIPRangesAvailableIpsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesAvailableIpsListOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPRangesAvailableIpsListParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-ranges_available-ips_list", + Method: "GET", + PathPattern: "/ipam/ip-ranges/{id}/available-ips/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPRangesAvailableIpsListReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPRangesAvailableIpsListOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_available-ips_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPRangesBulkDelete ipam ip ranges bulk delete API +*/ +func (a *Client) IpamIPRangesBulkDelete(params *IpamIPRangesBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesBulkDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPRangesBulkDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-ranges_bulk_delete", + Method: "DELETE", + PathPattern: "/ipam/ip-ranges/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPRangesBulkDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPRangesBulkDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPRangesBulkPartialUpdate ipam ip ranges bulk partial update API +*/ +func (a *Client) IpamIPRangesBulkPartialUpdate(params *IpamIPRangesBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesBulkPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPRangesBulkPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-ranges_bulk_partial_update", + Method: "PATCH", + PathPattern: "/ipam/ip-ranges/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPRangesBulkPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPRangesBulkPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPRangesBulkUpdate ipam ip ranges bulk update API +*/ +func (a *Client) IpamIPRangesBulkUpdate(params *IpamIPRangesBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesBulkUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPRangesBulkUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-ranges_bulk_update", + Method: "PUT", + PathPattern: "/ipam/ip-ranges/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPRangesBulkUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPRangesBulkUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPRangesCreate ipam ip ranges create API +*/ +func (a *Client) IpamIPRangesCreate(params *IpamIPRangesCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPRangesCreateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-ranges_create", + Method: "POST", + PathPattern: "/ipam/ip-ranges/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPRangesCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPRangesCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPRangesDelete ipam ip ranges delete API +*/ +func (a *Client) IpamIPRangesDelete(params *IpamIPRangesDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPRangesDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-ranges_delete", + Method: "DELETE", + PathPattern: "/ipam/ip-ranges/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPRangesDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPRangesDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPRangesList Overrides ListModelMixin to allow processing ExportTemplates. +*/ +func (a *Client) IpamIPRangesList(params *IpamIPRangesListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesListOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPRangesListParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-ranges_list", + Method: "GET", + PathPattern: "/ipam/ip-ranges/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPRangesListReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPRangesListOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPRangesPartialUpdate ipam ip ranges partial update API +*/ +func (a *Client) IpamIPRangesPartialUpdate(params *IpamIPRangesPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPRangesPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-ranges_partial_update", + Method: "PATCH", + PathPattern: "/ipam/ip-ranges/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPRangesPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPRangesPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPRangesRead ipam ip ranges read API +*/ +func (a *Client) IpamIPRangesRead(params *IpamIPRangesReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesReadOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPRangesReadParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-ranges_read", + Method: "GET", + PathPattern: "/ipam/ip-ranges/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPRangesReadReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPRangesReadOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamIPRangesUpdate ipam ip ranges update API +*/ +func (a *Client) IpamIPRangesUpdate(params *IpamIPRangesUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamIPRangesUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamIPRangesUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_ip-ranges_update", + Method: "PUT", + PathPattern: "/ipam/ip-ranges/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamIPRangesUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamIPRangesUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_ip-ranges_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamPrefixesAvailableIpsCreate ipam prefixes available ips create API +*/ +func (a *Client) IpamPrefixesAvailableIpsCreate(params *IpamPrefixesAvailableIpsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailableIpsCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamPrefixesAvailableIpsCreateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_prefixes_available-ips_create", + Method: "POST", + PathPattern: "/ipam/prefixes/{id}/available-ips/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamPrefixesAvailableIpsCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamPrefixesAvailableIpsCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_prefixes_available-ips_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamPrefixesAvailableIpsList ipam prefixes available ips list API +*/ +func (a *Client) IpamPrefixesAvailableIpsList(params *IpamPrefixesAvailableIpsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailableIpsListOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamPrefixesAvailableIpsListParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_prefixes_available-ips_list", + Method: "GET", + PathPattern: "/ipam/prefixes/{id}/available-ips/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamPrefixesAvailableIpsListReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamPrefixesAvailableIpsListOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_prefixes_available-ips_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamPrefixesAvailablePrefixesCreate ipam prefixes available prefixes create API +*/ +func (a *Client) IpamPrefixesAvailablePrefixesCreate(params *IpamPrefixesAvailablePrefixesCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailablePrefixesCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewIpamPrefixesAvailablePrefixesCreateParams() + } + op := &runtime.ClientOperation{ + ID: "ipam_prefixes_available-prefixes_create", + Method: "POST", + PathPattern: "/ipam/prefixes/{id}/available-prefixes/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &IpamPrefixesAvailablePrefixesCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*IpamPrefixesAvailablePrefixesCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for ipam_prefixes_available-prefixes_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + IpamPrefixesAvailablePrefixesList ipam prefixes available prefixes list API */ -func (a *Client) IpamPrefixesAvailablePrefixesRead(params *IpamPrefixesAvailablePrefixesReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailablePrefixesReadOK, error) { +func (a *Client) IpamPrefixesAvailablePrefixesList(params *IpamPrefixesAvailablePrefixesListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*IpamPrefixesAvailablePrefixesListOK, error) { // TODO: Validate the params before sending if params == nil { - params = NewIpamPrefixesAvailablePrefixesReadParams() + params = NewIpamPrefixesAvailablePrefixesListParams() } op := &runtime.ClientOperation{ - ID: "ipam_prefixes_available-prefixes_read", + ID: "ipam_prefixes_available-prefixes_list", Method: "GET", PathPattern: "/ipam/prefixes/{id}/available-prefixes/", ProducesMediaTypes: []string{"application/json"}, ConsumesMediaTypes: []string{"application/json"}, Schemes: []string{"http"}, Params: params, - Reader: &IpamPrefixesAvailablePrefixesReadReader{formats: a.formats}, + Reader: &IpamPrefixesAvailablePrefixesListReader{formats: a.formats}, AuthInfo: authInfo, Context: params.Context, Client: params.HTTPClient, @@ -1561,13 +2642,13 @@ func (a *Client) IpamPrefixesAvailablePrefixesRead(params *IpamPrefixesAvailable if err != nil { return nil, err } - success, ok := result.(*IpamPrefixesAvailablePrefixesReadOK) + success, ok := result.(*IpamPrefixesAvailablePrefixesListOK) if ok { return success, nil } // unexpected success response // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue - msg := fmt.Sprintf("unexpected success response for ipam_prefixes_available-prefixes_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + msg := fmt.Sprintf("unexpected success response for ipam_prefixes_available-prefixes_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) panic(msg) } diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_delete_parameters.go b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_delete_parameters.go new file mode 100644 index 00000000..92364e29 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_delete_parameters.go @@ -0,0 +1,141 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewIpamFhrpGroupAssignmentsBulkDeleteParams creates a new IpamFhrpGroupAssignmentsBulkDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupAssignmentsBulkDeleteParams() *IpamFhrpGroupAssignmentsBulkDeleteParams { + return &IpamFhrpGroupAssignmentsBulkDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupAssignmentsBulkDeleteParamsWithTimeout creates a new IpamFhrpGroupAssignmentsBulkDeleteParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupAssignmentsBulkDeleteParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsBulkDeleteParams { + return &IpamFhrpGroupAssignmentsBulkDeleteParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupAssignmentsBulkDeleteParamsWithContext creates a new IpamFhrpGroupAssignmentsBulkDeleteParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupAssignmentsBulkDeleteParamsWithContext(ctx context.Context) *IpamFhrpGroupAssignmentsBulkDeleteParams { + return &IpamFhrpGroupAssignmentsBulkDeleteParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupAssignmentsBulkDeleteParamsWithHTTPClient creates a new IpamFhrpGroupAssignmentsBulkDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupAssignmentsBulkDeleteParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsBulkDeleteParams { + return &IpamFhrpGroupAssignmentsBulkDeleteParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupAssignmentsBulkDeleteParams contains all the parameters to send to the API endpoint + for the ipam fhrp group assignments bulk delete operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupAssignmentsBulkDeleteParams struct { + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp group assignments bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsBulkDeleteParams) WithDefaults() *IpamFhrpGroupAssignmentsBulkDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp group assignments bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsBulkDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp group assignments bulk delete params +func (o *IpamFhrpGroupAssignmentsBulkDeleteParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsBulkDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp group assignments bulk delete params +func (o *IpamFhrpGroupAssignmentsBulkDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp group assignments bulk delete params +func (o *IpamFhrpGroupAssignmentsBulkDeleteParams) WithContext(ctx context.Context) *IpamFhrpGroupAssignmentsBulkDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp group assignments bulk delete params +func (o *IpamFhrpGroupAssignmentsBulkDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp group assignments bulk delete params +func (o *IpamFhrpGroupAssignmentsBulkDeleteParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsBulkDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp group assignments bulk delete params +func (o *IpamFhrpGroupAssignmentsBulkDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupAssignmentsBulkDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_delete_responses.go b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_delete_responses.go new file mode 100644 index 00000000..454e8212 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// IpamFhrpGroupAssignmentsBulkDeleteReader is a Reader for the IpamFhrpGroupAssignmentsBulkDelete structure. +type IpamFhrpGroupAssignmentsBulkDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupAssignmentsBulkDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewIpamFhrpGroupAssignmentsBulkDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupAssignmentsBulkDeleteNoContent creates a IpamFhrpGroupAssignmentsBulkDeleteNoContent with default headers values +func NewIpamFhrpGroupAssignmentsBulkDeleteNoContent() *IpamFhrpGroupAssignmentsBulkDeleteNoContent { + return &IpamFhrpGroupAssignmentsBulkDeleteNoContent{} +} + +/* IpamFhrpGroupAssignmentsBulkDeleteNoContent describes a response with status code 204, with default header values. + +IpamFhrpGroupAssignmentsBulkDeleteNoContent ipam fhrp group assignments bulk delete no content +*/ +type IpamFhrpGroupAssignmentsBulkDeleteNoContent struct { +} + +func (o *IpamFhrpGroupAssignmentsBulkDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /ipam/fhrp-group-assignments/][%d] ipamFhrpGroupAssignmentsBulkDeleteNoContent ", 204) +} + +func (o *IpamFhrpGroupAssignmentsBulkDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_partial_update_parameters.go b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_partial_update_parameters.go new file mode 100644 index 00000000..143f8319 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_partial_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamFhrpGroupAssignmentsBulkPartialUpdateParams creates a new IpamFhrpGroupAssignmentsBulkPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupAssignmentsBulkPartialUpdateParams() *IpamFhrpGroupAssignmentsBulkPartialUpdateParams { + return &IpamFhrpGroupAssignmentsBulkPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupAssignmentsBulkPartialUpdateParamsWithTimeout creates a new IpamFhrpGroupAssignmentsBulkPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupAssignmentsBulkPartialUpdateParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsBulkPartialUpdateParams { + return &IpamFhrpGroupAssignmentsBulkPartialUpdateParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupAssignmentsBulkPartialUpdateParamsWithContext creates a new IpamFhrpGroupAssignmentsBulkPartialUpdateParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupAssignmentsBulkPartialUpdateParamsWithContext(ctx context.Context) *IpamFhrpGroupAssignmentsBulkPartialUpdateParams { + return &IpamFhrpGroupAssignmentsBulkPartialUpdateParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupAssignmentsBulkPartialUpdateParamsWithHTTPClient creates a new IpamFhrpGroupAssignmentsBulkPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupAssignmentsBulkPartialUpdateParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsBulkPartialUpdateParams { + return &IpamFhrpGroupAssignmentsBulkPartialUpdateParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupAssignmentsBulkPartialUpdateParams contains all the parameters to send to the API endpoint + for the ipam fhrp group assignments bulk partial update operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupAssignmentsBulkPartialUpdateParams struct { + + // Data. + Data *models.WritableFHRPGroupAssignment + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp group assignments bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateParams) WithDefaults() *IpamFhrpGroupAssignmentsBulkPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp group assignments bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp group assignments bulk partial update params +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsBulkPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp group assignments bulk partial update params +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp group assignments bulk partial update params +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateParams) WithContext(ctx context.Context) *IpamFhrpGroupAssignmentsBulkPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp group assignments bulk partial update params +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp group assignments bulk partial update params +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsBulkPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp group assignments bulk partial update params +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam fhrp group assignments bulk partial update params +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateParams) WithData(data *models.WritableFHRPGroupAssignment) *IpamFhrpGroupAssignmentsBulkPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam fhrp group assignments bulk partial update params +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateParams) SetData(data *models.WritableFHRPGroupAssignment) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_partial_update_responses.go b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_partial_update_responses.go new file mode 100644 index 00000000..2d380484 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupAssignmentsBulkPartialUpdateReader is a Reader for the IpamFhrpGroupAssignmentsBulkPartialUpdate structure. +type IpamFhrpGroupAssignmentsBulkPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupAssignmentsBulkPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupAssignmentsBulkPartialUpdateOK creates a IpamFhrpGroupAssignmentsBulkPartialUpdateOK with default headers values +func NewIpamFhrpGroupAssignmentsBulkPartialUpdateOK() *IpamFhrpGroupAssignmentsBulkPartialUpdateOK { + return &IpamFhrpGroupAssignmentsBulkPartialUpdateOK{} +} + +/* IpamFhrpGroupAssignmentsBulkPartialUpdateOK describes a response with status code 200, with default header values. + +IpamFhrpGroupAssignmentsBulkPartialUpdateOK ipam fhrp group assignments bulk partial update o k +*/ +type IpamFhrpGroupAssignmentsBulkPartialUpdateOK struct { + Payload *models.FHRPGroupAssignment +} + +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /ipam/fhrp-group-assignments/][%d] ipamFhrpGroupAssignmentsBulkPartialUpdateOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateOK) GetPayload() *models.FHRPGroupAssignment { + return o.Payload +} + +func (o *IpamFhrpGroupAssignmentsBulkPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroupAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_update_parameters.go b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_update_parameters.go new file mode 100644 index 00000000..92ce054d --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamFhrpGroupAssignmentsBulkUpdateParams creates a new IpamFhrpGroupAssignmentsBulkUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupAssignmentsBulkUpdateParams() *IpamFhrpGroupAssignmentsBulkUpdateParams { + return &IpamFhrpGroupAssignmentsBulkUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupAssignmentsBulkUpdateParamsWithTimeout creates a new IpamFhrpGroupAssignmentsBulkUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupAssignmentsBulkUpdateParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsBulkUpdateParams { + return &IpamFhrpGroupAssignmentsBulkUpdateParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupAssignmentsBulkUpdateParamsWithContext creates a new IpamFhrpGroupAssignmentsBulkUpdateParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupAssignmentsBulkUpdateParamsWithContext(ctx context.Context) *IpamFhrpGroupAssignmentsBulkUpdateParams { + return &IpamFhrpGroupAssignmentsBulkUpdateParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupAssignmentsBulkUpdateParamsWithHTTPClient creates a new IpamFhrpGroupAssignmentsBulkUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupAssignmentsBulkUpdateParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsBulkUpdateParams { + return &IpamFhrpGroupAssignmentsBulkUpdateParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupAssignmentsBulkUpdateParams contains all the parameters to send to the API endpoint + for the ipam fhrp group assignments bulk update operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupAssignmentsBulkUpdateParams struct { + + // Data. + Data *models.WritableFHRPGroupAssignment + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp group assignments bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsBulkUpdateParams) WithDefaults() *IpamFhrpGroupAssignmentsBulkUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp group assignments bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsBulkUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp group assignments bulk update params +func (o *IpamFhrpGroupAssignmentsBulkUpdateParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsBulkUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp group assignments bulk update params +func (o *IpamFhrpGroupAssignmentsBulkUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp group assignments bulk update params +func (o *IpamFhrpGroupAssignmentsBulkUpdateParams) WithContext(ctx context.Context) *IpamFhrpGroupAssignmentsBulkUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp group assignments bulk update params +func (o *IpamFhrpGroupAssignmentsBulkUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp group assignments bulk update params +func (o *IpamFhrpGroupAssignmentsBulkUpdateParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsBulkUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp group assignments bulk update params +func (o *IpamFhrpGroupAssignmentsBulkUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam fhrp group assignments bulk update params +func (o *IpamFhrpGroupAssignmentsBulkUpdateParams) WithData(data *models.WritableFHRPGroupAssignment) *IpamFhrpGroupAssignmentsBulkUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam fhrp group assignments bulk update params +func (o *IpamFhrpGroupAssignmentsBulkUpdateParams) SetData(data *models.WritableFHRPGroupAssignment) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupAssignmentsBulkUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_update_responses.go b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_update_responses.go new file mode 100644 index 00000000..07c4e55e --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_bulk_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupAssignmentsBulkUpdateReader is a Reader for the IpamFhrpGroupAssignmentsBulkUpdate structure. +type IpamFhrpGroupAssignmentsBulkUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupAssignmentsBulkUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupAssignmentsBulkUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupAssignmentsBulkUpdateOK creates a IpamFhrpGroupAssignmentsBulkUpdateOK with default headers values +func NewIpamFhrpGroupAssignmentsBulkUpdateOK() *IpamFhrpGroupAssignmentsBulkUpdateOK { + return &IpamFhrpGroupAssignmentsBulkUpdateOK{} +} + +/* IpamFhrpGroupAssignmentsBulkUpdateOK describes a response with status code 200, with default header values. + +IpamFhrpGroupAssignmentsBulkUpdateOK ipam fhrp group assignments bulk update o k +*/ +type IpamFhrpGroupAssignmentsBulkUpdateOK struct { + Payload *models.FHRPGroupAssignment +} + +func (o *IpamFhrpGroupAssignmentsBulkUpdateOK) Error() string { + return fmt.Sprintf("[PUT /ipam/fhrp-group-assignments/][%d] ipamFhrpGroupAssignmentsBulkUpdateOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupAssignmentsBulkUpdateOK) GetPayload() *models.FHRPGroupAssignment { + return o.Payload +} + +func (o *IpamFhrpGroupAssignmentsBulkUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroupAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_create_parameters.go b/netbox/client/ipam/ipam_fhrp_group_assignments_create_parameters.go new file mode 100644 index 00000000..22f14ef0 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_create_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamFhrpGroupAssignmentsCreateParams creates a new IpamFhrpGroupAssignmentsCreateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupAssignmentsCreateParams() *IpamFhrpGroupAssignmentsCreateParams { + return &IpamFhrpGroupAssignmentsCreateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupAssignmentsCreateParamsWithTimeout creates a new IpamFhrpGroupAssignmentsCreateParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupAssignmentsCreateParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsCreateParams { + return &IpamFhrpGroupAssignmentsCreateParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupAssignmentsCreateParamsWithContext creates a new IpamFhrpGroupAssignmentsCreateParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupAssignmentsCreateParamsWithContext(ctx context.Context) *IpamFhrpGroupAssignmentsCreateParams { + return &IpamFhrpGroupAssignmentsCreateParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupAssignmentsCreateParamsWithHTTPClient creates a new IpamFhrpGroupAssignmentsCreateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupAssignmentsCreateParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsCreateParams { + return &IpamFhrpGroupAssignmentsCreateParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupAssignmentsCreateParams contains all the parameters to send to the API endpoint + for the ipam fhrp group assignments create operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupAssignmentsCreateParams struct { + + // Data. + Data *models.WritableFHRPGroupAssignment + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp group assignments create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsCreateParams) WithDefaults() *IpamFhrpGroupAssignmentsCreateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp group assignments create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsCreateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp group assignments create params +func (o *IpamFhrpGroupAssignmentsCreateParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsCreateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp group assignments create params +func (o *IpamFhrpGroupAssignmentsCreateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp group assignments create params +func (o *IpamFhrpGroupAssignmentsCreateParams) WithContext(ctx context.Context) *IpamFhrpGroupAssignmentsCreateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp group assignments create params +func (o *IpamFhrpGroupAssignmentsCreateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp group assignments create params +func (o *IpamFhrpGroupAssignmentsCreateParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsCreateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp group assignments create params +func (o *IpamFhrpGroupAssignmentsCreateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam fhrp group assignments create params +func (o *IpamFhrpGroupAssignmentsCreateParams) WithData(data *models.WritableFHRPGroupAssignment) *IpamFhrpGroupAssignmentsCreateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam fhrp group assignments create params +func (o *IpamFhrpGroupAssignmentsCreateParams) SetData(data *models.WritableFHRPGroupAssignment) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupAssignmentsCreateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_create_responses.go b/netbox/client/ipam/ipam_fhrp_group_assignments_create_responses.go new file mode 100644 index 00000000..c530098e --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_create_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupAssignmentsCreateReader is a Reader for the IpamFhrpGroupAssignmentsCreate structure. +type IpamFhrpGroupAssignmentsCreateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupAssignmentsCreateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 201: + result := NewIpamFhrpGroupAssignmentsCreateCreated() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupAssignmentsCreateCreated creates a IpamFhrpGroupAssignmentsCreateCreated with default headers values +func NewIpamFhrpGroupAssignmentsCreateCreated() *IpamFhrpGroupAssignmentsCreateCreated { + return &IpamFhrpGroupAssignmentsCreateCreated{} +} + +/* IpamFhrpGroupAssignmentsCreateCreated describes a response with status code 201, with default header values. + +IpamFhrpGroupAssignmentsCreateCreated ipam fhrp group assignments create created +*/ +type IpamFhrpGroupAssignmentsCreateCreated struct { + Payload *models.FHRPGroupAssignment +} + +func (o *IpamFhrpGroupAssignmentsCreateCreated) Error() string { + return fmt.Sprintf("[POST /ipam/fhrp-group-assignments/][%d] ipamFhrpGroupAssignmentsCreateCreated %+v", 201, o.Payload) +} +func (o *IpamFhrpGroupAssignmentsCreateCreated) GetPayload() *models.FHRPGroupAssignment { + return o.Payload +} + +func (o *IpamFhrpGroupAssignmentsCreateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroupAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_delete_parameters.go b/netbox/client/ipam/ipam_fhrp_group_assignments_delete_parameters.go new file mode 100644 index 00000000..6ed132d3 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_delete_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewIpamFhrpGroupAssignmentsDeleteParams creates a new IpamFhrpGroupAssignmentsDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupAssignmentsDeleteParams() *IpamFhrpGroupAssignmentsDeleteParams { + return &IpamFhrpGroupAssignmentsDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupAssignmentsDeleteParamsWithTimeout creates a new IpamFhrpGroupAssignmentsDeleteParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupAssignmentsDeleteParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsDeleteParams { + return &IpamFhrpGroupAssignmentsDeleteParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupAssignmentsDeleteParamsWithContext creates a new IpamFhrpGroupAssignmentsDeleteParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupAssignmentsDeleteParamsWithContext(ctx context.Context) *IpamFhrpGroupAssignmentsDeleteParams { + return &IpamFhrpGroupAssignmentsDeleteParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupAssignmentsDeleteParamsWithHTTPClient creates a new IpamFhrpGroupAssignmentsDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupAssignmentsDeleteParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsDeleteParams { + return &IpamFhrpGroupAssignmentsDeleteParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupAssignmentsDeleteParams contains all the parameters to send to the API endpoint + for the ipam fhrp group assignments delete operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupAssignmentsDeleteParams struct { + + /* ID. + + A unique integer value identifying this FHRP group assignment. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp group assignments delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsDeleteParams) WithDefaults() *IpamFhrpGroupAssignmentsDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp group assignments delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp group assignments delete params +func (o *IpamFhrpGroupAssignmentsDeleteParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp group assignments delete params +func (o *IpamFhrpGroupAssignmentsDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp group assignments delete params +func (o *IpamFhrpGroupAssignmentsDeleteParams) WithContext(ctx context.Context) *IpamFhrpGroupAssignmentsDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp group assignments delete params +func (o *IpamFhrpGroupAssignmentsDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp group assignments delete params +func (o *IpamFhrpGroupAssignmentsDeleteParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp group assignments delete params +func (o *IpamFhrpGroupAssignmentsDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the ipam fhrp group assignments delete params +func (o *IpamFhrpGroupAssignmentsDeleteParams) WithID(id int64) *IpamFhrpGroupAssignmentsDeleteParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam fhrp group assignments delete params +func (o *IpamFhrpGroupAssignmentsDeleteParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupAssignmentsDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_delete_responses.go b/netbox/client/ipam/ipam_fhrp_group_assignments_delete_responses.go new file mode 100644 index 00000000..d586b271 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// IpamFhrpGroupAssignmentsDeleteReader is a Reader for the IpamFhrpGroupAssignmentsDelete structure. +type IpamFhrpGroupAssignmentsDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupAssignmentsDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewIpamFhrpGroupAssignmentsDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupAssignmentsDeleteNoContent creates a IpamFhrpGroupAssignmentsDeleteNoContent with default headers values +func NewIpamFhrpGroupAssignmentsDeleteNoContent() *IpamFhrpGroupAssignmentsDeleteNoContent { + return &IpamFhrpGroupAssignmentsDeleteNoContent{} +} + +/* IpamFhrpGroupAssignmentsDeleteNoContent describes a response with status code 204, with default header values. + +IpamFhrpGroupAssignmentsDeleteNoContent ipam fhrp group assignments delete no content +*/ +type IpamFhrpGroupAssignmentsDeleteNoContent struct { +} + +func (o *IpamFhrpGroupAssignmentsDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /ipam/fhrp-group-assignments/{id}/][%d] ipamFhrpGroupAssignmentsDeleteNoContent ", 204) +} + +func (o *IpamFhrpGroupAssignmentsDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_list_parameters.go b/netbox/client/ipam/ipam_fhrp_group_assignments_list_parameters.go new file mode 100644 index 00000000..dedaafbf --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_list_parameters.go @@ -0,0 +1,1079 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewIpamFhrpGroupAssignmentsListParams creates a new IpamFhrpGroupAssignmentsListParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupAssignmentsListParams() *IpamFhrpGroupAssignmentsListParams { + return &IpamFhrpGroupAssignmentsListParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupAssignmentsListParamsWithTimeout creates a new IpamFhrpGroupAssignmentsListParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupAssignmentsListParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsListParams { + return &IpamFhrpGroupAssignmentsListParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupAssignmentsListParamsWithContext creates a new IpamFhrpGroupAssignmentsListParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupAssignmentsListParamsWithContext(ctx context.Context) *IpamFhrpGroupAssignmentsListParams { + return &IpamFhrpGroupAssignmentsListParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupAssignmentsListParamsWithHTTPClient creates a new IpamFhrpGroupAssignmentsListParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupAssignmentsListParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsListParams { + return &IpamFhrpGroupAssignmentsListParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupAssignmentsListParams contains all the parameters to send to the API endpoint + for the ipam fhrp group assignments list operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupAssignmentsListParams struct { + + // Created. + Created *string + + // CreatedGte. + CreatedGte *string + + // CreatedLte. + CreatedLte *string + + // GroupID. + GroupID *string + + // GroupIDn. + GroupIDn *string + + // ID. + ID *string + + // IDGt. + IDGt *string + + // IDGte. + IDGte *string + + // IDLt. + IDLt *string + + // IDLte. + IDLte *string + + // IDn. + IDn *string + + // InterfaceID. + InterfaceID *string + + // InterfaceIDGt. + InterfaceIDGt *string + + // InterfaceIDGte. + InterfaceIDGte *string + + // InterfaceIDLt. + InterfaceIDLt *string + + // InterfaceIDLte. + InterfaceIDLte *string + + // InterfaceIDn. + InterfaceIDn *string + + // InterfaceType. + InterfaceType *string + + // InterfaceTypen. + InterfaceTypen *string + + // LastUpdated. + LastUpdated *string + + // LastUpdatedGte. + LastUpdatedGte *string + + // LastUpdatedLte. + LastUpdatedLte *string + + /* Limit. + + Number of results to return per page. + */ + Limit *int64 + + /* Offset. + + The initial index from which to return the results. + */ + Offset *int64 + + // Priority. + Priority *string + + // PriorityGt. + PriorityGt *string + + // PriorityGte. + PriorityGte *string + + // PriorityLt. + PriorityLt *string + + // PriorityLte. + PriorityLte *string + + // Priorityn. + Priorityn *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp group assignments list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsListParams) WithDefaults() *IpamFhrpGroupAssignmentsListParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp group assignments list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsListParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsListParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithContext(ctx context.Context) *IpamFhrpGroupAssignmentsListParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsListParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithCreated adds the created to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithCreated(created *string) *IpamFhrpGroupAssignmentsListParams { + o.SetCreated(created) + return o +} + +// SetCreated adds the created to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetCreated(created *string) { + o.Created = created +} + +// WithCreatedGte adds the createdGte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithCreatedGte(createdGte *string) *IpamFhrpGroupAssignmentsListParams { + o.SetCreatedGte(createdGte) + return o +} + +// SetCreatedGte adds the createdGte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetCreatedGte(createdGte *string) { + o.CreatedGte = createdGte +} + +// WithCreatedLte adds the createdLte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithCreatedLte(createdLte *string) *IpamFhrpGroupAssignmentsListParams { + o.SetCreatedLte(createdLte) + return o +} + +// SetCreatedLte adds the createdLte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetCreatedLte(createdLte *string) { + o.CreatedLte = createdLte +} + +// WithGroupID adds the groupID to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithGroupID(groupID *string) *IpamFhrpGroupAssignmentsListParams { + o.SetGroupID(groupID) + return o +} + +// SetGroupID adds the groupId to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetGroupID(groupID *string) { + o.GroupID = groupID +} + +// WithGroupIDn adds the groupIDn to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithGroupIDn(groupIDn *string) *IpamFhrpGroupAssignmentsListParams { + o.SetGroupIDn(groupIDn) + return o +} + +// SetGroupIDn adds the groupIdN to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetGroupIDn(groupIDn *string) { + o.GroupIDn = groupIDn +} + +// WithID adds the id to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithID(id *string) *IpamFhrpGroupAssignmentsListParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetID(id *string) { + o.ID = id +} + +// WithIDGt adds the iDGt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithIDGt(iDGt *string) *IpamFhrpGroupAssignmentsListParams { + o.SetIDGt(iDGt) + return o +} + +// SetIDGt adds the idGt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetIDGt(iDGt *string) { + o.IDGt = iDGt +} + +// WithIDGte adds the iDGte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithIDGte(iDGte *string) *IpamFhrpGroupAssignmentsListParams { + o.SetIDGte(iDGte) + return o +} + +// SetIDGte adds the idGte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetIDGte(iDGte *string) { + o.IDGte = iDGte +} + +// WithIDLt adds the iDLt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithIDLt(iDLt *string) *IpamFhrpGroupAssignmentsListParams { + o.SetIDLt(iDLt) + return o +} + +// SetIDLt adds the idLt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetIDLt(iDLt *string) { + o.IDLt = iDLt +} + +// WithIDLte adds the iDLte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithIDLte(iDLte *string) *IpamFhrpGroupAssignmentsListParams { + o.SetIDLte(iDLte) + return o +} + +// SetIDLte adds the idLte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetIDLte(iDLte *string) { + o.IDLte = iDLte +} + +// WithIDn adds the iDn to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithIDn(iDn *string) *IpamFhrpGroupAssignmentsListParams { + o.SetIDn(iDn) + return o +} + +// SetIDn adds the idN to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetIDn(iDn *string) { + o.IDn = iDn +} + +// WithInterfaceID adds the interfaceID to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithInterfaceID(interfaceID *string) *IpamFhrpGroupAssignmentsListParams { + o.SetInterfaceID(interfaceID) + return o +} + +// SetInterfaceID adds the interfaceId to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetInterfaceID(interfaceID *string) { + o.InterfaceID = interfaceID +} + +// WithInterfaceIDGt adds the interfaceIDGt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithInterfaceIDGt(interfaceIDGt *string) *IpamFhrpGroupAssignmentsListParams { + o.SetInterfaceIDGt(interfaceIDGt) + return o +} + +// SetInterfaceIDGt adds the interfaceIdGt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetInterfaceIDGt(interfaceIDGt *string) { + o.InterfaceIDGt = interfaceIDGt +} + +// WithInterfaceIDGte adds the interfaceIDGte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithInterfaceIDGte(interfaceIDGte *string) *IpamFhrpGroupAssignmentsListParams { + o.SetInterfaceIDGte(interfaceIDGte) + return o +} + +// SetInterfaceIDGte adds the interfaceIdGte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetInterfaceIDGte(interfaceIDGte *string) { + o.InterfaceIDGte = interfaceIDGte +} + +// WithInterfaceIDLt adds the interfaceIDLt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithInterfaceIDLt(interfaceIDLt *string) *IpamFhrpGroupAssignmentsListParams { + o.SetInterfaceIDLt(interfaceIDLt) + return o +} + +// SetInterfaceIDLt adds the interfaceIdLt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetInterfaceIDLt(interfaceIDLt *string) { + o.InterfaceIDLt = interfaceIDLt +} + +// WithInterfaceIDLte adds the interfaceIDLte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithInterfaceIDLte(interfaceIDLte *string) *IpamFhrpGroupAssignmentsListParams { + o.SetInterfaceIDLte(interfaceIDLte) + return o +} + +// SetInterfaceIDLte adds the interfaceIdLte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetInterfaceIDLte(interfaceIDLte *string) { + o.InterfaceIDLte = interfaceIDLte +} + +// WithInterfaceIDn adds the interfaceIDn to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithInterfaceIDn(interfaceIDn *string) *IpamFhrpGroupAssignmentsListParams { + o.SetInterfaceIDn(interfaceIDn) + return o +} + +// SetInterfaceIDn adds the interfaceIdN to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetInterfaceIDn(interfaceIDn *string) { + o.InterfaceIDn = interfaceIDn +} + +// WithInterfaceType adds the interfaceType to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithInterfaceType(interfaceType *string) *IpamFhrpGroupAssignmentsListParams { + o.SetInterfaceType(interfaceType) + return o +} + +// SetInterfaceType adds the interfaceType to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetInterfaceType(interfaceType *string) { + o.InterfaceType = interfaceType +} + +// WithInterfaceTypen adds the interfaceTypen to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithInterfaceTypen(interfaceTypen *string) *IpamFhrpGroupAssignmentsListParams { + o.SetInterfaceTypen(interfaceTypen) + return o +} + +// SetInterfaceTypen adds the interfaceTypeN to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetInterfaceTypen(interfaceTypen *string) { + o.InterfaceTypen = interfaceTypen +} + +// WithLastUpdated adds the lastUpdated to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithLastUpdated(lastUpdated *string) *IpamFhrpGroupAssignmentsListParams { + o.SetLastUpdated(lastUpdated) + return o +} + +// SetLastUpdated adds the lastUpdated to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetLastUpdated(lastUpdated *string) { + o.LastUpdated = lastUpdated +} + +// WithLastUpdatedGte adds the lastUpdatedGte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithLastUpdatedGte(lastUpdatedGte *string) *IpamFhrpGroupAssignmentsListParams { + o.SetLastUpdatedGte(lastUpdatedGte) + return o +} + +// SetLastUpdatedGte adds the lastUpdatedGte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetLastUpdatedGte(lastUpdatedGte *string) { + o.LastUpdatedGte = lastUpdatedGte +} + +// WithLastUpdatedLte adds the lastUpdatedLte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithLastUpdatedLte(lastUpdatedLte *string) *IpamFhrpGroupAssignmentsListParams { + o.SetLastUpdatedLte(lastUpdatedLte) + return o +} + +// SetLastUpdatedLte adds the lastUpdatedLte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetLastUpdatedLte(lastUpdatedLte *string) { + o.LastUpdatedLte = lastUpdatedLte +} + +// WithLimit adds the limit to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithLimit(limit *int64) *IpamFhrpGroupAssignmentsListParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithOffset(offset *int64) *IpamFhrpGroupAssignmentsListParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithPriority adds the priority to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithPriority(priority *string) *IpamFhrpGroupAssignmentsListParams { + o.SetPriority(priority) + return o +} + +// SetPriority adds the priority to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetPriority(priority *string) { + o.Priority = priority +} + +// WithPriorityGt adds the priorityGt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithPriorityGt(priorityGt *string) *IpamFhrpGroupAssignmentsListParams { + o.SetPriorityGt(priorityGt) + return o +} + +// SetPriorityGt adds the priorityGt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetPriorityGt(priorityGt *string) { + o.PriorityGt = priorityGt +} + +// WithPriorityGte adds the priorityGte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithPriorityGte(priorityGte *string) *IpamFhrpGroupAssignmentsListParams { + o.SetPriorityGte(priorityGte) + return o +} + +// SetPriorityGte adds the priorityGte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetPriorityGte(priorityGte *string) { + o.PriorityGte = priorityGte +} + +// WithPriorityLt adds the priorityLt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithPriorityLt(priorityLt *string) *IpamFhrpGroupAssignmentsListParams { + o.SetPriorityLt(priorityLt) + return o +} + +// SetPriorityLt adds the priorityLt to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetPriorityLt(priorityLt *string) { + o.PriorityLt = priorityLt +} + +// WithPriorityLte adds the priorityLte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithPriorityLte(priorityLte *string) *IpamFhrpGroupAssignmentsListParams { + o.SetPriorityLte(priorityLte) + return o +} + +// SetPriorityLte adds the priorityLte to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetPriorityLte(priorityLte *string) { + o.PriorityLte = priorityLte +} + +// WithPriorityn adds the priorityn to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) WithPriorityn(priorityn *string) *IpamFhrpGroupAssignmentsListParams { + o.SetPriorityn(priorityn) + return o +} + +// SetPriorityn adds the priorityN to the ipam fhrp group assignments list params +func (o *IpamFhrpGroupAssignmentsListParams) SetPriorityn(priorityn *string) { + o.Priorityn = priorityn +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupAssignmentsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.Created != nil { + + // query param created + var qrCreated string + + if o.Created != nil { + qrCreated = *o.Created + } + qCreated := qrCreated + if qCreated != "" { + + if err := r.SetQueryParam("created", qCreated); err != nil { + return err + } + } + } + + if o.CreatedGte != nil { + + // query param created__gte + var qrCreatedGte string + + if o.CreatedGte != nil { + qrCreatedGte = *o.CreatedGte + } + qCreatedGte := qrCreatedGte + if qCreatedGte != "" { + + if err := r.SetQueryParam("created__gte", qCreatedGte); err != nil { + return err + } + } + } + + if o.CreatedLte != nil { + + // query param created__lte + var qrCreatedLte string + + if o.CreatedLte != nil { + qrCreatedLte = *o.CreatedLte + } + qCreatedLte := qrCreatedLte + if qCreatedLte != "" { + + if err := r.SetQueryParam("created__lte", qCreatedLte); err != nil { + return err + } + } + } + + if o.GroupID != nil { + + // query param group_id + var qrGroupID string + + if o.GroupID != nil { + qrGroupID = *o.GroupID + } + qGroupID := qrGroupID + if qGroupID != "" { + + if err := r.SetQueryParam("group_id", qGroupID); err != nil { + return err + } + } + } + + if o.GroupIDn != nil { + + // query param group_id__n + var qrGroupIDn string + + if o.GroupIDn != nil { + qrGroupIDn = *o.GroupIDn + } + qGroupIDn := qrGroupIDn + if qGroupIDn != "" { + + if err := r.SetQueryParam("group_id__n", qGroupIDn); err != nil { + return err + } + } + } + + if o.ID != nil { + + // query param id + var qrID string + + if o.ID != nil { + qrID = *o.ID + } + qID := qrID + if qID != "" { + + if err := r.SetQueryParam("id", qID); err != nil { + return err + } + } + } + + if o.IDGt != nil { + + // query param id__gt + var qrIDGt string + + if o.IDGt != nil { + qrIDGt = *o.IDGt + } + qIDGt := qrIDGt + if qIDGt != "" { + + if err := r.SetQueryParam("id__gt", qIDGt); err != nil { + return err + } + } + } + + if o.IDGte != nil { + + // query param id__gte + var qrIDGte string + + if o.IDGte != nil { + qrIDGte = *o.IDGte + } + qIDGte := qrIDGte + if qIDGte != "" { + + if err := r.SetQueryParam("id__gte", qIDGte); err != nil { + return err + } + } + } + + if o.IDLt != nil { + + // query param id__lt + var qrIDLt string + + if o.IDLt != nil { + qrIDLt = *o.IDLt + } + qIDLt := qrIDLt + if qIDLt != "" { + + if err := r.SetQueryParam("id__lt", qIDLt); err != nil { + return err + } + } + } + + if o.IDLte != nil { + + // query param id__lte + var qrIDLte string + + if o.IDLte != nil { + qrIDLte = *o.IDLte + } + qIDLte := qrIDLte + if qIDLte != "" { + + if err := r.SetQueryParam("id__lte", qIDLte); err != nil { + return err + } + } + } + + if o.IDn != nil { + + // query param id__n + var qrIDn string + + if o.IDn != nil { + qrIDn = *o.IDn + } + qIDn := qrIDn + if qIDn != "" { + + if err := r.SetQueryParam("id__n", qIDn); err != nil { + return err + } + } + } + + if o.InterfaceID != nil { + + // query param interface_id + var qrInterfaceID string + + if o.InterfaceID != nil { + qrInterfaceID = *o.InterfaceID + } + qInterfaceID := qrInterfaceID + if qInterfaceID != "" { + + if err := r.SetQueryParam("interface_id", qInterfaceID); err != nil { + return err + } + } + } + + if o.InterfaceIDGt != nil { + + // query param interface_id__gt + var qrInterfaceIDGt string + + if o.InterfaceIDGt != nil { + qrInterfaceIDGt = *o.InterfaceIDGt + } + qInterfaceIDGt := qrInterfaceIDGt + if qInterfaceIDGt != "" { + + if err := r.SetQueryParam("interface_id__gt", qInterfaceIDGt); err != nil { + return err + } + } + } + + if o.InterfaceIDGte != nil { + + // query param interface_id__gte + var qrInterfaceIDGte string + + if o.InterfaceIDGte != nil { + qrInterfaceIDGte = *o.InterfaceIDGte + } + qInterfaceIDGte := qrInterfaceIDGte + if qInterfaceIDGte != "" { + + if err := r.SetQueryParam("interface_id__gte", qInterfaceIDGte); err != nil { + return err + } + } + } + + if o.InterfaceIDLt != nil { + + // query param interface_id__lt + var qrInterfaceIDLt string + + if o.InterfaceIDLt != nil { + qrInterfaceIDLt = *o.InterfaceIDLt + } + qInterfaceIDLt := qrInterfaceIDLt + if qInterfaceIDLt != "" { + + if err := r.SetQueryParam("interface_id__lt", qInterfaceIDLt); err != nil { + return err + } + } + } + + if o.InterfaceIDLte != nil { + + // query param interface_id__lte + var qrInterfaceIDLte string + + if o.InterfaceIDLte != nil { + qrInterfaceIDLte = *o.InterfaceIDLte + } + qInterfaceIDLte := qrInterfaceIDLte + if qInterfaceIDLte != "" { + + if err := r.SetQueryParam("interface_id__lte", qInterfaceIDLte); err != nil { + return err + } + } + } + + if o.InterfaceIDn != nil { + + // query param interface_id__n + var qrInterfaceIDn string + + if o.InterfaceIDn != nil { + qrInterfaceIDn = *o.InterfaceIDn + } + qInterfaceIDn := qrInterfaceIDn + if qInterfaceIDn != "" { + + if err := r.SetQueryParam("interface_id__n", qInterfaceIDn); err != nil { + return err + } + } + } + + if o.InterfaceType != nil { + + // query param interface_type + var qrInterfaceType string + + if o.InterfaceType != nil { + qrInterfaceType = *o.InterfaceType + } + qInterfaceType := qrInterfaceType + if qInterfaceType != "" { + + if err := r.SetQueryParam("interface_type", qInterfaceType); err != nil { + return err + } + } + } + + if o.InterfaceTypen != nil { + + // query param interface_type__n + var qrInterfaceTypen string + + if o.InterfaceTypen != nil { + qrInterfaceTypen = *o.InterfaceTypen + } + qInterfaceTypen := qrInterfaceTypen + if qInterfaceTypen != "" { + + if err := r.SetQueryParam("interface_type__n", qInterfaceTypen); err != nil { + return err + } + } + } + + if o.LastUpdated != nil { + + // query param last_updated + var qrLastUpdated string + + if o.LastUpdated != nil { + qrLastUpdated = *o.LastUpdated + } + qLastUpdated := qrLastUpdated + if qLastUpdated != "" { + + if err := r.SetQueryParam("last_updated", qLastUpdated); err != nil { + return err + } + } + } + + if o.LastUpdatedGte != nil { + + // query param last_updated__gte + var qrLastUpdatedGte string + + if o.LastUpdatedGte != nil { + qrLastUpdatedGte = *o.LastUpdatedGte + } + qLastUpdatedGte := qrLastUpdatedGte + if qLastUpdatedGte != "" { + + if err := r.SetQueryParam("last_updated__gte", qLastUpdatedGte); err != nil { + return err + } + } + } + + if o.LastUpdatedLte != nil { + + // query param last_updated__lte + var qrLastUpdatedLte string + + if o.LastUpdatedLte != nil { + qrLastUpdatedLte = *o.LastUpdatedLte + } + qLastUpdatedLte := qrLastUpdatedLte + if qLastUpdatedLte != "" { + + if err := r.SetQueryParam("last_updated__lte", qLastUpdatedLte); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.Priority != nil { + + // query param priority + var qrPriority string + + if o.Priority != nil { + qrPriority = *o.Priority + } + qPriority := qrPriority + if qPriority != "" { + + if err := r.SetQueryParam("priority", qPriority); err != nil { + return err + } + } + } + + if o.PriorityGt != nil { + + // query param priority__gt + var qrPriorityGt string + + if o.PriorityGt != nil { + qrPriorityGt = *o.PriorityGt + } + qPriorityGt := qrPriorityGt + if qPriorityGt != "" { + + if err := r.SetQueryParam("priority__gt", qPriorityGt); err != nil { + return err + } + } + } + + if o.PriorityGte != nil { + + // query param priority__gte + var qrPriorityGte string + + if o.PriorityGte != nil { + qrPriorityGte = *o.PriorityGte + } + qPriorityGte := qrPriorityGte + if qPriorityGte != "" { + + if err := r.SetQueryParam("priority__gte", qPriorityGte); err != nil { + return err + } + } + } + + if o.PriorityLt != nil { + + // query param priority__lt + var qrPriorityLt string + + if o.PriorityLt != nil { + qrPriorityLt = *o.PriorityLt + } + qPriorityLt := qrPriorityLt + if qPriorityLt != "" { + + if err := r.SetQueryParam("priority__lt", qPriorityLt); err != nil { + return err + } + } + } + + if o.PriorityLte != nil { + + // query param priority__lte + var qrPriorityLte string + + if o.PriorityLte != nil { + qrPriorityLte = *o.PriorityLte + } + qPriorityLte := qrPriorityLte + if qPriorityLte != "" { + + if err := r.SetQueryParam("priority__lte", qPriorityLte); err != nil { + return err + } + } + } + + if o.Priorityn != nil { + + // query param priority__n + var qrPriorityn string + + if o.Priorityn != nil { + qrPriorityn = *o.Priorityn + } + qPriorityn := qrPriorityn + if qPriorityn != "" { + + if err := r.SetQueryParam("priority__n", qPriorityn); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_list_responses.go b/netbox/client/ipam/ipam_fhrp_group_assignments_list_responses.go new file mode 100644 index 00000000..a0589156 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_list_responses.go @@ -0,0 +1,247 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupAssignmentsListReader is a Reader for the IpamFhrpGroupAssignmentsList structure. +type IpamFhrpGroupAssignmentsListReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupAssignmentsListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupAssignmentsListOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupAssignmentsListOK creates a IpamFhrpGroupAssignmentsListOK with default headers values +func NewIpamFhrpGroupAssignmentsListOK() *IpamFhrpGroupAssignmentsListOK { + return &IpamFhrpGroupAssignmentsListOK{} +} + +/* IpamFhrpGroupAssignmentsListOK describes a response with status code 200, with default header values. + +IpamFhrpGroupAssignmentsListOK ipam fhrp group assignments list o k +*/ +type IpamFhrpGroupAssignmentsListOK struct { + Payload *IpamFhrpGroupAssignmentsListOKBody +} + +func (o *IpamFhrpGroupAssignmentsListOK) Error() string { + return fmt.Sprintf("[GET /ipam/fhrp-group-assignments/][%d] ipamFhrpGroupAssignmentsListOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupAssignmentsListOK) GetPayload() *IpamFhrpGroupAssignmentsListOKBody { + return o.Payload +} + +func (o *IpamFhrpGroupAssignmentsListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(IpamFhrpGroupAssignmentsListOKBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*IpamFhrpGroupAssignmentsListOKBody ipam fhrp group assignments list o k body +swagger:model IpamFhrpGroupAssignmentsListOKBody +*/ +type IpamFhrpGroupAssignmentsListOKBody struct { + + // count + // Required: true + Count *int64 `json:"count"` + + // next + // Format: uri + Next *strfmt.URI `json:"next,omitempty"` + + // previous + // Format: uri + Previous *strfmt.URI `json:"previous,omitempty"` + + // results + // Required: true + Results []*models.FHRPGroupAssignment `json:"results"` +} + +// Validate validates this ipam fhrp group assignments list o k body +func (o *IpamFhrpGroupAssignmentsListOKBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateCount(formats); err != nil { + res = append(res, err) + } + + if err := o.validateNext(formats); err != nil { + res = append(res, err) + } + + if err := o.validatePrevious(formats); err != nil { + res = append(res, err) + } + + if err := o.validateResults(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *IpamFhrpGroupAssignmentsListOKBody) validateCount(formats strfmt.Registry) error { + + if err := validate.Required("ipamFhrpGroupAssignmentsListOK"+"."+"count", "body", o.Count); err != nil { + return err + } + + return nil +} + +func (o *IpamFhrpGroupAssignmentsListOKBody) validateNext(formats strfmt.Registry) error { + if swag.IsZero(o.Next) { // not required + return nil + } + + if err := validate.FormatOf("ipamFhrpGroupAssignmentsListOK"+"."+"next", "body", "uri", o.Next.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *IpamFhrpGroupAssignmentsListOKBody) validatePrevious(formats strfmt.Registry) error { + if swag.IsZero(o.Previous) { // not required + return nil + } + + if err := validate.FormatOf("ipamFhrpGroupAssignmentsListOK"+"."+"previous", "body", "uri", o.Previous.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *IpamFhrpGroupAssignmentsListOKBody) validateResults(formats strfmt.Registry) error { + + if err := validate.Required("ipamFhrpGroupAssignmentsListOK"+"."+"results", "body", o.Results); err != nil { + return err + } + + for i := 0; i < len(o.Results); i++ { + if swag.IsZero(o.Results[i]) { // not required + continue + } + + if o.Results[i] != nil { + if err := o.Results[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("ipamFhrpGroupAssignmentsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("ipamFhrpGroupAssignmentsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this ipam fhrp group assignments list o k body based on the context it is used +func (o *IpamFhrpGroupAssignmentsListOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := o.contextValidateResults(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *IpamFhrpGroupAssignmentsListOKBody) contextValidateResults(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(o.Results); i++ { + + if o.Results[i] != nil { + if err := o.Results[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("ipamFhrpGroupAssignmentsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("ipamFhrpGroupAssignmentsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (o *IpamFhrpGroupAssignmentsListOKBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *IpamFhrpGroupAssignmentsListOKBody) UnmarshalBinary(b []byte) error { + var res IpamFhrpGroupAssignmentsListOKBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_partial_update_parameters.go b/netbox/client/ipam/ipam_fhrp_group_assignments_partial_update_parameters.go new file mode 100644 index 00000000..9ccecd90 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_partial_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamFhrpGroupAssignmentsPartialUpdateParams creates a new IpamFhrpGroupAssignmentsPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupAssignmentsPartialUpdateParams() *IpamFhrpGroupAssignmentsPartialUpdateParams { + return &IpamFhrpGroupAssignmentsPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupAssignmentsPartialUpdateParamsWithTimeout creates a new IpamFhrpGroupAssignmentsPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupAssignmentsPartialUpdateParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsPartialUpdateParams { + return &IpamFhrpGroupAssignmentsPartialUpdateParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupAssignmentsPartialUpdateParamsWithContext creates a new IpamFhrpGroupAssignmentsPartialUpdateParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupAssignmentsPartialUpdateParamsWithContext(ctx context.Context) *IpamFhrpGroupAssignmentsPartialUpdateParams { + return &IpamFhrpGroupAssignmentsPartialUpdateParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupAssignmentsPartialUpdateParamsWithHTTPClient creates a new IpamFhrpGroupAssignmentsPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupAssignmentsPartialUpdateParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsPartialUpdateParams { + return &IpamFhrpGroupAssignmentsPartialUpdateParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupAssignmentsPartialUpdateParams contains all the parameters to send to the API endpoint + for the ipam fhrp group assignments partial update operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupAssignmentsPartialUpdateParams struct { + + // Data. + Data *models.WritableFHRPGroupAssignment + + /* ID. + + A unique integer value identifying this FHRP group assignment. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp group assignments partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) WithDefaults() *IpamFhrpGroupAssignmentsPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp group assignments partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp group assignments partial update params +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp group assignments partial update params +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp group assignments partial update params +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) WithContext(ctx context.Context) *IpamFhrpGroupAssignmentsPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp group assignments partial update params +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp group assignments partial update params +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp group assignments partial update params +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam fhrp group assignments partial update params +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) WithData(data *models.WritableFHRPGroupAssignment) *IpamFhrpGroupAssignmentsPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam fhrp group assignments partial update params +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) SetData(data *models.WritableFHRPGroupAssignment) { + o.Data = data +} + +// WithID adds the id to the ipam fhrp group assignments partial update params +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) WithID(id int64) *IpamFhrpGroupAssignmentsPartialUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam fhrp group assignments partial update params +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupAssignmentsPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_partial_update_responses.go b/netbox/client/ipam/ipam_fhrp_group_assignments_partial_update_responses.go new file mode 100644 index 00000000..1fb61c81 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupAssignmentsPartialUpdateReader is a Reader for the IpamFhrpGroupAssignmentsPartialUpdate structure. +type IpamFhrpGroupAssignmentsPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupAssignmentsPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupAssignmentsPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupAssignmentsPartialUpdateOK creates a IpamFhrpGroupAssignmentsPartialUpdateOK with default headers values +func NewIpamFhrpGroupAssignmentsPartialUpdateOK() *IpamFhrpGroupAssignmentsPartialUpdateOK { + return &IpamFhrpGroupAssignmentsPartialUpdateOK{} +} + +/* IpamFhrpGroupAssignmentsPartialUpdateOK describes a response with status code 200, with default header values. + +IpamFhrpGroupAssignmentsPartialUpdateOK ipam fhrp group assignments partial update o k +*/ +type IpamFhrpGroupAssignmentsPartialUpdateOK struct { + Payload *models.FHRPGroupAssignment +} + +func (o *IpamFhrpGroupAssignmentsPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /ipam/fhrp-group-assignments/{id}/][%d] ipamFhrpGroupAssignmentsPartialUpdateOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupAssignmentsPartialUpdateOK) GetPayload() *models.FHRPGroupAssignment { + return o.Payload +} + +func (o *IpamFhrpGroupAssignmentsPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroupAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_read_parameters.go b/netbox/client/ipam/ipam_fhrp_group_assignments_read_parameters.go new file mode 100644 index 00000000..daf7f084 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_read_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewIpamFhrpGroupAssignmentsReadParams creates a new IpamFhrpGroupAssignmentsReadParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupAssignmentsReadParams() *IpamFhrpGroupAssignmentsReadParams { + return &IpamFhrpGroupAssignmentsReadParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupAssignmentsReadParamsWithTimeout creates a new IpamFhrpGroupAssignmentsReadParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupAssignmentsReadParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsReadParams { + return &IpamFhrpGroupAssignmentsReadParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupAssignmentsReadParamsWithContext creates a new IpamFhrpGroupAssignmentsReadParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupAssignmentsReadParamsWithContext(ctx context.Context) *IpamFhrpGroupAssignmentsReadParams { + return &IpamFhrpGroupAssignmentsReadParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupAssignmentsReadParamsWithHTTPClient creates a new IpamFhrpGroupAssignmentsReadParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupAssignmentsReadParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsReadParams { + return &IpamFhrpGroupAssignmentsReadParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupAssignmentsReadParams contains all the parameters to send to the API endpoint + for the ipam fhrp group assignments read operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupAssignmentsReadParams struct { + + /* ID. + + A unique integer value identifying this FHRP group assignment. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp group assignments read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsReadParams) WithDefaults() *IpamFhrpGroupAssignmentsReadParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp group assignments read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsReadParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp group assignments read params +func (o *IpamFhrpGroupAssignmentsReadParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsReadParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp group assignments read params +func (o *IpamFhrpGroupAssignmentsReadParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp group assignments read params +func (o *IpamFhrpGroupAssignmentsReadParams) WithContext(ctx context.Context) *IpamFhrpGroupAssignmentsReadParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp group assignments read params +func (o *IpamFhrpGroupAssignmentsReadParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp group assignments read params +func (o *IpamFhrpGroupAssignmentsReadParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsReadParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp group assignments read params +func (o *IpamFhrpGroupAssignmentsReadParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the ipam fhrp group assignments read params +func (o *IpamFhrpGroupAssignmentsReadParams) WithID(id int64) *IpamFhrpGroupAssignmentsReadParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam fhrp group assignments read params +func (o *IpamFhrpGroupAssignmentsReadParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupAssignmentsReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_read_responses.go b/netbox/client/ipam/ipam_fhrp_group_assignments_read_responses.go new file mode 100644 index 00000000..be7b0c7e --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_read_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupAssignmentsReadReader is a Reader for the IpamFhrpGroupAssignmentsRead structure. +type IpamFhrpGroupAssignmentsReadReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupAssignmentsReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupAssignmentsReadOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupAssignmentsReadOK creates a IpamFhrpGroupAssignmentsReadOK with default headers values +func NewIpamFhrpGroupAssignmentsReadOK() *IpamFhrpGroupAssignmentsReadOK { + return &IpamFhrpGroupAssignmentsReadOK{} +} + +/* IpamFhrpGroupAssignmentsReadOK describes a response with status code 200, with default header values. + +IpamFhrpGroupAssignmentsReadOK ipam fhrp group assignments read o k +*/ +type IpamFhrpGroupAssignmentsReadOK struct { + Payload *models.FHRPGroupAssignment +} + +func (o *IpamFhrpGroupAssignmentsReadOK) Error() string { + return fmt.Sprintf("[GET /ipam/fhrp-group-assignments/{id}/][%d] ipamFhrpGroupAssignmentsReadOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupAssignmentsReadOK) GetPayload() *models.FHRPGroupAssignment { + return o.Payload +} + +func (o *IpamFhrpGroupAssignmentsReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroupAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_update_parameters.go b/netbox/client/ipam/ipam_fhrp_group_assignments_update_parameters.go new file mode 100644 index 00000000..ad6dca7e --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamFhrpGroupAssignmentsUpdateParams creates a new IpamFhrpGroupAssignmentsUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupAssignmentsUpdateParams() *IpamFhrpGroupAssignmentsUpdateParams { + return &IpamFhrpGroupAssignmentsUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupAssignmentsUpdateParamsWithTimeout creates a new IpamFhrpGroupAssignmentsUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupAssignmentsUpdateParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsUpdateParams { + return &IpamFhrpGroupAssignmentsUpdateParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupAssignmentsUpdateParamsWithContext creates a new IpamFhrpGroupAssignmentsUpdateParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupAssignmentsUpdateParamsWithContext(ctx context.Context) *IpamFhrpGroupAssignmentsUpdateParams { + return &IpamFhrpGroupAssignmentsUpdateParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupAssignmentsUpdateParamsWithHTTPClient creates a new IpamFhrpGroupAssignmentsUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupAssignmentsUpdateParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsUpdateParams { + return &IpamFhrpGroupAssignmentsUpdateParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupAssignmentsUpdateParams contains all the parameters to send to the API endpoint + for the ipam fhrp group assignments update operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupAssignmentsUpdateParams struct { + + // Data. + Data *models.WritableFHRPGroupAssignment + + /* ID. + + A unique integer value identifying this FHRP group assignment. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp group assignments update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsUpdateParams) WithDefaults() *IpamFhrpGroupAssignmentsUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp group assignments update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupAssignmentsUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp group assignments update params +func (o *IpamFhrpGroupAssignmentsUpdateParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupAssignmentsUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp group assignments update params +func (o *IpamFhrpGroupAssignmentsUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp group assignments update params +func (o *IpamFhrpGroupAssignmentsUpdateParams) WithContext(ctx context.Context) *IpamFhrpGroupAssignmentsUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp group assignments update params +func (o *IpamFhrpGroupAssignmentsUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp group assignments update params +func (o *IpamFhrpGroupAssignmentsUpdateParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupAssignmentsUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp group assignments update params +func (o *IpamFhrpGroupAssignmentsUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam fhrp group assignments update params +func (o *IpamFhrpGroupAssignmentsUpdateParams) WithData(data *models.WritableFHRPGroupAssignment) *IpamFhrpGroupAssignmentsUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam fhrp group assignments update params +func (o *IpamFhrpGroupAssignmentsUpdateParams) SetData(data *models.WritableFHRPGroupAssignment) { + o.Data = data +} + +// WithID adds the id to the ipam fhrp group assignments update params +func (o *IpamFhrpGroupAssignmentsUpdateParams) WithID(id int64) *IpamFhrpGroupAssignmentsUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam fhrp group assignments update params +func (o *IpamFhrpGroupAssignmentsUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupAssignmentsUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_group_assignments_update_responses.go b/netbox/client/ipam/ipam_fhrp_group_assignments_update_responses.go new file mode 100644 index 00000000..d1c82b29 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_group_assignments_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupAssignmentsUpdateReader is a Reader for the IpamFhrpGroupAssignmentsUpdate structure. +type IpamFhrpGroupAssignmentsUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupAssignmentsUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupAssignmentsUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupAssignmentsUpdateOK creates a IpamFhrpGroupAssignmentsUpdateOK with default headers values +func NewIpamFhrpGroupAssignmentsUpdateOK() *IpamFhrpGroupAssignmentsUpdateOK { + return &IpamFhrpGroupAssignmentsUpdateOK{} +} + +/* IpamFhrpGroupAssignmentsUpdateOK describes a response with status code 200, with default header values. + +IpamFhrpGroupAssignmentsUpdateOK ipam fhrp group assignments update o k +*/ +type IpamFhrpGroupAssignmentsUpdateOK struct { + Payload *models.FHRPGroupAssignment +} + +func (o *IpamFhrpGroupAssignmentsUpdateOK) Error() string { + return fmt.Sprintf("[PUT /ipam/fhrp-group-assignments/{id}/][%d] ipamFhrpGroupAssignmentsUpdateOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupAssignmentsUpdateOK) GetPayload() *models.FHRPGroupAssignment { + return o.Payload +} + +func (o *IpamFhrpGroupAssignmentsUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroupAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_bulk_delete_parameters.go b/netbox/client/ipam/ipam_fhrp_groups_bulk_delete_parameters.go new file mode 100644 index 00000000..923bdf3d --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_bulk_delete_parameters.go @@ -0,0 +1,141 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewIpamFhrpGroupsBulkDeleteParams creates a new IpamFhrpGroupsBulkDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupsBulkDeleteParams() *IpamFhrpGroupsBulkDeleteParams { + return &IpamFhrpGroupsBulkDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupsBulkDeleteParamsWithTimeout creates a new IpamFhrpGroupsBulkDeleteParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupsBulkDeleteParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupsBulkDeleteParams { + return &IpamFhrpGroupsBulkDeleteParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupsBulkDeleteParamsWithContext creates a new IpamFhrpGroupsBulkDeleteParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupsBulkDeleteParamsWithContext(ctx context.Context) *IpamFhrpGroupsBulkDeleteParams { + return &IpamFhrpGroupsBulkDeleteParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupsBulkDeleteParamsWithHTTPClient creates a new IpamFhrpGroupsBulkDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupsBulkDeleteParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupsBulkDeleteParams { + return &IpamFhrpGroupsBulkDeleteParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupsBulkDeleteParams contains all the parameters to send to the API endpoint + for the ipam fhrp groups bulk delete operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupsBulkDeleteParams struct { + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp groups bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsBulkDeleteParams) WithDefaults() *IpamFhrpGroupsBulkDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp groups bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsBulkDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp groups bulk delete params +func (o *IpamFhrpGroupsBulkDeleteParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupsBulkDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp groups bulk delete params +func (o *IpamFhrpGroupsBulkDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp groups bulk delete params +func (o *IpamFhrpGroupsBulkDeleteParams) WithContext(ctx context.Context) *IpamFhrpGroupsBulkDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp groups bulk delete params +func (o *IpamFhrpGroupsBulkDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp groups bulk delete params +func (o *IpamFhrpGroupsBulkDeleteParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupsBulkDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp groups bulk delete params +func (o *IpamFhrpGroupsBulkDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupsBulkDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_bulk_delete_responses.go b/netbox/client/ipam/ipam_fhrp_groups_bulk_delete_responses.go new file mode 100644 index 00000000..2a6c849d --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_bulk_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// IpamFhrpGroupsBulkDeleteReader is a Reader for the IpamFhrpGroupsBulkDelete structure. +type IpamFhrpGroupsBulkDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupsBulkDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewIpamFhrpGroupsBulkDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupsBulkDeleteNoContent creates a IpamFhrpGroupsBulkDeleteNoContent with default headers values +func NewIpamFhrpGroupsBulkDeleteNoContent() *IpamFhrpGroupsBulkDeleteNoContent { + return &IpamFhrpGroupsBulkDeleteNoContent{} +} + +/* IpamFhrpGroupsBulkDeleteNoContent describes a response with status code 204, with default header values. + +IpamFhrpGroupsBulkDeleteNoContent ipam fhrp groups bulk delete no content +*/ +type IpamFhrpGroupsBulkDeleteNoContent struct { +} + +func (o *IpamFhrpGroupsBulkDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /ipam/fhrp-groups/][%d] ipamFhrpGroupsBulkDeleteNoContent ", 204) +} + +func (o *IpamFhrpGroupsBulkDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_bulk_partial_update_parameters.go b/netbox/client/ipam/ipam_fhrp_groups_bulk_partial_update_parameters.go new file mode 100644 index 00000000..a3b4985b --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_bulk_partial_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamFhrpGroupsBulkPartialUpdateParams creates a new IpamFhrpGroupsBulkPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupsBulkPartialUpdateParams() *IpamFhrpGroupsBulkPartialUpdateParams { + return &IpamFhrpGroupsBulkPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupsBulkPartialUpdateParamsWithTimeout creates a new IpamFhrpGroupsBulkPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupsBulkPartialUpdateParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupsBulkPartialUpdateParams { + return &IpamFhrpGroupsBulkPartialUpdateParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupsBulkPartialUpdateParamsWithContext creates a new IpamFhrpGroupsBulkPartialUpdateParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupsBulkPartialUpdateParamsWithContext(ctx context.Context) *IpamFhrpGroupsBulkPartialUpdateParams { + return &IpamFhrpGroupsBulkPartialUpdateParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupsBulkPartialUpdateParamsWithHTTPClient creates a new IpamFhrpGroupsBulkPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupsBulkPartialUpdateParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupsBulkPartialUpdateParams { + return &IpamFhrpGroupsBulkPartialUpdateParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupsBulkPartialUpdateParams contains all the parameters to send to the API endpoint + for the ipam fhrp groups bulk partial update operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupsBulkPartialUpdateParams struct { + + // Data. + Data *models.FHRPGroup + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp groups bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsBulkPartialUpdateParams) WithDefaults() *IpamFhrpGroupsBulkPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp groups bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsBulkPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp groups bulk partial update params +func (o *IpamFhrpGroupsBulkPartialUpdateParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupsBulkPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp groups bulk partial update params +func (o *IpamFhrpGroupsBulkPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp groups bulk partial update params +func (o *IpamFhrpGroupsBulkPartialUpdateParams) WithContext(ctx context.Context) *IpamFhrpGroupsBulkPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp groups bulk partial update params +func (o *IpamFhrpGroupsBulkPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp groups bulk partial update params +func (o *IpamFhrpGroupsBulkPartialUpdateParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupsBulkPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp groups bulk partial update params +func (o *IpamFhrpGroupsBulkPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam fhrp groups bulk partial update params +func (o *IpamFhrpGroupsBulkPartialUpdateParams) WithData(data *models.FHRPGroup) *IpamFhrpGroupsBulkPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam fhrp groups bulk partial update params +func (o *IpamFhrpGroupsBulkPartialUpdateParams) SetData(data *models.FHRPGroup) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupsBulkPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_bulk_partial_update_responses.go b/netbox/client/ipam/ipam_fhrp_groups_bulk_partial_update_responses.go new file mode 100644 index 00000000..875c4870 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_bulk_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupsBulkPartialUpdateReader is a Reader for the IpamFhrpGroupsBulkPartialUpdate structure. +type IpamFhrpGroupsBulkPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupsBulkPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupsBulkPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupsBulkPartialUpdateOK creates a IpamFhrpGroupsBulkPartialUpdateOK with default headers values +func NewIpamFhrpGroupsBulkPartialUpdateOK() *IpamFhrpGroupsBulkPartialUpdateOK { + return &IpamFhrpGroupsBulkPartialUpdateOK{} +} + +/* IpamFhrpGroupsBulkPartialUpdateOK describes a response with status code 200, with default header values. + +IpamFhrpGroupsBulkPartialUpdateOK ipam fhrp groups bulk partial update o k +*/ +type IpamFhrpGroupsBulkPartialUpdateOK struct { + Payload *models.FHRPGroup +} + +func (o *IpamFhrpGroupsBulkPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /ipam/fhrp-groups/][%d] ipamFhrpGroupsBulkPartialUpdateOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupsBulkPartialUpdateOK) GetPayload() *models.FHRPGroup { + return o.Payload +} + +func (o *IpamFhrpGroupsBulkPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_bulk_update_parameters.go b/netbox/client/ipam/ipam_fhrp_groups_bulk_update_parameters.go new file mode 100644 index 00000000..aef6d643 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_bulk_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamFhrpGroupsBulkUpdateParams creates a new IpamFhrpGroupsBulkUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupsBulkUpdateParams() *IpamFhrpGroupsBulkUpdateParams { + return &IpamFhrpGroupsBulkUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupsBulkUpdateParamsWithTimeout creates a new IpamFhrpGroupsBulkUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupsBulkUpdateParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupsBulkUpdateParams { + return &IpamFhrpGroupsBulkUpdateParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupsBulkUpdateParamsWithContext creates a new IpamFhrpGroupsBulkUpdateParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupsBulkUpdateParamsWithContext(ctx context.Context) *IpamFhrpGroupsBulkUpdateParams { + return &IpamFhrpGroupsBulkUpdateParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupsBulkUpdateParamsWithHTTPClient creates a new IpamFhrpGroupsBulkUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupsBulkUpdateParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupsBulkUpdateParams { + return &IpamFhrpGroupsBulkUpdateParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupsBulkUpdateParams contains all the parameters to send to the API endpoint + for the ipam fhrp groups bulk update operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupsBulkUpdateParams struct { + + // Data. + Data *models.FHRPGroup + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp groups bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsBulkUpdateParams) WithDefaults() *IpamFhrpGroupsBulkUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp groups bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsBulkUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp groups bulk update params +func (o *IpamFhrpGroupsBulkUpdateParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupsBulkUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp groups bulk update params +func (o *IpamFhrpGroupsBulkUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp groups bulk update params +func (o *IpamFhrpGroupsBulkUpdateParams) WithContext(ctx context.Context) *IpamFhrpGroupsBulkUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp groups bulk update params +func (o *IpamFhrpGroupsBulkUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp groups bulk update params +func (o *IpamFhrpGroupsBulkUpdateParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupsBulkUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp groups bulk update params +func (o *IpamFhrpGroupsBulkUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam fhrp groups bulk update params +func (o *IpamFhrpGroupsBulkUpdateParams) WithData(data *models.FHRPGroup) *IpamFhrpGroupsBulkUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam fhrp groups bulk update params +func (o *IpamFhrpGroupsBulkUpdateParams) SetData(data *models.FHRPGroup) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupsBulkUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_bulk_update_responses.go b/netbox/client/ipam/ipam_fhrp_groups_bulk_update_responses.go new file mode 100644 index 00000000..6bb4e9ae --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_bulk_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupsBulkUpdateReader is a Reader for the IpamFhrpGroupsBulkUpdate structure. +type IpamFhrpGroupsBulkUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupsBulkUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupsBulkUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupsBulkUpdateOK creates a IpamFhrpGroupsBulkUpdateOK with default headers values +func NewIpamFhrpGroupsBulkUpdateOK() *IpamFhrpGroupsBulkUpdateOK { + return &IpamFhrpGroupsBulkUpdateOK{} +} + +/* IpamFhrpGroupsBulkUpdateOK describes a response with status code 200, with default header values. + +IpamFhrpGroupsBulkUpdateOK ipam fhrp groups bulk update o k +*/ +type IpamFhrpGroupsBulkUpdateOK struct { + Payload *models.FHRPGroup +} + +func (o *IpamFhrpGroupsBulkUpdateOK) Error() string { + return fmt.Sprintf("[PUT /ipam/fhrp-groups/][%d] ipamFhrpGroupsBulkUpdateOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupsBulkUpdateOK) GetPayload() *models.FHRPGroup { + return o.Payload +} + +func (o *IpamFhrpGroupsBulkUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_create_parameters.go b/netbox/client/ipam/ipam_fhrp_groups_create_parameters.go new file mode 100644 index 00000000..a58be8f9 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_create_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamFhrpGroupsCreateParams creates a new IpamFhrpGroupsCreateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupsCreateParams() *IpamFhrpGroupsCreateParams { + return &IpamFhrpGroupsCreateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupsCreateParamsWithTimeout creates a new IpamFhrpGroupsCreateParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupsCreateParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupsCreateParams { + return &IpamFhrpGroupsCreateParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupsCreateParamsWithContext creates a new IpamFhrpGroupsCreateParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupsCreateParamsWithContext(ctx context.Context) *IpamFhrpGroupsCreateParams { + return &IpamFhrpGroupsCreateParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupsCreateParamsWithHTTPClient creates a new IpamFhrpGroupsCreateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupsCreateParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupsCreateParams { + return &IpamFhrpGroupsCreateParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupsCreateParams contains all the parameters to send to the API endpoint + for the ipam fhrp groups create operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupsCreateParams struct { + + // Data. + Data *models.FHRPGroup + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp groups create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsCreateParams) WithDefaults() *IpamFhrpGroupsCreateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp groups create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsCreateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp groups create params +func (o *IpamFhrpGroupsCreateParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupsCreateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp groups create params +func (o *IpamFhrpGroupsCreateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp groups create params +func (o *IpamFhrpGroupsCreateParams) WithContext(ctx context.Context) *IpamFhrpGroupsCreateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp groups create params +func (o *IpamFhrpGroupsCreateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp groups create params +func (o *IpamFhrpGroupsCreateParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupsCreateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp groups create params +func (o *IpamFhrpGroupsCreateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam fhrp groups create params +func (o *IpamFhrpGroupsCreateParams) WithData(data *models.FHRPGroup) *IpamFhrpGroupsCreateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam fhrp groups create params +func (o *IpamFhrpGroupsCreateParams) SetData(data *models.FHRPGroup) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupsCreateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_create_responses.go b/netbox/client/ipam/ipam_fhrp_groups_create_responses.go new file mode 100644 index 00000000..31bd5eac --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_create_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupsCreateReader is a Reader for the IpamFhrpGroupsCreate structure. +type IpamFhrpGroupsCreateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupsCreateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 201: + result := NewIpamFhrpGroupsCreateCreated() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupsCreateCreated creates a IpamFhrpGroupsCreateCreated with default headers values +func NewIpamFhrpGroupsCreateCreated() *IpamFhrpGroupsCreateCreated { + return &IpamFhrpGroupsCreateCreated{} +} + +/* IpamFhrpGroupsCreateCreated describes a response with status code 201, with default header values. + +IpamFhrpGroupsCreateCreated ipam fhrp groups create created +*/ +type IpamFhrpGroupsCreateCreated struct { + Payload *models.FHRPGroup +} + +func (o *IpamFhrpGroupsCreateCreated) Error() string { + return fmt.Sprintf("[POST /ipam/fhrp-groups/][%d] ipamFhrpGroupsCreateCreated %+v", 201, o.Payload) +} +func (o *IpamFhrpGroupsCreateCreated) GetPayload() *models.FHRPGroup { + return o.Payload +} + +func (o *IpamFhrpGroupsCreateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_delete_parameters.go b/netbox/client/ipam/ipam_fhrp_groups_delete_parameters.go new file mode 100644 index 00000000..fbb7001b --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_delete_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewIpamFhrpGroupsDeleteParams creates a new IpamFhrpGroupsDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupsDeleteParams() *IpamFhrpGroupsDeleteParams { + return &IpamFhrpGroupsDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupsDeleteParamsWithTimeout creates a new IpamFhrpGroupsDeleteParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupsDeleteParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupsDeleteParams { + return &IpamFhrpGroupsDeleteParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupsDeleteParamsWithContext creates a new IpamFhrpGroupsDeleteParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupsDeleteParamsWithContext(ctx context.Context) *IpamFhrpGroupsDeleteParams { + return &IpamFhrpGroupsDeleteParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupsDeleteParamsWithHTTPClient creates a new IpamFhrpGroupsDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupsDeleteParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupsDeleteParams { + return &IpamFhrpGroupsDeleteParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupsDeleteParams contains all the parameters to send to the API endpoint + for the ipam fhrp groups delete operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupsDeleteParams struct { + + /* ID. + + A unique integer value identifying this FHRP group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp groups delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsDeleteParams) WithDefaults() *IpamFhrpGroupsDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp groups delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp groups delete params +func (o *IpamFhrpGroupsDeleteParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupsDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp groups delete params +func (o *IpamFhrpGroupsDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp groups delete params +func (o *IpamFhrpGroupsDeleteParams) WithContext(ctx context.Context) *IpamFhrpGroupsDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp groups delete params +func (o *IpamFhrpGroupsDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp groups delete params +func (o *IpamFhrpGroupsDeleteParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupsDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp groups delete params +func (o *IpamFhrpGroupsDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the ipam fhrp groups delete params +func (o *IpamFhrpGroupsDeleteParams) WithID(id int64) *IpamFhrpGroupsDeleteParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam fhrp groups delete params +func (o *IpamFhrpGroupsDeleteParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupsDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_delete_responses.go b/netbox/client/ipam/ipam_fhrp_groups_delete_responses.go new file mode 100644 index 00000000..0d21609e --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// IpamFhrpGroupsDeleteReader is a Reader for the IpamFhrpGroupsDelete structure. +type IpamFhrpGroupsDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupsDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewIpamFhrpGroupsDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupsDeleteNoContent creates a IpamFhrpGroupsDeleteNoContent with default headers values +func NewIpamFhrpGroupsDeleteNoContent() *IpamFhrpGroupsDeleteNoContent { + return &IpamFhrpGroupsDeleteNoContent{} +} + +/* IpamFhrpGroupsDeleteNoContent describes a response with status code 204, with default header values. + +IpamFhrpGroupsDeleteNoContent ipam fhrp groups delete no content +*/ +type IpamFhrpGroupsDeleteNoContent struct { +} + +func (o *IpamFhrpGroupsDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /ipam/fhrp-groups/{id}/][%d] ipamFhrpGroupsDeleteNoContent ", 204) +} + +func (o *IpamFhrpGroupsDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_list_parameters.go b/netbox/client/ipam/ipam_fhrp_groups_list_parameters.go new file mode 100644 index 00000000..52b00ce1 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_list_parameters.go @@ -0,0 +1,1358 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewIpamFhrpGroupsListParams creates a new IpamFhrpGroupsListParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupsListParams() *IpamFhrpGroupsListParams { + return &IpamFhrpGroupsListParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupsListParamsWithTimeout creates a new IpamFhrpGroupsListParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupsListParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupsListParams { + return &IpamFhrpGroupsListParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupsListParamsWithContext creates a new IpamFhrpGroupsListParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupsListParamsWithContext(ctx context.Context) *IpamFhrpGroupsListParams { + return &IpamFhrpGroupsListParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupsListParamsWithHTTPClient creates a new IpamFhrpGroupsListParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupsListParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupsListParams { + return &IpamFhrpGroupsListParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupsListParams contains all the parameters to send to the API endpoint + for the ipam fhrp groups list operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupsListParams struct { + + // AuthKey. + AuthKey *string + + // AuthKeyEmpty. + AuthKeyEmpty *string + + // AuthKeyIc. + AuthKeyIc *string + + // AuthKeyIe. + AuthKeyIe *string + + // AuthKeyIew. + AuthKeyIew *string + + // AuthKeyIsw. + AuthKeyIsw *string + + // AuthKeyn. + AuthKeyn *string + + // AuthKeyNic. + AuthKeyNic *string + + // AuthKeyNie. + AuthKeyNie *string + + // AuthKeyNiew. + AuthKeyNiew *string + + // AuthKeyNisw. + AuthKeyNisw *string + + // AuthType. + AuthType *string + + // AuthTypen. + AuthTypen *string + + // Created. + Created *string + + // CreatedGte. + CreatedGte *string + + // CreatedLte. + CreatedLte *string + + // GroupID. + GroupID *string + + // GroupIDGt. + GroupIDGt *string + + // GroupIDGte. + GroupIDGte *string + + // GroupIDLt. + GroupIDLt *string + + // GroupIDLte. + GroupIDLte *string + + // GroupIDn. + GroupIDn *string + + // ID. + ID *string + + // IDGt. + IDGt *string + + // IDGte. + IDGte *string + + // IDLt. + IDLt *string + + // IDLte. + IDLte *string + + // IDn. + IDn *string + + // LastUpdated. + LastUpdated *string + + // LastUpdatedGte. + LastUpdatedGte *string + + // LastUpdatedLte. + LastUpdatedLte *string + + /* Limit. + + Number of results to return per page. + */ + Limit *int64 + + /* Offset. + + The initial index from which to return the results. + */ + Offset *int64 + + // Protocol. + Protocol *string + + // Protocoln. + Protocoln *string + + // Q. + Q *string + + // RelatedIP. + RelatedIP *string + + // Tag. + Tag *string + + // Tagn. + Tagn *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp groups list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsListParams) WithDefaults() *IpamFhrpGroupsListParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp groups list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsListParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupsListParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithContext(ctx context.Context) *IpamFhrpGroupsListParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupsListParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAuthKey adds the authKey to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthKey(authKey *string) *IpamFhrpGroupsListParams { + o.SetAuthKey(authKey) + return o +} + +// SetAuthKey adds the authKey to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthKey(authKey *string) { + o.AuthKey = authKey +} + +// WithAuthKeyEmpty adds the authKeyEmpty to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthKeyEmpty(authKeyEmpty *string) *IpamFhrpGroupsListParams { + o.SetAuthKeyEmpty(authKeyEmpty) + return o +} + +// SetAuthKeyEmpty adds the authKeyEmpty to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthKeyEmpty(authKeyEmpty *string) { + o.AuthKeyEmpty = authKeyEmpty +} + +// WithAuthKeyIc adds the authKeyIc to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthKeyIc(authKeyIc *string) *IpamFhrpGroupsListParams { + o.SetAuthKeyIc(authKeyIc) + return o +} + +// SetAuthKeyIc adds the authKeyIc to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthKeyIc(authKeyIc *string) { + o.AuthKeyIc = authKeyIc +} + +// WithAuthKeyIe adds the authKeyIe to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthKeyIe(authKeyIe *string) *IpamFhrpGroupsListParams { + o.SetAuthKeyIe(authKeyIe) + return o +} + +// SetAuthKeyIe adds the authKeyIe to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthKeyIe(authKeyIe *string) { + o.AuthKeyIe = authKeyIe +} + +// WithAuthKeyIew adds the authKeyIew to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthKeyIew(authKeyIew *string) *IpamFhrpGroupsListParams { + o.SetAuthKeyIew(authKeyIew) + return o +} + +// SetAuthKeyIew adds the authKeyIew to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthKeyIew(authKeyIew *string) { + o.AuthKeyIew = authKeyIew +} + +// WithAuthKeyIsw adds the authKeyIsw to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthKeyIsw(authKeyIsw *string) *IpamFhrpGroupsListParams { + o.SetAuthKeyIsw(authKeyIsw) + return o +} + +// SetAuthKeyIsw adds the authKeyIsw to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthKeyIsw(authKeyIsw *string) { + o.AuthKeyIsw = authKeyIsw +} + +// WithAuthKeyn adds the authKeyn to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthKeyn(authKeyn *string) *IpamFhrpGroupsListParams { + o.SetAuthKeyn(authKeyn) + return o +} + +// SetAuthKeyn adds the authKeyN to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthKeyn(authKeyn *string) { + o.AuthKeyn = authKeyn +} + +// WithAuthKeyNic adds the authKeyNic to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthKeyNic(authKeyNic *string) *IpamFhrpGroupsListParams { + o.SetAuthKeyNic(authKeyNic) + return o +} + +// SetAuthKeyNic adds the authKeyNic to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthKeyNic(authKeyNic *string) { + o.AuthKeyNic = authKeyNic +} + +// WithAuthKeyNie adds the authKeyNie to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthKeyNie(authKeyNie *string) *IpamFhrpGroupsListParams { + o.SetAuthKeyNie(authKeyNie) + return o +} + +// SetAuthKeyNie adds the authKeyNie to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthKeyNie(authKeyNie *string) { + o.AuthKeyNie = authKeyNie +} + +// WithAuthKeyNiew adds the authKeyNiew to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthKeyNiew(authKeyNiew *string) *IpamFhrpGroupsListParams { + o.SetAuthKeyNiew(authKeyNiew) + return o +} + +// SetAuthKeyNiew adds the authKeyNiew to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthKeyNiew(authKeyNiew *string) { + o.AuthKeyNiew = authKeyNiew +} + +// WithAuthKeyNisw adds the authKeyNisw to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthKeyNisw(authKeyNisw *string) *IpamFhrpGroupsListParams { + o.SetAuthKeyNisw(authKeyNisw) + return o +} + +// SetAuthKeyNisw adds the authKeyNisw to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthKeyNisw(authKeyNisw *string) { + o.AuthKeyNisw = authKeyNisw +} + +// WithAuthType adds the authType to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthType(authType *string) *IpamFhrpGroupsListParams { + o.SetAuthType(authType) + return o +} + +// SetAuthType adds the authType to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthType(authType *string) { + o.AuthType = authType +} + +// WithAuthTypen adds the authTypen to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithAuthTypen(authTypen *string) *IpamFhrpGroupsListParams { + o.SetAuthTypen(authTypen) + return o +} + +// SetAuthTypen adds the authTypeN to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetAuthTypen(authTypen *string) { + o.AuthTypen = authTypen +} + +// WithCreated adds the created to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithCreated(created *string) *IpamFhrpGroupsListParams { + o.SetCreated(created) + return o +} + +// SetCreated adds the created to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetCreated(created *string) { + o.Created = created +} + +// WithCreatedGte adds the createdGte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithCreatedGte(createdGte *string) *IpamFhrpGroupsListParams { + o.SetCreatedGte(createdGte) + return o +} + +// SetCreatedGte adds the createdGte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetCreatedGte(createdGte *string) { + o.CreatedGte = createdGte +} + +// WithCreatedLte adds the createdLte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithCreatedLte(createdLte *string) *IpamFhrpGroupsListParams { + o.SetCreatedLte(createdLte) + return o +} + +// SetCreatedLte adds the createdLte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetCreatedLte(createdLte *string) { + o.CreatedLte = createdLte +} + +// WithGroupID adds the groupID to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithGroupID(groupID *string) *IpamFhrpGroupsListParams { + o.SetGroupID(groupID) + return o +} + +// SetGroupID adds the groupId to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetGroupID(groupID *string) { + o.GroupID = groupID +} + +// WithGroupIDGt adds the groupIDGt to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithGroupIDGt(groupIDGt *string) *IpamFhrpGroupsListParams { + o.SetGroupIDGt(groupIDGt) + return o +} + +// SetGroupIDGt adds the groupIdGt to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetGroupIDGt(groupIDGt *string) { + o.GroupIDGt = groupIDGt +} + +// WithGroupIDGte adds the groupIDGte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithGroupIDGte(groupIDGte *string) *IpamFhrpGroupsListParams { + o.SetGroupIDGte(groupIDGte) + return o +} + +// SetGroupIDGte adds the groupIdGte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetGroupIDGte(groupIDGte *string) { + o.GroupIDGte = groupIDGte +} + +// WithGroupIDLt adds the groupIDLt to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithGroupIDLt(groupIDLt *string) *IpamFhrpGroupsListParams { + o.SetGroupIDLt(groupIDLt) + return o +} + +// SetGroupIDLt adds the groupIdLt to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetGroupIDLt(groupIDLt *string) { + o.GroupIDLt = groupIDLt +} + +// WithGroupIDLte adds the groupIDLte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithGroupIDLte(groupIDLte *string) *IpamFhrpGroupsListParams { + o.SetGroupIDLte(groupIDLte) + return o +} + +// SetGroupIDLte adds the groupIdLte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetGroupIDLte(groupIDLte *string) { + o.GroupIDLte = groupIDLte +} + +// WithGroupIDn adds the groupIDn to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithGroupIDn(groupIDn *string) *IpamFhrpGroupsListParams { + o.SetGroupIDn(groupIDn) + return o +} + +// SetGroupIDn adds the groupIdN to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetGroupIDn(groupIDn *string) { + o.GroupIDn = groupIDn +} + +// WithID adds the id to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithID(id *string) *IpamFhrpGroupsListParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetID(id *string) { + o.ID = id +} + +// WithIDGt adds the iDGt to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithIDGt(iDGt *string) *IpamFhrpGroupsListParams { + o.SetIDGt(iDGt) + return o +} + +// SetIDGt adds the idGt to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetIDGt(iDGt *string) { + o.IDGt = iDGt +} + +// WithIDGte adds the iDGte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithIDGte(iDGte *string) *IpamFhrpGroupsListParams { + o.SetIDGte(iDGte) + return o +} + +// SetIDGte adds the idGte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetIDGte(iDGte *string) { + o.IDGte = iDGte +} + +// WithIDLt adds the iDLt to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithIDLt(iDLt *string) *IpamFhrpGroupsListParams { + o.SetIDLt(iDLt) + return o +} + +// SetIDLt adds the idLt to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetIDLt(iDLt *string) { + o.IDLt = iDLt +} + +// WithIDLte adds the iDLte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithIDLte(iDLte *string) *IpamFhrpGroupsListParams { + o.SetIDLte(iDLte) + return o +} + +// SetIDLte adds the idLte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetIDLte(iDLte *string) { + o.IDLte = iDLte +} + +// WithIDn adds the iDn to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithIDn(iDn *string) *IpamFhrpGroupsListParams { + o.SetIDn(iDn) + return o +} + +// SetIDn adds the idN to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetIDn(iDn *string) { + o.IDn = iDn +} + +// WithLastUpdated adds the lastUpdated to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithLastUpdated(lastUpdated *string) *IpamFhrpGroupsListParams { + o.SetLastUpdated(lastUpdated) + return o +} + +// SetLastUpdated adds the lastUpdated to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetLastUpdated(lastUpdated *string) { + o.LastUpdated = lastUpdated +} + +// WithLastUpdatedGte adds the lastUpdatedGte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithLastUpdatedGte(lastUpdatedGte *string) *IpamFhrpGroupsListParams { + o.SetLastUpdatedGte(lastUpdatedGte) + return o +} + +// SetLastUpdatedGte adds the lastUpdatedGte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetLastUpdatedGte(lastUpdatedGte *string) { + o.LastUpdatedGte = lastUpdatedGte +} + +// WithLastUpdatedLte adds the lastUpdatedLte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithLastUpdatedLte(lastUpdatedLte *string) *IpamFhrpGroupsListParams { + o.SetLastUpdatedLte(lastUpdatedLte) + return o +} + +// SetLastUpdatedLte adds the lastUpdatedLte to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetLastUpdatedLte(lastUpdatedLte *string) { + o.LastUpdatedLte = lastUpdatedLte +} + +// WithLimit adds the limit to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithLimit(limit *int64) *IpamFhrpGroupsListParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithOffset(offset *int64) *IpamFhrpGroupsListParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithProtocol adds the protocol to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithProtocol(protocol *string) *IpamFhrpGroupsListParams { + o.SetProtocol(protocol) + return o +} + +// SetProtocol adds the protocol to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetProtocol(protocol *string) { + o.Protocol = protocol +} + +// WithProtocoln adds the protocoln to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithProtocoln(protocoln *string) *IpamFhrpGroupsListParams { + o.SetProtocoln(protocoln) + return o +} + +// SetProtocoln adds the protocolN to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetProtocoln(protocoln *string) { + o.Protocoln = protocoln +} + +// WithQ adds the q to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithQ(q *string) *IpamFhrpGroupsListParams { + o.SetQ(q) + return o +} + +// SetQ adds the q to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetQ(q *string) { + o.Q = q +} + +// WithRelatedIP adds the relatedIP to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithRelatedIP(relatedIP *string) *IpamFhrpGroupsListParams { + o.SetRelatedIP(relatedIP) + return o +} + +// SetRelatedIP adds the relatedIp to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetRelatedIP(relatedIP *string) { + o.RelatedIP = relatedIP +} + +// WithTag adds the tag to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithTag(tag *string) *IpamFhrpGroupsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) WithTagn(tagn *string) *IpamFhrpGroupsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the ipam fhrp groups list params +func (o *IpamFhrpGroupsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.AuthKey != nil { + + // query param auth_key + var qrAuthKey string + + if o.AuthKey != nil { + qrAuthKey = *o.AuthKey + } + qAuthKey := qrAuthKey + if qAuthKey != "" { + + if err := r.SetQueryParam("auth_key", qAuthKey); err != nil { + return err + } + } + } + + if o.AuthKeyEmpty != nil { + + // query param auth_key__empty + var qrAuthKeyEmpty string + + if o.AuthKeyEmpty != nil { + qrAuthKeyEmpty = *o.AuthKeyEmpty + } + qAuthKeyEmpty := qrAuthKeyEmpty + if qAuthKeyEmpty != "" { + + if err := r.SetQueryParam("auth_key__empty", qAuthKeyEmpty); err != nil { + return err + } + } + } + + if o.AuthKeyIc != nil { + + // query param auth_key__ic + var qrAuthKeyIc string + + if o.AuthKeyIc != nil { + qrAuthKeyIc = *o.AuthKeyIc + } + qAuthKeyIc := qrAuthKeyIc + if qAuthKeyIc != "" { + + if err := r.SetQueryParam("auth_key__ic", qAuthKeyIc); err != nil { + return err + } + } + } + + if o.AuthKeyIe != nil { + + // query param auth_key__ie + var qrAuthKeyIe string + + if o.AuthKeyIe != nil { + qrAuthKeyIe = *o.AuthKeyIe + } + qAuthKeyIe := qrAuthKeyIe + if qAuthKeyIe != "" { + + if err := r.SetQueryParam("auth_key__ie", qAuthKeyIe); err != nil { + return err + } + } + } + + if o.AuthKeyIew != nil { + + // query param auth_key__iew + var qrAuthKeyIew string + + if o.AuthKeyIew != nil { + qrAuthKeyIew = *o.AuthKeyIew + } + qAuthKeyIew := qrAuthKeyIew + if qAuthKeyIew != "" { + + if err := r.SetQueryParam("auth_key__iew", qAuthKeyIew); err != nil { + return err + } + } + } + + if o.AuthKeyIsw != nil { + + // query param auth_key__isw + var qrAuthKeyIsw string + + if o.AuthKeyIsw != nil { + qrAuthKeyIsw = *o.AuthKeyIsw + } + qAuthKeyIsw := qrAuthKeyIsw + if qAuthKeyIsw != "" { + + if err := r.SetQueryParam("auth_key__isw", qAuthKeyIsw); err != nil { + return err + } + } + } + + if o.AuthKeyn != nil { + + // query param auth_key__n + var qrAuthKeyn string + + if o.AuthKeyn != nil { + qrAuthKeyn = *o.AuthKeyn + } + qAuthKeyn := qrAuthKeyn + if qAuthKeyn != "" { + + if err := r.SetQueryParam("auth_key__n", qAuthKeyn); err != nil { + return err + } + } + } + + if o.AuthKeyNic != nil { + + // query param auth_key__nic + var qrAuthKeyNic string + + if o.AuthKeyNic != nil { + qrAuthKeyNic = *o.AuthKeyNic + } + qAuthKeyNic := qrAuthKeyNic + if qAuthKeyNic != "" { + + if err := r.SetQueryParam("auth_key__nic", qAuthKeyNic); err != nil { + return err + } + } + } + + if o.AuthKeyNie != nil { + + // query param auth_key__nie + var qrAuthKeyNie string + + if o.AuthKeyNie != nil { + qrAuthKeyNie = *o.AuthKeyNie + } + qAuthKeyNie := qrAuthKeyNie + if qAuthKeyNie != "" { + + if err := r.SetQueryParam("auth_key__nie", qAuthKeyNie); err != nil { + return err + } + } + } + + if o.AuthKeyNiew != nil { + + // query param auth_key__niew + var qrAuthKeyNiew string + + if o.AuthKeyNiew != nil { + qrAuthKeyNiew = *o.AuthKeyNiew + } + qAuthKeyNiew := qrAuthKeyNiew + if qAuthKeyNiew != "" { + + if err := r.SetQueryParam("auth_key__niew", qAuthKeyNiew); err != nil { + return err + } + } + } + + if o.AuthKeyNisw != nil { + + // query param auth_key__nisw + var qrAuthKeyNisw string + + if o.AuthKeyNisw != nil { + qrAuthKeyNisw = *o.AuthKeyNisw + } + qAuthKeyNisw := qrAuthKeyNisw + if qAuthKeyNisw != "" { + + if err := r.SetQueryParam("auth_key__nisw", qAuthKeyNisw); err != nil { + return err + } + } + } + + if o.AuthType != nil { + + // query param auth_type + var qrAuthType string + + if o.AuthType != nil { + qrAuthType = *o.AuthType + } + qAuthType := qrAuthType + if qAuthType != "" { + + if err := r.SetQueryParam("auth_type", qAuthType); err != nil { + return err + } + } + } + + if o.AuthTypen != nil { + + // query param auth_type__n + var qrAuthTypen string + + if o.AuthTypen != nil { + qrAuthTypen = *o.AuthTypen + } + qAuthTypen := qrAuthTypen + if qAuthTypen != "" { + + if err := r.SetQueryParam("auth_type__n", qAuthTypen); err != nil { + return err + } + } + } + + if o.Created != nil { + + // query param created + var qrCreated string + + if o.Created != nil { + qrCreated = *o.Created + } + qCreated := qrCreated + if qCreated != "" { + + if err := r.SetQueryParam("created", qCreated); err != nil { + return err + } + } + } + + if o.CreatedGte != nil { + + // query param created__gte + var qrCreatedGte string + + if o.CreatedGte != nil { + qrCreatedGte = *o.CreatedGte + } + qCreatedGte := qrCreatedGte + if qCreatedGte != "" { + + if err := r.SetQueryParam("created__gte", qCreatedGte); err != nil { + return err + } + } + } + + if o.CreatedLte != nil { + + // query param created__lte + var qrCreatedLte string + + if o.CreatedLte != nil { + qrCreatedLte = *o.CreatedLte + } + qCreatedLte := qrCreatedLte + if qCreatedLte != "" { + + if err := r.SetQueryParam("created__lte", qCreatedLte); err != nil { + return err + } + } + } + + if o.GroupID != nil { + + // query param group_id + var qrGroupID string + + if o.GroupID != nil { + qrGroupID = *o.GroupID + } + qGroupID := qrGroupID + if qGroupID != "" { + + if err := r.SetQueryParam("group_id", qGroupID); err != nil { + return err + } + } + } + + if o.GroupIDGt != nil { + + // query param group_id__gt + var qrGroupIDGt string + + if o.GroupIDGt != nil { + qrGroupIDGt = *o.GroupIDGt + } + qGroupIDGt := qrGroupIDGt + if qGroupIDGt != "" { + + if err := r.SetQueryParam("group_id__gt", qGroupIDGt); err != nil { + return err + } + } + } + + if o.GroupIDGte != nil { + + // query param group_id__gte + var qrGroupIDGte string + + if o.GroupIDGte != nil { + qrGroupIDGte = *o.GroupIDGte + } + qGroupIDGte := qrGroupIDGte + if qGroupIDGte != "" { + + if err := r.SetQueryParam("group_id__gte", qGroupIDGte); err != nil { + return err + } + } + } + + if o.GroupIDLt != nil { + + // query param group_id__lt + var qrGroupIDLt string + + if o.GroupIDLt != nil { + qrGroupIDLt = *o.GroupIDLt + } + qGroupIDLt := qrGroupIDLt + if qGroupIDLt != "" { + + if err := r.SetQueryParam("group_id__lt", qGroupIDLt); err != nil { + return err + } + } + } + + if o.GroupIDLte != nil { + + // query param group_id__lte + var qrGroupIDLte string + + if o.GroupIDLte != nil { + qrGroupIDLte = *o.GroupIDLte + } + qGroupIDLte := qrGroupIDLte + if qGroupIDLte != "" { + + if err := r.SetQueryParam("group_id__lte", qGroupIDLte); err != nil { + return err + } + } + } + + if o.GroupIDn != nil { + + // query param group_id__n + var qrGroupIDn string + + if o.GroupIDn != nil { + qrGroupIDn = *o.GroupIDn + } + qGroupIDn := qrGroupIDn + if qGroupIDn != "" { + + if err := r.SetQueryParam("group_id__n", qGroupIDn); err != nil { + return err + } + } + } + + if o.ID != nil { + + // query param id + var qrID string + + if o.ID != nil { + qrID = *o.ID + } + qID := qrID + if qID != "" { + + if err := r.SetQueryParam("id", qID); err != nil { + return err + } + } + } + + if o.IDGt != nil { + + // query param id__gt + var qrIDGt string + + if o.IDGt != nil { + qrIDGt = *o.IDGt + } + qIDGt := qrIDGt + if qIDGt != "" { + + if err := r.SetQueryParam("id__gt", qIDGt); err != nil { + return err + } + } + } + + if o.IDGte != nil { + + // query param id__gte + var qrIDGte string + + if o.IDGte != nil { + qrIDGte = *o.IDGte + } + qIDGte := qrIDGte + if qIDGte != "" { + + if err := r.SetQueryParam("id__gte", qIDGte); err != nil { + return err + } + } + } + + if o.IDLt != nil { + + // query param id__lt + var qrIDLt string + + if o.IDLt != nil { + qrIDLt = *o.IDLt + } + qIDLt := qrIDLt + if qIDLt != "" { + + if err := r.SetQueryParam("id__lt", qIDLt); err != nil { + return err + } + } + } + + if o.IDLte != nil { + + // query param id__lte + var qrIDLte string + + if o.IDLte != nil { + qrIDLte = *o.IDLte + } + qIDLte := qrIDLte + if qIDLte != "" { + + if err := r.SetQueryParam("id__lte", qIDLte); err != nil { + return err + } + } + } + + if o.IDn != nil { + + // query param id__n + var qrIDn string + + if o.IDn != nil { + qrIDn = *o.IDn + } + qIDn := qrIDn + if qIDn != "" { + + if err := r.SetQueryParam("id__n", qIDn); err != nil { + return err + } + } + } + + if o.LastUpdated != nil { + + // query param last_updated + var qrLastUpdated string + + if o.LastUpdated != nil { + qrLastUpdated = *o.LastUpdated + } + qLastUpdated := qrLastUpdated + if qLastUpdated != "" { + + if err := r.SetQueryParam("last_updated", qLastUpdated); err != nil { + return err + } + } + } + + if o.LastUpdatedGte != nil { + + // query param last_updated__gte + var qrLastUpdatedGte string + + if o.LastUpdatedGte != nil { + qrLastUpdatedGte = *o.LastUpdatedGte + } + qLastUpdatedGte := qrLastUpdatedGte + if qLastUpdatedGte != "" { + + if err := r.SetQueryParam("last_updated__gte", qLastUpdatedGte); err != nil { + return err + } + } + } + + if o.LastUpdatedLte != nil { + + // query param last_updated__lte + var qrLastUpdatedLte string + + if o.LastUpdatedLte != nil { + qrLastUpdatedLte = *o.LastUpdatedLte + } + qLastUpdatedLte := qrLastUpdatedLte + if qLastUpdatedLte != "" { + + if err := r.SetQueryParam("last_updated__lte", qLastUpdatedLte); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.Protocol != nil { + + // query param protocol + var qrProtocol string + + if o.Protocol != nil { + qrProtocol = *o.Protocol + } + qProtocol := qrProtocol + if qProtocol != "" { + + if err := r.SetQueryParam("protocol", qProtocol); err != nil { + return err + } + } + } + + if o.Protocoln != nil { + + // query param protocol__n + var qrProtocoln string + + if o.Protocoln != nil { + qrProtocoln = *o.Protocoln + } + qProtocoln := qrProtocoln + if qProtocoln != "" { + + if err := r.SetQueryParam("protocol__n", qProtocoln); err != nil { + return err + } + } + } + + if o.Q != nil { + + // query param q + var qrQ string + + if o.Q != nil { + qrQ = *o.Q + } + qQ := qrQ + if qQ != "" { + + if err := r.SetQueryParam("q", qQ); err != nil { + return err + } + } + } + + if o.RelatedIP != nil { + + // query param related_ip + var qrRelatedIP string + + if o.RelatedIP != nil { + qrRelatedIP = *o.RelatedIP + } + qRelatedIP := qrRelatedIP + if qRelatedIP != "" { + + if err := r.SetQueryParam("related_ip", qRelatedIP); err != nil { + return err + } + } + } + + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_list_responses.go b/netbox/client/ipam/ipam_fhrp_groups_list_responses.go new file mode 100644 index 00000000..8761a596 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_list_responses.go @@ -0,0 +1,247 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupsListReader is a Reader for the IpamFhrpGroupsList structure. +type IpamFhrpGroupsListReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupsListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupsListOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupsListOK creates a IpamFhrpGroupsListOK with default headers values +func NewIpamFhrpGroupsListOK() *IpamFhrpGroupsListOK { + return &IpamFhrpGroupsListOK{} +} + +/* IpamFhrpGroupsListOK describes a response with status code 200, with default header values. + +IpamFhrpGroupsListOK ipam fhrp groups list o k +*/ +type IpamFhrpGroupsListOK struct { + Payload *IpamFhrpGroupsListOKBody +} + +func (o *IpamFhrpGroupsListOK) Error() string { + return fmt.Sprintf("[GET /ipam/fhrp-groups/][%d] ipamFhrpGroupsListOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupsListOK) GetPayload() *IpamFhrpGroupsListOKBody { + return o.Payload +} + +func (o *IpamFhrpGroupsListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(IpamFhrpGroupsListOKBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*IpamFhrpGroupsListOKBody ipam fhrp groups list o k body +swagger:model IpamFhrpGroupsListOKBody +*/ +type IpamFhrpGroupsListOKBody struct { + + // count + // Required: true + Count *int64 `json:"count"` + + // next + // Format: uri + Next *strfmt.URI `json:"next,omitempty"` + + // previous + // Format: uri + Previous *strfmt.URI `json:"previous,omitempty"` + + // results + // Required: true + Results []*models.FHRPGroup `json:"results"` +} + +// Validate validates this ipam fhrp groups list o k body +func (o *IpamFhrpGroupsListOKBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateCount(formats); err != nil { + res = append(res, err) + } + + if err := o.validateNext(formats); err != nil { + res = append(res, err) + } + + if err := o.validatePrevious(formats); err != nil { + res = append(res, err) + } + + if err := o.validateResults(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *IpamFhrpGroupsListOKBody) validateCount(formats strfmt.Registry) error { + + if err := validate.Required("ipamFhrpGroupsListOK"+"."+"count", "body", o.Count); err != nil { + return err + } + + return nil +} + +func (o *IpamFhrpGroupsListOKBody) validateNext(formats strfmt.Registry) error { + if swag.IsZero(o.Next) { // not required + return nil + } + + if err := validate.FormatOf("ipamFhrpGroupsListOK"+"."+"next", "body", "uri", o.Next.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *IpamFhrpGroupsListOKBody) validatePrevious(formats strfmt.Registry) error { + if swag.IsZero(o.Previous) { // not required + return nil + } + + if err := validate.FormatOf("ipamFhrpGroupsListOK"+"."+"previous", "body", "uri", o.Previous.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *IpamFhrpGroupsListOKBody) validateResults(formats strfmt.Registry) error { + + if err := validate.Required("ipamFhrpGroupsListOK"+"."+"results", "body", o.Results); err != nil { + return err + } + + for i := 0; i < len(o.Results); i++ { + if swag.IsZero(o.Results[i]) { // not required + continue + } + + if o.Results[i] != nil { + if err := o.Results[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("ipamFhrpGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("ipamFhrpGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this ipam fhrp groups list o k body based on the context it is used +func (o *IpamFhrpGroupsListOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := o.contextValidateResults(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *IpamFhrpGroupsListOKBody) contextValidateResults(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(o.Results); i++ { + + if o.Results[i] != nil { + if err := o.Results[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("ipamFhrpGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("ipamFhrpGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (o *IpamFhrpGroupsListOKBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *IpamFhrpGroupsListOKBody) UnmarshalBinary(b []byte) error { + var res IpamFhrpGroupsListOKBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_partial_update_parameters.go b/netbox/client/ipam/ipam_fhrp_groups_partial_update_parameters.go new file mode 100644 index 00000000..4544078c --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_partial_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamFhrpGroupsPartialUpdateParams creates a new IpamFhrpGroupsPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupsPartialUpdateParams() *IpamFhrpGroupsPartialUpdateParams { + return &IpamFhrpGroupsPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupsPartialUpdateParamsWithTimeout creates a new IpamFhrpGroupsPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupsPartialUpdateParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupsPartialUpdateParams { + return &IpamFhrpGroupsPartialUpdateParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupsPartialUpdateParamsWithContext creates a new IpamFhrpGroupsPartialUpdateParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupsPartialUpdateParamsWithContext(ctx context.Context) *IpamFhrpGroupsPartialUpdateParams { + return &IpamFhrpGroupsPartialUpdateParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupsPartialUpdateParamsWithHTTPClient creates a new IpamFhrpGroupsPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupsPartialUpdateParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupsPartialUpdateParams { + return &IpamFhrpGroupsPartialUpdateParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupsPartialUpdateParams contains all the parameters to send to the API endpoint + for the ipam fhrp groups partial update operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupsPartialUpdateParams struct { + + // Data. + Data *models.FHRPGroup + + /* ID. + + A unique integer value identifying this FHRP group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp groups partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsPartialUpdateParams) WithDefaults() *IpamFhrpGroupsPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp groups partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp groups partial update params +func (o *IpamFhrpGroupsPartialUpdateParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupsPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp groups partial update params +func (o *IpamFhrpGroupsPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp groups partial update params +func (o *IpamFhrpGroupsPartialUpdateParams) WithContext(ctx context.Context) *IpamFhrpGroupsPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp groups partial update params +func (o *IpamFhrpGroupsPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp groups partial update params +func (o *IpamFhrpGroupsPartialUpdateParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupsPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp groups partial update params +func (o *IpamFhrpGroupsPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam fhrp groups partial update params +func (o *IpamFhrpGroupsPartialUpdateParams) WithData(data *models.FHRPGroup) *IpamFhrpGroupsPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam fhrp groups partial update params +func (o *IpamFhrpGroupsPartialUpdateParams) SetData(data *models.FHRPGroup) { + o.Data = data +} + +// WithID adds the id to the ipam fhrp groups partial update params +func (o *IpamFhrpGroupsPartialUpdateParams) WithID(id int64) *IpamFhrpGroupsPartialUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam fhrp groups partial update params +func (o *IpamFhrpGroupsPartialUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupsPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_partial_update_responses.go b/netbox/client/ipam/ipam_fhrp_groups_partial_update_responses.go new file mode 100644 index 00000000..a4b843d2 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupsPartialUpdateReader is a Reader for the IpamFhrpGroupsPartialUpdate structure. +type IpamFhrpGroupsPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupsPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupsPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupsPartialUpdateOK creates a IpamFhrpGroupsPartialUpdateOK with default headers values +func NewIpamFhrpGroupsPartialUpdateOK() *IpamFhrpGroupsPartialUpdateOK { + return &IpamFhrpGroupsPartialUpdateOK{} +} + +/* IpamFhrpGroupsPartialUpdateOK describes a response with status code 200, with default header values. + +IpamFhrpGroupsPartialUpdateOK ipam fhrp groups partial update o k +*/ +type IpamFhrpGroupsPartialUpdateOK struct { + Payload *models.FHRPGroup +} + +func (o *IpamFhrpGroupsPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /ipam/fhrp-groups/{id}/][%d] ipamFhrpGroupsPartialUpdateOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupsPartialUpdateOK) GetPayload() *models.FHRPGroup { + return o.Payload +} + +func (o *IpamFhrpGroupsPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_read_parameters.go b/netbox/client/ipam/ipam_fhrp_groups_read_parameters.go new file mode 100644 index 00000000..af8aa3a2 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_read_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewIpamFhrpGroupsReadParams creates a new IpamFhrpGroupsReadParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupsReadParams() *IpamFhrpGroupsReadParams { + return &IpamFhrpGroupsReadParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupsReadParamsWithTimeout creates a new IpamFhrpGroupsReadParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupsReadParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupsReadParams { + return &IpamFhrpGroupsReadParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupsReadParamsWithContext creates a new IpamFhrpGroupsReadParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupsReadParamsWithContext(ctx context.Context) *IpamFhrpGroupsReadParams { + return &IpamFhrpGroupsReadParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupsReadParamsWithHTTPClient creates a new IpamFhrpGroupsReadParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupsReadParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupsReadParams { + return &IpamFhrpGroupsReadParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupsReadParams contains all the parameters to send to the API endpoint + for the ipam fhrp groups read operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupsReadParams struct { + + /* ID. + + A unique integer value identifying this FHRP group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp groups read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsReadParams) WithDefaults() *IpamFhrpGroupsReadParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp groups read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsReadParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp groups read params +func (o *IpamFhrpGroupsReadParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupsReadParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp groups read params +func (o *IpamFhrpGroupsReadParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp groups read params +func (o *IpamFhrpGroupsReadParams) WithContext(ctx context.Context) *IpamFhrpGroupsReadParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp groups read params +func (o *IpamFhrpGroupsReadParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp groups read params +func (o *IpamFhrpGroupsReadParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupsReadParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp groups read params +func (o *IpamFhrpGroupsReadParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the ipam fhrp groups read params +func (o *IpamFhrpGroupsReadParams) WithID(id int64) *IpamFhrpGroupsReadParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam fhrp groups read params +func (o *IpamFhrpGroupsReadParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupsReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_read_responses.go b/netbox/client/ipam/ipam_fhrp_groups_read_responses.go new file mode 100644 index 00000000..402f70c7 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_read_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupsReadReader is a Reader for the IpamFhrpGroupsRead structure. +type IpamFhrpGroupsReadReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupsReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupsReadOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupsReadOK creates a IpamFhrpGroupsReadOK with default headers values +func NewIpamFhrpGroupsReadOK() *IpamFhrpGroupsReadOK { + return &IpamFhrpGroupsReadOK{} +} + +/* IpamFhrpGroupsReadOK describes a response with status code 200, with default header values. + +IpamFhrpGroupsReadOK ipam fhrp groups read o k +*/ +type IpamFhrpGroupsReadOK struct { + Payload *models.FHRPGroup +} + +func (o *IpamFhrpGroupsReadOK) Error() string { + return fmt.Sprintf("[GET /ipam/fhrp-groups/{id}/][%d] ipamFhrpGroupsReadOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupsReadOK) GetPayload() *models.FHRPGroup { + return o.Payload +} + +func (o *IpamFhrpGroupsReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_update_parameters.go b/netbox/client/ipam/ipam_fhrp_groups_update_parameters.go new file mode 100644 index 00000000..12c01178 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewIpamFhrpGroupsUpdateParams creates a new IpamFhrpGroupsUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewIpamFhrpGroupsUpdateParams() *IpamFhrpGroupsUpdateParams { + return &IpamFhrpGroupsUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewIpamFhrpGroupsUpdateParamsWithTimeout creates a new IpamFhrpGroupsUpdateParams object +// with the ability to set a timeout on a request. +func NewIpamFhrpGroupsUpdateParamsWithTimeout(timeout time.Duration) *IpamFhrpGroupsUpdateParams { + return &IpamFhrpGroupsUpdateParams{ + timeout: timeout, + } +} + +// NewIpamFhrpGroupsUpdateParamsWithContext creates a new IpamFhrpGroupsUpdateParams object +// with the ability to set a context for a request. +func NewIpamFhrpGroupsUpdateParamsWithContext(ctx context.Context) *IpamFhrpGroupsUpdateParams { + return &IpamFhrpGroupsUpdateParams{ + Context: ctx, + } +} + +// NewIpamFhrpGroupsUpdateParamsWithHTTPClient creates a new IpamFhrpGroupsUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewIpamFhrpGroupsUpdateParamsWithHTTPClient(client *http.Client) *IpamFhrpGroupsUpdateParams { + return &IpamFhrpGroupsUpdateParams{ + HTTPClient: client, + } +} + +/* IpamFhrpGroupsUpdateParams contains all the parameters to send to the API endpoint + for the ipam fhrp groups update operation. + + Typically these are written to a http.Request. +*/ +type IpamFhrpGroupsUpdateParams struct { + + // Data. + Data *models.FHRPGroup + + /* ID. + + A unique integer value identifying this FHRP group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the ipam fhrp groups update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsUpdateParams) WithDefaults() *IpamFhrpGroupsUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the ipam fhrp groups update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *IpamFhrpGroupsUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the ipam fhrp groups update params +func (o *IpamFhrpGroupsUpdateParams) WithTimeout(timeout time.Duration) *IpamFhrpGroupsUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the ipam fhrp groups update params +func (o *IpamFhrpGroupsUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the ipam fhrp groups update params +func (o *IpamFhrpGroupsUpdateParams) WithContext(ctx context.Context) *IpamFhrpGroupsUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the ipam fhrp groups update params +func (o *IpamFhrpGroupsUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the ipam fhrp groups update params +func (o *IpamFhrpGroupsUpdateParams) WithHTTPClient(client *http.Client) *IpamFhrpGroupsUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the ipam fhrp groups update params +func (o *IpamFhrpGroupsUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the ipam fhrp groups update params +func (o *IpamFhrpGroupsUpdateParams) WithData(data *models.FHRPGroup) *IpamFhrpGroupsUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the ipam fhrp groups update params +func (o *IpamFhrpGroupsUpdateParams) SetData(data *models.FHRPGroup) { + o.Data = data +} + +// WithID adds the id to the ipam fhrp groups update params +func (o *IpamFhrpGroupsUpdateParams) WithID(id int64) *IpamFhrpGroupsUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the ipam fhrp groups update params +func (o *IpamFhrpGroupsUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *IpamFhrpGroupsUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/ipam/ipam_fhrp_groups_update_responses.go b/netbox/client/ipam/ipam_fhrp_groups_update_responses.go new file mode 100644 index 00000000..5c068ca5 --- /dev/null +++ b/netbox/client/ipam/ipam_fhrp_groups_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package ipam + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// IpamFhrpGroupsUpdateReader is a Reader for the IpamFhrpGroupsUpdate structure. +type IpamFhrpGroupsUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *IpamFhrpGroupsUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewIpamFhrpGroupsUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewIpamFhrpGroupsUpdateOK creates a IpamFhrpGroupsUpdateOK with default headers values +func NewIpamFhrpGroupsUpdateOK() *IpamFhrpGroupsUpdateOK { + return &IpamFhrpGroupsUpdateOK{} +} + +/* IpamFhrpGroupsUpdateOK describes a response with status code 200, with default header values. + +IpamFhrpGroupsUpdateOK ipam fhrp groups update o k +*/ +type IpamFhrpGroupsUpdateOK struct { + Payload *models.FHRPGroup +} + +func (o *IpamFhrpGroupsUpdateOK) Error() string { + return fmt.Sprintf("[PUT /ipam/fhrp-groups/{id}/][%d] ipamFhrpGroupsUpdateOK %+v", 200, o.Payload) +} +func (o *IpamFhrpGroupsUpdateOK) GetPayload() *models.FHRPGroup { + return o.Payload +} + +func (o *IpamFhrpGroupsUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.FHRPGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/ipam/ipam_ip_ranges_available_ips_create_parameters.go b/netbox/client/ipam/ipam_ip_ranges_available_ips_create_parameters.go index 8a7e3a32..8befe3e2 100644 --- a/netbox/client/ipam/ipam_ip_ranges_available_ips_create_parameters.go +++ b/netbox/client/ipam/ipam_ip_ranges_available_ips_create_parameters.go @@ -78,11 +78,11 @@ func NewIpamIPRangesAvailableIpsCreateParamsWithHTTPClient(client *http.Client) type IpamIPRangesAvailableIpsCreateParams struct { // Data. - Data []*models.AvailableIP + Data *models.WritableAvailableIP /* ID. - A unique integer value identifying this IP range. + A unique integer value identifying this IP address. */ ID int64 @@ -140,13 +140,13 @@ func (o *IpamIPRangesAvailableIpsCreateParams) SetHTTPClient(client *http.Client } // WithData adds the data to the ipam ip ranges available ips create params -func (o *IpamIPRangesAvailableIpsCreateParams) WithData(data []*models.AvailableIP) *IpamIPRangesAvailableIpsCreateParams { +func (o *IpamIPRangesAvailableIpsCreateParams) WithData(data *models.WritableAvailableIP) *IpamIPRangesAvailableIpsCreateParams { o.SetData(data) return o } // SetData adds the data to the ipam ip ranges available ips create params -func (o *IpamIPRangesAvailableIpsCreateParams) SetData(data []*models.AvailableIP) { +func (o *IpamIPRangesAvailableIpsCreateParams) SetData(data *models.WritableAvailableIP) { o.Data = data } diff --git a/netbox/client/ipam/ipam_ip_ranges_available_ips_create_responses.go b/netbox/client/ipam/ipam_ip_ranges_available_ips_create_responses.go index 9c39252c..479e61ab 100644 --- a/netbox/client/ipam/ipam_ip_ranges_available_ips_create_responses.go +++ b/netbox/client/ipam/ipam_ip_ranges_available_ips_create_responses.go @@ -59,13 +59,13 @@ func NewIpamIPRangesAvailableIpsCreateCreated() *IpamIPRangesAvailableIpsCreateC IpamIPRangesAvailableIpsCreateCreated ipam Ip ranges available ips create created */ type IpamIPRangesAvailableIpsCreateCreated struct { - Payload []*models.AvailableIP + Payload []*models.IPAddress } func (o *IpamIPRangesAvailableIpsCreateCreated) Error() string { return fmt.Sprintf("[POST /ipam/ip-ranges/{id}/available-ips/][%d] ipamIpRangesAvailableIpsCreateCreated %+v", 201, o.Payload) } -func (o *IpamIPRangesAvailableIpsCreateCreated) GetPayload() []*models.AvailableIP { +func (o *IpamIPRangesAvailableIpsCreateCreated) GetPayload() []*models.IPAddress { return o.Payload } diff --git a/netbox/client/ipam/ipam_ip_ranges_available_ips_read_parameters.go b/netbox/client/ipam/ipam_ip_ranges_available_ips_list_parameters.go similarity index 56% rename from netbox/client/ipam/ipam_ip_ranges_available_ips_read_parameters.go rename to netbox/client/ipam/ipam_ip_ranges_available_ips_list_parameters.go index 499945cf..0a8c4f09 100644 --- a/netbox/client/ipam/ipam_ip_ranges_available_ips_read_parameters.go +++ b/netbox/client/ipam/ipam_ip_ranges_available_ips_list_parameters.go @@ -32,52 +32,52 @@ import ( "github.com/go-openapi/swag" ) -// NewIpamIPRangesAvailableIpsReadParams creates a new IpamIPRangesAvailableIpsReadParams object, +// NewIpamIPRangesAvailableIpsListParams creates a new IpamIPRangesAvailableIpsListParams object, // with the default timeout for this client. // // Default values are not hydrated, since defaults are normally applied by the API server side. // // To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewIpamIPRangesAvailableIpsReadParams() *IpamIPRangesAvailableIpsReadParams { - return &IpamIPRangesAvailableIpsReadParams{ +func NewIpamIPRangesAvailableIpsListParams() *IpamIPRangesAvailableIpsListParams { + return &IpamIPRangesAvailableIpsListParams{ timeout: cr.DefaultTimeout, } } -// NewIpamIPRangesAvailableIpsReadParamsWithTimeout creates a new IpamIPRangesAvailableIpsReadParams object +// NewIpamIPRangesAvailableIpsListParamsWithTimeout creates a new IpamIPRangesAvailableIpsListParams object // with the ability to set a timeout on a request. -func NewIpamIPRangesAvailableIpsReadParamsWithTimeout(timeout time.Duration) *IpamIPRangesAvailableIpsReadParams { - return &IpamIPRangesAvailableIpsReadParams{ +func NewIpamIPRangesAvailableIpsListParamsWithTimeout(timeout time.Duration) *IpamIPRangesAvailableIpsListParams { + return &IpamIPRangesAvailableIpsListParams{ timeout: timeout, } } -// NewIpamIPRangesAvailableIpsReadParamsWithContext creates a new IpamIPRangesAvailableIpsReadParams object +// NewIpamIPRangesAvailableIpsListParamsWithContext creates a new IpamIPRangesAvailableIpsListParams object // with the ability to set a context for a request. -func NewIpamIPRangesAvailableIpsReadParamsWithContext(ctx context.Context) *IpamIPRangesAvailableIpsReadParams { - return &IpamIPRangesAvailableIpsReadParams{ +func NewIpamIPRangesAvailableIpsListParamsWithContext(ctx context.Context) *IpamIPRangesAvailableIpsListParams { + return &IpamIPRangesAvailableIpsListParams{ Context: ctx, } } -// NewIpamIPRangesAvailableIpsReadParamsWithHTTPClient creates a new IpamIPRangesAvailableIpsReadParams object +// NewIpamIPRangesAvailableIpsListParamsWithHTTPClient creates a new IpamIPRangesAvailableIpsListParams object // with the ability to set a custom HTTPClient for a request. -func NewIpamIPRangesAvailableIpsReadParamsWithHTTPClient(client *http.Client) *IpamIPRangesAvailableIpsReadParams { - return &IpamIPRangesAvailableIpsReadParams{ +func NewIpamIPRangesAvailableIpsListParamsWithHTTPClient(client *http.Client) *IpamIPRangesAvailableIpsListParams { + return &IpamIPRangesAvailableIpsListParams{ HTTPClient: client, } } -/* IpamIPRangesAvailableIpsReadParams contains all the parameters to send to the API endpoint - for the ipam ip ranges available ips read operation. +/* IpamIPRangesAvailableIpsListParams contains all the parameters to send to the API endpoint + for the ipam ip ranges available ips list operation. Typically these are written to a http.Request. */ -type IpamIPRangesAvailableIpsReadParams struct { +type IpamIPRangesAvailableIpsListParams struct { /* ID. - A unique integer value identifying this IP range. + A unique integer value identifying this IP address. */ ID int64 @@ -86,67 +86,67 @@ type IpamIPRangesAvailableIpsReadParams struct { HTTPClient *http.Client } -// WithDefaults hydrates default values in the ipam ip ranges available ips read params (not the query body). +// WithDefaults hydrates default values in the ipam ip ranges available ips list params (not the query body). // // All values with no default are reset to their zero value. -func (o *IpamIPRangesAvailableIpsReadParams) WithDefaults() *IpamIPRangesAvailableIpsReadParams { +func (o *IpamIPRangesAvailableIpsListParams) WithDefaults() *IpamIPRangesAvailableIpsListParams { o.SetDefaults() return o } -// SetDefaults hydrates default values in the ipam ip ranges available ips read params (not the query body). +// SetDefaults hydrates default values in the ipam ip ranges available ips list params (not the query body). // // All values with no default are reset to their zero value. -func (o *IpamIPRangesAvailableIpsReadParams) SetDefaults() { +func (o *IpamIPRangesAvailableIpsListParams) SetDefaults() { // no default values defined for this parameter } -// WithTimeout adds the timeout to the ipam ip ranges available ips read params -func (o *IpamIPRangesAvailableIpsReadParams) WithTimeout(timeout time.Duration) *IpamIPRangesAvailableIpsReadParams { +// WithTimeout adds the timeout to the ipam ip ranges available ips list params +func (o *IpamIPRangesAvailableIpsListParams) WithTimeout(timeout time.Duration) *IpamIPRangesAvailableIpsListParams { o.SetTimeout(timeout) return o } -// SetTimeout adds the timeout to the ipam ip ranges available ips read params -func (o *IpamIPRangesAvailableIpsReadParams) SetTimeout(timeout time.Duration) { +// SetTimeout adds the timeout to the ipam ip ranges available ips list params +func (o *IpamIPRangesAvailableIpsListParams) SetTimeout(timeout time.Duration) { o.timeout = timeout } -// WithContext adds the context to the ipam ip ranges available ips read params -func (o *IpamIPRangesAvailableIpsReadParams) WithContext(ctx context.Context) *IpamIPRangesAvailableIpsReadParams { +// WithContext adds the context to the ipam ip ranges available ips list params +func (o *IpamIPRangesAvailableIpsListParams) WithContext(ctx context.Context) *IpamIPRangesAvailableIpsListParams { o.SetContext(ctx) return o } -// SetContext adds the context to the ipam ip ranges available ips read params -func (o *IpamIPRangesAvailableIpsReadParams) SetContext(ctx context.Context) { +// SetContext adds the context to the ipam ip ranges available ips list params +func (o *IpamIPRangesAvailableIpsListParams) SetContext(ctx context.Context) { o.Context = ctx } -// WithHTTPClient adds the HTTPClient to the ipam ip ranges available ips read params -func (o *IpamIPRangesAvailableIpsReadParams) WithHTTPClient(client *http.Client) *IpamIPRangesAvailableIpsReadParams { +// WithHTTPClient adds the HTTPClient to the ipam ip ranges available ips list params +func (o *IpamIPRangesAvailableIpsListParams) WithHTTPClient(client *http.Client) *IpamIPRangesAvailableIpsListParams { o.SetHTTPClient(client) return o } -// SetHTTPClient adds the HTTPClient to the ipam ip ranges available ips read params -func (o *IpamIPRangesAvailableIpsReadParams) SetHTTPClient(client *http.Client) { +// SetHTTPClient adds the HTTPClient to the ipam ip ranges available ips list params +func (o *IpamIPRangesAvailableIpsListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } -// WithID adds the id to the ipam ip ranges available ips read params -func (o *IpamIPRangesAvailableIpsReadParams) WithID(id int64) *IpamIPRangesAvailableIpsReadParams { +// WithID adds the id to the ipam ip ranges available ips list params +func (o *IpamIPRangesAvailableIpsListParams) WithID(id int64) *IpamIPRangesAvailableIpsListParams { o.SetID(id) return o } -// SetID adds the id to the ipam ip ranges available ips read params -func (o *IpamIPRangesAvailableIpsReadParams) SetID(id int64) { +// SetID adds the id to the ipam ip ranges available ips list params +func (o *IpamIPRangesAvailableIpsListParams) SetID(id int64) { o.ID = id } // WriteToRequest writes these params to a swagger request -func (o *IpamIPRangesAvailableIpsReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { +func (o *IpamIPRangesAvailableIpsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { if err := r.SetTimeout(o.timeout); err != nil { return err diff --git a/netbox/client/ipam/ipam_ip_ranges_available_ips_read_responses.go b/netbox/client/ipam/ipam_ip_ranges_available_ips_list_responses.go similarity index 69% rename from netbox/client/ipam/ipam_ip_ranges_available_ips_read_responses.go rename to netbox/client/ipam/ipam_ip_ranges_available_ips_list_responses.go index b2d1bd54..b06905d3 100644 --- a/netbox/client/ipam/ipam_ip_ranges_available_ips_read_responses.go +++ b/netbox/client/ipam/ipam_ip_ranges_available_ips_list_responses.go @@ -30,16 +30,16 @@ import ( "github.com/smutel/go-netbox/netbox/models" ) -// IpamIPRangesAvailableIpsReadReader is a Reader for the IpamIPRangesAvailableIpsRead structure. -type IpamIPRangesAvailableIpsReadReader struct { +// IpamIPRangesAvailableIpsListReader is a Reader for the IpamIPRangesAvailableIpsList structure. +type IpamIPRangesAvailableIpsListReader struct { formats strfmt.Registry } // ReadResponse reads a server response into the received o. -func (o *IpamIPRangesAvailableIpsReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { +func (o *IpamIPRangesAvailableIpsListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { switch response.Code() { case 200: - result := NewIpamIPRangesAvailableIpsReadOK() + result := NewIpamIPRangesAvailableIpsListOK() if err := result.readResponse(response, consumer, o.formats); err != nil { return nil, err } @@ -49,27 +49,27 @@ func (o *IpamIPRangesAvailableIpsReadReader) ReadResponse(response runtime.Clien } } -// NewIpamIPRangesAvailableIpsReadOK creates a IpamIPRangesAvailableIpsReadOK with default headers values -func NewIpamIPRangesAvailableIpsReadOK() *IpamIPRangesAvailableIpsReadOK { - return &IpamIPRangesAvailableIpsReadOK{} +// NewIpamIPRangesAvailableIpsListOK creates a IpamIPRangesAvailableIpsListOK with default headers values +func NewIpamIPRangesAvailableIpsListOK() *IpamIPRangesAvailableIpsListOK { + return &IpamIPRangesAvailableIpsListOK{} } -/* IpamIPRangesAvailableIpsReadOK describes a response with status code 200, with default header values. +/* IpamIPRangesAvailableIpsListOK describes a response with status code 200, with default header values. -IpamIPRangesAvailableIpsReadOK ipam Ip ranges available ips read o k +IpamIPRangesAvailableIpsListOK ipam Ip ranges available ips list o k */ -type IpamIPRangesAvailableIpsReadOK struct { +type IpamIPRangesAvailableIpsListOK struct { Payload []*models.AvailableIP } -func (o *IpamIPRangesAvailableIpsReadOK) Error() string { - return fmt.Sprintf("[GET /ipam/ip-ranges/{id}/available-ips/][%d] ipamIpRangesAvailableIpsReadOK %+v", 200, o.Payload) +func (o *IpamIPRangesAvailableIpsListOK) Error() string { + return fmt.Sprintf("[GET /ipam/ip-ranges/{id}/available-ips/][%d] ipamIpRangesAvailableIpsListOK %+v", 200, o.Payload) } -func (o *IpamIPRangesAvailableIpsReadOK) GetPayload() []*models.AvailableIP { +func (o *IpamIPRangesAvailableIpsListOK) GetPayload() []*models.AvailableIP { return o.Payload } -func (o *IpamIPRangesAvailableIpsReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { +func (o *IpamIPRangesAvailableIpsListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { // response payload if err := consumer.Consume(response.Body(), &o.Payload); err != nil && err != io.EOF { diff --git a/netbox/client/ipam/ipam_ip_ranges_list_parameters.go b/netbox/client/ipam/ipam_ip_ranges_list_parameters.go index a9da48a4..acfba48f 100644 --- a/netbox/client/ipam/ipam_ip_ranges_list_parameters.go +++ b/netbox/client/ipam/ipam_ip_ranges_list_parameters.go @@ -87,6 +87,39 @@ type IpamIPRangesListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // Family. Family *float64 @@ -289,6 +322,127 @@ func (o *IpamIPRangesListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the ipam ip ranges list params +func (o *IpamIPRangesListParams) WithDescription(description *string) *IpamIPRangesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the ipam ip ranges list params +func (o *IpamIPRangesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the ipam ip ranges list params +func (o *IpamIPRangesListParams) WithDescriptionEmpty(descriptionEmpty *string) *IpamIPRangesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the ipam ip ranges list params +func (o *IpamIPRangesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the ipam ip ranges list params +func (o *IpamIPRangesListParams) WithDescriptionIc(descriptionIc *string) *IpamIPRangesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the ipam ip ranges list params +func (o *IpamIPRangesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the ipam ip ranges list params +func (o *IpamIPRangesListParams) WithDescriptionIe(descriptionIe *string) *IpamIPRangesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the ipam ip ranges list params +func (o *IpamIPRangesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the ipam ip ranges list params +func (o *IpamIPRangesListParams) WithDescriptionIew(descriptionIew *string) *IpamIPRangesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the ipam ip ranges list params +func (o *IpamIPRangesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the ipam ip ranges list params +func (o *IpamIPRangesListParams) WithDescriptionIsw(descriptionIsw *string) *IpamIPRangesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the ipam ip ranges list params +func (o *IpamIPRangesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the ipam ip ranges list params +func (o *IpamIPRangesListParams) WithDescriptionn(descriptionn *string) *IpamIPRangesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the ipam ip ranges list params +func (o *IpamIPRangesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the ipam ip ranges list params +func (o *IpamIPRangesListParams) WithDescriptionNic(descriptionNic *string) *IpamIPRangesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the ipam ip ranges list params +func (o *IpamIPRangesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the ipam ip ranges list params +func (o *IpamIPRangesListParams) WithDescriptionNie(descriptionNie *string) *IpamIPRangesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the ipam ip ranges list params +func (o *IpamIPRangesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the ipam ip ranges list params +func (o *IpamIPRangesListParams) WithDescriptionNiew(descriptionNiew *string) *IpamIPRangesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the ipam ip ranges list params +func (o *IpamIPRangesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the ipam ip ranges list params +func (o *IpamIPRangesListParams) WithDescriptionNisw(descriptionNisw *string) *IpamIPRangesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the ipam ip ranges list params +func (o *IpamIPRangesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithFamily adds the family to the ipam ip ranges list params func (o *IpamIPRangesListParams) WithFamily(family *float64) *IpamIPRangesListParams { o.SetFamily(family) @@ -728,6 +882,193 @@ func (o *IpamIPRangesListParams) WriteToRequest(r runtime.ClientRequest, reg str } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.Family != nil { // query param family diff --git a/netbox/client/ipam/ipam_prefixes_available_ips_create_parameters.go b/netbox/client/ipam/ipam_prefixes_available_ips_create_parameters.go index 98d43768..feb155ff 100644 --- a/netbox/client/ipam/ipam_prefixes_available_ips_create_parameters.go +++ b/netbox/client/ipam/ipam_prefixes_available_ips_create_parameters.go @@ -78,11 +78,11 @@ func NewIpamPrefixesAvailableIpsCreateParamsWithHTTPClient(client *http.Client) type IpamPrefixesAvailableIpsCreateParams struct { // Data. - Data []*models.AvailableIP + Data *models.WritableAvailableIP /* ID. - A unique integer value identifying this prefix. + A unique integer value identifying this IP address. */ ID int64 @@ -140,13 +140,13 @@ func (o *IpamPrefixesAvailableIpsCreateParams) SetHTTPClient(client *http.Client } // WithData adds the data to the ipam prefixes available ips create params -func (o *IpamPrefixesAvailableIpsCreateParams) WithData(data []*models.AvailableIP) *IpamPrefixesAvailableIpsCreateParams { +func (o *IpamPrefixesAvailableIpsCreateParams) WithData(data *models.WritableAvailableIP) *IpamPrefixesAvailableIpsCreateParams { o.SetData(data) return o } // SetData adds the data to the ipam prefixes available ips create params -func (o *IpamPrefixesAvailableIpsCreateParams) SetData(data []*models.AvailableIP) { +func (o *IpamPrefixesAvailableIpsCreateParams) SetData(data *models.WritableAvailableIP) { o.Data = data } diff --git a/netbox/client/ipam/ipam_prefixes_available_ips_create_responses.go b/netbox/client/ipam/ipam_prefixes_available_ips_create_responses.go index ed23adaa..0c696fba 100644 --- a/netbox/client/ipam/ipam_prefixes_available_ips_create_responses.go +++ b/netbox/client/ipam/ipam_prefixes_available_ips_create_responses.go @@ -59,13 +59,13 @@ func NewIpamPrefixesAvailableIpsCreateCreated() *IpamPrefixesAvailableIpsCreateC IpamPrefixesAvailableIpsCreateCreated ipam prefixes available ips create created */ type IpamPrefixesAvailableIpsCreateCreated struct { - Payload []*models.AvailableIP + Payload []*models.IPAddress } func (o *IpamPrefixesAvailableIpsCreateCreated) Error() string { return fmt.Sprintf("[POST /ipam/prefixes/{id}/available-ips/][%d] ipamPrefixesAvailableIpsCreateCreated %+v", 201, o.Payload) } -func (o *IpamPrefixesAvailableIpsCreateCreated) GetPayload() []*models.AvailableIP { +func (o *IpamPrefixesAvailableIpsCreateCreated) GetPayload() []*models.IPAddress { return o.Payload } diff --git a/netbox/client/ipam/ipam_prefixes_available_ips_read_parameters.go b/netbox/client/ipam/ipam_prefixes_available_ips_list_parameters.go similarity index 56% rename from netbox/client/ipam/ipam_prefixes_available_ips_read_parameters.go rename to netbox/client/ipam/ipam_prefixes_available_ips_list_parameters.go index 71228c85..c9fa4a46 100644 --- a/netbox/client/ipam/ipam_prefixes_available_ips_read_parameters.go +++ b/netbox/client/ipam/ipam_prefixes_available_ips_list_parameters.go @@ -32,52 +32,52 @@ import ( "github.com/go-openapi/swag" ) -// NewIpamPrefixesAvailableIpsReadParams creates a new IpamPrefixesAvailableIpsReadParams object, +// NewIpamPrefixesAvailableIpsListParams creates a new IpamPrefixesAvailableIpsListParams object, // with the default timeout for this client. // // Default values are not hydrated, since defaults are normally applied by the API server side. // // To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewIpamPrefixesAvailableIpsReadParams() *IpamPrefixesAvailableIpsReadParams { - return &IpamPrefixesAvailableIpsReadParams{ +func NewIpamPrefixesAvailableIpsListParams() *IpamPrefixesAvailableIpsListParams { + return &IpamPrefixesAvailableIpsListParams{ timeout: cr.DefaultTimeout, } } -// NewIpamPrefixesAvailableIpsReadParamsWithTimeout creates a new IpamPrefixesAvailableIpsReadParams object +// NewIpamPrefixesAvailableIpsListParamsWithTimeout creates a new IpamPrefixesAvailableIpsListParams object // with the ability to set a timeout on a request. -func NewIpamPrefixesAvailableIpsReadParamsWithTimeout(timeout time.Duration) *IpamPrefixesAvailableIpsReadParams { - return &IpamPrefixesAvailableIpsReadParams{ +func NewIpamPrefixesAvailableIpsListParamsWithTimeout(timeout time.Duration) *IpamPrefixesAvailableIpsListParams { + return &IpamPrefixesAvailableIpsListParams{ timeout: timeout, } } -// NewIpamPrefixesAvailableIpsReadParamsWithContext creates a new IpamPrefixesAvailableIpsReadParams object +// NewIpamPrefixesAvailableIpsListParamsWithContext creates a new IpamPrefixesAvailableIpsListParams object // with the ability to set a context for a request. -func NewIpamPrefixesAvailableIpsReadParamsWithContext(ctx context.Context) *IpamPrefixesAvailableIpsReadParams { - return &IpamPrefixesAvailableIpsReadParams{ +func NewIpamPrefixesAvailableIpsListParamsWithContext(ctx context.Context) *IpamPrefixesAvailableIpsListParams { + return &IpamPrefixesAvailableIpsListParams{ Context: ctx, } } -// NewIpamPrefixesAvailableIpsReadParamsWithHTTPClient creates a new IpamPrefixesAvailableIpsReadParams object +// NewIpamPrefixesAvailableIpsListParamsWithHTTPClient creates a new IpamPrefixesAvailableIpsListParams object // with the ability to set a custom HTTPClient for a request. -func NewIpamPrefixesAvailableIpsReadParamsWithHTTPClient(client *http.Client) *IpamPrefixesAvailableIpsReadParams { - return &IpamPrefixesAvailableIpsReadParams{ +func NewIpamPrefixesAvailableIpsListParamsWithHTTPClient(client *http.Client) *IpamPrefixesAvailableIpsListParams { + return &IpamPrefixesAvailableIpsListParams{ HTTPClient: client, } } -/* IpamPrefixesAvailableIpsReadParams contains all the parameters to send to the API endpoint - for the ipam prefixes available ips read operation. +/* IpamPrefixesAvailableIpsListParams contains all the parameters to send to the API endpoint + for the ipam prefixes available ips list operation. Typically these are written to a http.Request. */ -type IpamPrefixesAvailableIpsReadParams struct { +type IpamPrefixesAvailableIpsListParams struct { /* ID. - A unique integer value identifying this prefix. + A unique integer value identifying this IP address. */ ID int64 @@ -86,67 +86,67 @@ type IpamPrefixesAvailableIpsReadParams struct { HTTPClient *http.Client } -// WithDefaults hydrates default values in the ipam prefixes available ips read params (not the query body). +// WithDefaults hydrates default values in the ipam prefixes available ips list params (not the query body). // // All values with no default are reset to their zero value. -func (o *IpamPrefixesAvailableIpsReadParams) WithDefaults() *IpamPrefixesAvailableIpsReadParams { +func (o *IpamPrefixesAvailableIpsListParams) WithDefaults() *IpamPrefixesAvailableIpsListParams { o.SetDefaults() return o } -// SetDefaults hydrates default values in the ipam prefixes available ips read params (not the query body). +// SetDefaults hydrates default values in the ipam prefixes available ips list params (not the query body). // // All values with no default are reset to their zero value. -func (o *IpamPrefixesAvailableIpsReadParams) SetDefaults() { +func (o *IpamPrefixesAvailableIpsListParams) SetDefaults() { // no default values defined for this parameter } -// WithTimeout adds the timeout to the ipam prefixes available ips read params -func (o *IpamPrefixesAvailableIpsReadParams) WithTimeout(timeout time.Duration) *IpamPrefixesAvailableIpsReadParams { +// WithTimeout adds the timeout to the ipam prefixes available ips list params +func (o *IpamPrefixesAvailableIpsListParams) WithTimeout(timeout time.Duration) *IpamPrefixesAvailableIpsListParams { o.SetTimeout(timeout) return o } -// SetTimeout adds the timeout to the ipam prefixes available ips read params -func (o *IpamPrefixesAvailableIpsReadParams) SetTimeout(timeout time.Duration) { +// SetTimeout adds the timeout to the ipam prefixes available ips list params +func (o *IpamPrefixesAvailableIpsListParams) SetTimeout(timeout time.Duration) { o.timeout = timeout } -// WithContext adds the context to the ipam prefixes available ips read params -func (o *IpamPrefixesAvailableIpsReadParams) WithContext(ctx context.Context) *IpamPrefixesAvailableIpsReadParams { +// WithContext adds the context to the ipam prefixes available ips list params +func (o *IpamPrefixesAvailableIpsListParams) WithContext(ctx context.Context) *IpamPrefixesAvailableIpsListParams { o.SetContext(ctx) return o } -// SetContext adds the context to the ipam prefixes available ips read params -func (o *IpamPrefixesAvailableIpsReadParams) SetContext(ctx context.Context) { +// SetContext adds the context to the ipam prefixes available ips list params +func (o *IpamPrefixesAvailableIpsListParams) SetContext(ctx context.Context) { o.Context = ctx } -// WithHTTPClient adds the HTTPClient to the ipam prefixes available ips read params -func (o *IpamPrefixesAvailableIpsReadParams) WithHTTPClient(client *http.Client) *IpamPrefixesAvailableIpsReadParams { +// WithHTTPClient adds the HTTPClient to the ipam prefixes available ips list params +func (o *IpamPrefixesAvailableIpsListParams) WithHTTPClient(client *http.Client) *IpamPrefixesAvailableIpsListParams { o.SetHTTPClient(client) return o } -// SetHTTPClient adds the HTTPClient to the ipam prefixes available ips read params -func (o *IpamPrefixesAvailableIpsReadParams) SetHTTPClient(client *http.Client) { +// SetHTTPClient adds the HTTPClient to the ipam prefixes available ips list params +func (o *IpamPrefixesAvailableIpsListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } -// WithID adds the id to the ipam prefixes available ips read params -func (o *IpamPrefixesAvailableIpsReadParams) WithID(id int64) *IpamPrefixesAvailableIpsReadParams { +// WithID adds the id to the ipam prefixes available ips list params +func (o *IpamPrefixesAvailableIpsListParams) WithID(id int64) *IpamPrefixesAvailableIpsListParams { o.SetID(id) return o } -// SetID adds the id to the ipam prefixes available ips read params -func (o *IpamPrefixesAvailableIpsReadParams) SetID(id int64) { +// SetID adds the id to the ipam prefixes available ips list params +func (o *IpamPrefixesAvailableIpsListParams) SetID(id int64) { o.ID = id } // WriteToRequest writes these params to a swagger request -func (o *IpamPrefixesAvailableIpsReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { +func (o *IpamPrefixesAvailableIpsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { if err := r.SetTimeout(o.timeout); err != nil { return err diff --git a/netbox/client/ipam/ipam_prefixes_available_ips_read_responses.go b/netbox/client/ipam/ipam_prefixes_available_ips_list_responses.go similarity index 69% rename from netbox/client/ipam/ipam_prefixes_available_ips_read_responses.go rename to netbox/client/ipam/ipam_prefixes_available_ips_list_responses.go index 48920287..50354a45 100644 --- a/netbox/client/ipam/ipam_prefixes_available_ips_read_responses.go +++ b/netbox/client/ipam/ipam_prefixes_available_ips_list_responses.go @@ -30,16 +30,16 @@ import ( "github.com/smutel/go-netbox/netbox/models" ) -// IpamPrefixesAvailableIpsReadReader is a Reader for the IpamPrefixesAvailableIpsRead structure. -type IpamPrefixesAvailableIpsReadReader struct { +// IpamPrefixesAvailableIpsListReader is a Reader for the IpamPrefixesAvailableIpsList structure. +type IpamPrefixesAvailableIpsListReader struct { formats strfmt.Registry } // ReadResponse reads a server response into the received o. -func (o *IpamPrefixesAvailableIpsReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { +func (o *IpamPrefixesAvailableIpsListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { switch response.Code() { case 200: - result := NewIpamPrefixesAvailableIpsReadOK() + result := NewIpamPrefixesAvailableIpsListOK() if err := result.readResponse(response, consumer, o.formats); err != nil { return nil, err } @@ -49,27 +49,27 @@ func (o *IpamPrefixesAvailableIpsReadReader) ReadResponse(response runtime.Clien } } -// NewIpamPrefixesAvailableIpsReadOK creates a IpamPrefixesAvailableIpsReadOK with default headers values -func NewIpamPrefixesAvailableIpsReadOK() *IpamPrefixesAvailableIpsReadOK { - return &IpamPrefixesAvailableIpsReadOK{} +// NewIpamPrefixesAvailableIpsListOK creates a IpamPrefixesAvailableIpsListOK with default headers values +func NewIpamPrefixesAvailableIpsListOK() *IpamPrefixesAvailableIpsListOK { + return &IpamPrefixesAvailableIpsListOK{} } -/* IpamPrefixesAvailableIpsReadOK describes a response with status code 200, with default header values. +/* IpamPrefixesAvailableIpsListOK describes a response with status code 200, with default header values. -IpamPrefixesAvailableIpsReadOK ipam prefixes available ips read o k +IpamPrefixesAvailableIpsListOK ipam prefixes available ips list o k */ -type IpamPrefixesAvailableIpsReadOK struct { +type IpamPrefixesAvailableIpsListOK struct { Payload []*models.AvailableIP } -func (o *IpamPrefixesAvailableIpsReadOK) Error() string { - return fmt.Sprintf("[GET /ipam/prefixes/{id}/available-ips/][%d] ipamPrefixesAvailableIpsReadOK %+v", 200, o.Payload) +func (o *IpamPrefixesAvailableIpsListOK) Error() string { + return fmt.Sprintf("[GET /ipam/prefixes/{id}/available-ips/][%d] ipamPrefixesAvailableIpsListOK %+v", 200, o.Payload) } -func (o *IpamPrefixesAvailableIpsReadOK) GetPayload() []*models.AvailableIP { +func (o *IpamPrefixesAvailableIpsListOK) GetPayload() []*models.AvailableIP { return o.Payload } -func (o *IpamPrefixesAvailableIpsReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { +func (o *IpamPrefixesAvailableIpsListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { // response payload if err := consumer.Consume(response.Body(), &o.Payload); err != nil && err != io.EOF { diff --git a/netbox/client/ipam/ipam_prefixes_available_prefixes_create_responses.go b/netbox/client/ipam/ipam_prefixes_available_prefixes_create_responses.go index 2fbf7ba1..299b63fb 100644 --- a/netbox/client/ipam/ipam_prefixes_available_prefixes_create_responses.go +++ b/netbox/client/ipam/ipam_prefixes_available_prefixes_create_responses.go @@ -59,22 +59,20 @@ func NewIpamPrefixesAvailablePrefixesCreateCreated() *IpamPrefixesAvailablePrefi IpamPrefixesAvailablePrefixesCreateCreated ipam prefixes available prefixes create created */ type IpamPrefixesAvailablePrefixesCreateCreated struct { - Payload *models.Prefix + Payload []*models.Prefix } func (o *IpamPrefixesAvailablePrefixesCreateCreated) Error() string { return fmt.Sprintf("[POST /ipam/prefixes/{id}/available-prefixes/][%d] ipamPrefixesAvailablePrefixesCreateCreated %+v", 201, o.Payload) } -func (o *IpamPrefixesAvailablePrefixesCreateCreated) GetPayload() *models.Prefix { +func (o *IpamPrefixesAvailablePrefixesCreateCreated) GetPayload() []*models.Prefix { return o.Payload } func (o *IpamPrefixesAvailablePrefixesCreateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { - o.Payload = new(models.Prefix) - // response payload - if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + if err := consumer.Consume(response.Body(), &o.Payload); err != nil && err != io.EOF { return err } diff --git a/netbox/client/ipam/ipam_prefixes_available_prefixes_read_parameters.go b/netbox/client/ipam/ipam_prefixes_available_prefixes_list_parameters.go similarity index 55% rename from netbox/client/ipam/ipam_prefixes_available_prefixes_read_parameters.go rename to netbox/client/ipam/ipam_prefixes_available_prefixes_list_parameters.go index 0771213e..1d13c281 100644 --- a/netbox/client/ipam/ipam_prefixes_available_prefixes_read_parameters.go +++ b/netbox/client/ipam/ipam_prefixes_available_prefixes_list_parameters.go @@ -32,48 +32,48 @@ import ( "github.com/go-openapi/swag" ) -// NewIpamPrefixesAvailablePrefixesReadParams creates a new IpamPrefixesAvailablePrefixesReadParams object, +// NewIpamPrefixesAvailablePrefixesListParams creates a new IpamPrefixesAvailablePrefixesListParams object, // with the default timeout for this client. // // Default values are not hydrated, since defaults are normally applied by the API server side. // // To enforce default values in parameter, use SetDefaults or WithDefaults. -func NewIpamPrefixesAvailablePrefixesReadParams() *IpamPrefixesAvailablePrefixesReadParams { - return &IpamPrefixesAvailablePrefixesReadParams{ +func NewIpamPrefixesAvailablePrefixesListParams() *IpamPrefixesAvailablePrefixesListParams { + return &IpamPrefixesAvailablePrefixesListParams{ timeout: cr.DefaultTimeout, } } -// NewIpamPrefixesAvailablePrefixesReadParamsWithTimeout creates a new IpamPrefixesAvailablePrefixesReadParams object +// NewIpamPrefixesAvailablePrefixesListParamsWithTimeout creates a new IpamPrefixesAvailablePrefixesListParams object // with the ability to set a timeout on a request. -func NewIpamPrefixesAvailablePrefixesReadParamsWithTimeout(timeout time.Duration) *IpamPrefixesAvailablePrefixesReadParams { - return &IpamPrefixesAvailablePrefixesReadParams{ +func NewIpamPrefixesAvailablePrefixesListParamsWithTimeout(timeout time.Duration) *IpamPrefixesAvailablePrefixesListParams { + return &IpamPrefixesAvailablePrefixesListParams{ timeout: timeout, } } -// NewIpamPrefixesAvailablePrefixesReadParamsWithContext creates a new IpamPrefixesAvailablePrefixesReadParams object +// NewIpamPrefixesAvailablePrefixesListParamsWithContext creates a new IpamPrefixesAvailablePrefixesListParams object // with the ability to set a context for a request. -func NewIpamPrefixesAvailablePrefixesReadParamsWithContext(ctx context.Context) *IpamPrefixesAvailablePrefixesReadParams { - return &IpamPrefixesAvailablePrefixesReadParams{ +func NewIpamPrefixesAvailablePrefixesListParamsWithContext(ctx context.Context) *IpamPrefixesAvailablePrefixesListParams { + return &IpamPrefixesAvailablePrefixesListParams{ Context: ctx, } } -// NewIpamPrefixesAvailablePrefixesReadParamsWithHTTPClient creates a new IpamPrefixesAvailablePrefixesReadParams object +// NewIpamPrefixesAvailablePrefixesListParamsWithHTTPClient creates a new IpamPrefixesAvailablePrefixesListParams object // with the ability to set a custom HTTPClient for a request. -func NewIpamPrefixesAvailablePrefixesReadParamsWithHTTPClient(client *http.Client) *IpamPrefixesAvailablePrefixesReadParams { - return &IpamPrefixesAvailablePrefixesReadParams{ +func NewIpamPrefixesAvailablePrefixesListParamsWithHTTPClient(client *http.Client) *IpamPrefixesAvailablePrefixesListParams { + return &IpamPrefixesAvailablePrefixesListParams{ HTTPClient: client, } } -/* IpamPrefixesAvailablePrefixesReadParams contains all the parameters to send to the API endpoint - for the ipam prefixes available prefixes read operation. +/* IpamPrefixesAvailablePrefixesListParams contains all the parameters to send to the API endpoint + for the ipam prefixes available prefixes list operation. Typically these are written to a http.Request. */ -type IpamPrefixesAvailablePrefixesReadParams struct { +type IpamPrefixesAvailablePrefixesListParams struct { /* ID. @@ -86,67 +86,67 @@ type IpamPrefixesAvailablePrefixesReadParams struct { HTTPClient *http.Client } -// WithDefaults hydrates default values in the ipam prefixes available prefixes read params (not the query body). +// WithDefaults hydrates default values in the ipam prefixes available prefixes list params (not the query body). // // All values with no default are reset to their zero value. -func (o *IpamPrefixesAvailablePrefixesReadParams) WithDefaults() *IpamPrefixesAvailablePrefixesReadParams { +func (o *IpamPrefixesAvailablePrefixesListParams) WithDefaults() *IpamPrefixesAvailablePrefixesListParams { o.SetDefaults() return o } -// SetDefaults hydrates default values in the ipam prefixes available prefixes read params (not the query body). +// SetDefaults hydrates default values in the ipam prefixes available prefixes list params (not the query body). // // All values with no default are reset to their zero value. -func (o *IpamPrefixesAvailablePrefixesReadParams) SetDefaults() { +func (o *IpamPrefixesAvailablePrefixesListParams) SetDefaults() { // no default values defined for this parameter } -// WithTimeout adds the timeout to the ipam prefixes available prefixes read params -func (o *IpamPrefixesAvailablePrefixesReadParams) WithTimeout(timeout time.Duration) *IpamPrefixesAvailablePrefixesReadParams { +// WithTimeout adds the timeout to the ipam prefixes available prefixes list params +func (o *IpamPrefixesAvailablePrefixesListParams) WithTimeout(timeout time.Duration) *IpamPrefixesAvailablePrefixesListParams { o.SetTimeout(timeout) return o } -// SetTimeout adds the timeout to the ipam prefixes available prefixes read params -func (o *IpamPrefixesAvailablePrefixesReadParams) SetTimeout(timeout time.Duration) { +// SetTimeout adds the timeout to the ipam prefixes available prefixes list params +func (o *IpamPrefixesAvailablePrefixesListParams) SetTimeout(timeout time.Duration) { o.timeout = timeout } -// WithContext adds the context to the ipam prefixes available prefixes read params -func (o *IpamPrefixesAvailablePrefixesReadParams) WithContext(ctx context.Context) *IpamPrefixesAvailablePrefixesReadParams { +// WithContext adds the context to the ipam prefixes available prefixes list params +func (o *IpamPrefixesAvailablePrefixesListParams) WithContext(ctx context.Context) *IpamPrefixesAvailablePrefixesListParams { o.SetContext(ctx) return o } -// SetContext adds the context to the ipam prefixes available prefixes read params -func (o *IpamPrefixesAvailablePrefixesReadParams) SetContext(ctx context.Context) { +// SetContext adds the context to the ipam prefixes available prefixes list params +func (o *IpamPrefixesAvailablePrefixesListParams) SetContext(ctx context.Context) { o.Context = ctx } -// WithHTTPClient adds the HTTPClient to the ipam prefixes available prefixes read params -func (o *IpamPrefixesAvailablePrefixesReadParams) WithHTTPClient(client *http.Client) *IpamPrefixesAvailablePrefixesReadParams { +// WithHTTPClient adds the HTTPClient to the ipam prefixes available prefixes list params +func (o *IpamPrefixesAvailablePrefixesListParams) WithHTTPClient(client *http.Client) *IpamPrefixesAvailablePrefixesListParams { o.SetHTTPClient(client) return o } -// SetHTTPClient adds the HTTPClient to the ipam prefixes available prefixes read params -func (o *IpamPrefixesAvailablePrefixesReadParams) SetHTTPClient(client *http.Client) { +// SetHTTPClient adds the HTTPClient to the ipam prefixes available prefixes list params +func (o *IpamPrefixesAvailablePrefixesListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } -// WithID adds the id to the ipam prefixes available prefixes read params -func (o *IpamPrefixesAvailablePrefixesReadParams) WithID(id int64) *IpamPrefixesAvailablePrefixesReadParams { +// WithID adds the id to the ipam prefixes available prefixes list params +func (o *IpamPrefixesAvailablePrefixesListParams) WithID(id int64) *IpamPrefixesAvailablePrefixesListParams { o.SetID(id) return o } -// SetID adds the id to the ipam prefixes available prefixes read params -func (o *IpamPrefixesAvailablePrefixesReadParams) SetID(id int64) { +// SetID adds the id to the ipam prefixes available prefixes list params +func (o *IpamPrefixesAvailablePrefixesListParams) SetID(id int64) { o.ID = id } // WriteToRequest writes these params to a swagger request -func (o *IpamPrefixesAvailablePrefixesReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { +func (o *IpamPrefixesAvailablePrefixesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { if err := r.SetTimeout(o.timeout); err != nil { return err diff --git a/netbox/client/ipam/ipam_prefixes_available_prefixes_read_responses.go b/netbox/client/ipam/ipam_prefixes_available_prefixes_list_responses.go similarity index 68% rename from netbox/client/ipam/ipam_prefixes_available_prefixes_read_responses.go rename to netbox/client/ipam/ipam_prefixes_available_prefixes_list_responses.go index 8028d168..239e71a4 100644 --- a/netbox/client/ipam/ipam_prefixes_available_prefixes_read_responses.go +++ b/netbox/client/ipam/ipam_prefixes_available_prefixes_list_responses.go @@ -30,16 +30,16 @@ import ( "github.com/smutel/go-netbox/netbox/models" ) -// IpamPrefixesAvailablePrefixesReadReader is a Reader for the IpamPrefixesAvailablePrefixesRead structure. -type IpamPrefixesAvailablePrefixesReadReader struct { +// IpamPrefixesAvailablePrefixesListReader is a Reader for the IpamPrefixesAvailablePrefixesList structure. +type IpamPrefixesAvailablePrefixesListReader struct { formats strfmt.Registry } // ReadResponse reads a server response into the received o. -func (o *IpamPrefixesAvailablePrefixesReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { +func (o *IpamPrefixesAvailablePrefixesListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { switch response.Code() { case 200: - result := NewIpamPrefixesAvailablePrefixesReadOK() + result := NewIpamPrefixesAvailablePrefixesListOK() if err := result.readResponse(response, consumer, o.formats); err != nil { return nil, err } @@ -49,27 +49,27 @@ func (o *IpamPrefixesAvailablePrefixesReadReader) ReadResponse(response runtime. } } -// NewIpamPrefixesAvailablePrefixesReadOK creates a IpamPrefixesAvailablePrefixesReadOK with default headers values -func NewIpamPrefixesAvailablePrefixesReadOK() *IpamPrefixesAvailablePrefixesReadOK { - return &IpamPrefixesAvailablePrefixesReadOK{} +// NewIpamPrefixesAvailablePrefixesListOK creates a IpamPrefixesAvailablePrefixesListOK with default headers values +func NewIpamPrefixesAvailablePrefixesListOK() *IpamPrefixesAvailablePrefixesListOK { + return &IpamPrefixesAvailablePrefixesListOK{} } -/* IpamPrefixesAvailablePrefixesReadOK describes a response with status code 200, with default header values. +/* IpamPrefixesAvailablePrefixesListOK describes a response with status code 200, with default header values. -IpamPrefixesAvailablePrefixesReadOK ipam prefixes available prefixes read o k +IpamPrefixesAvailablePrefixesListOK ipam prefixes available prefixes list o k */ -type IpamPrefixesAvailablePrefixesReadOK struct { +type IpamPrefixesAvailablePrefixesListOK struct { Payload []*models.AvailablePrefix } -func (o *IpamPrefixesAvailablePrefixesReadOK) Error() string { - return fmt.Sprintf("[GET /ipam/prefixes/{id}/available-prefixes/][%d] ipamPrefixesAvailablePrefixesReadOK %+v", 200, o.Payload) +func (o *IpamPrefixesAvailablePrefixesListOK) Error() string { + return fmt.Sprintf("[GET /ipam/prefixes/{id}/available-prefixes/][%d] ipamPrefixesAvailablePrefixesListOK %+v", 200, o.Payload) } -func (o *IpamPrefixesAvailablePrefixesReadOK) GetPayload() []*models.AvailablePrefix { +func (o *IpamPrefixesAvailablePrefixesListOK) GetPayload() []*models.AvailablePrefix { return o.Payload } -func (o *IpamPrefixesAvailablePrefixesReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { +func (o *IpamPrefixesAvailablePrefixesListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { // response payload if err := consumer.Consume(response.Body(), &o.Payload); err != nil && err != io.EOF { diff --git a/netbox/client/ipam/ipam_prefixes_list_parameters.go b/netbox/client/ipam/ipam_prefixes_list_parameters.go index 9b5c16b1..1f04e841 100644 --- a/netbox/client/ipam/ipam_prefixes_list_parameters.go +++ b/netbox/client/ipam/ipam_prefixes_list_parameters.go @@ -123,6 +123,39 @@ type IpamPrefixesListParams struct { // Depthn. Depthn *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // Family. Family *float64 @@ -285,6 +318,21 @@ type IpamPrefixesListParams struct { // VlanVid. VlanVid *float64 + // VlanVidGt. + VlanVidGt *float64 + + // VlanVidGte. + VlanVidGte *float64 + + // VlanVidLt. + VlanVidLt *float64 + + // VlanVidLte. + VlanVidLte *float64 + + // VlanVidn. + VlanVidn *float64 + // Vrf. Vrf *string @@ -532,6 +580,127 @@ func (o *IpamPrefixesListParams) SetDepthn(depthn *string) { o.Depthn = depthn } +// WithDescription adds the description to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithDescription(description *string) *IpamPrefixesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithDescriptionEmpty(descriptionEmpty *string) *IpamPrefixesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithDescriptionIc(descriptionIc *string) *IpamPrefixesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithDescriptionIe(descriptionIe *string) *IpamPrefixesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithDescriptionIew(descriptionIew *string) *IpamPrefixesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithDescriptionIsw(descriptionIsw *string) *IpamPrefixesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithDescriptionn(descriptionn *string) *IpamPrefixesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithDescriptionNic(descriptionNic *string) *IpamPrefixesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithDescriptionNie(descriptionNie *string) *IpamPrefixesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithDescriptionNiew(descriptionNiew *string) *IpamPrefixesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithDescriptionNisw(descriptionNisw *string) *IpamPrefixesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithFamily adds the family to the ipam prefixes list params func (o *IpamPrefixesListParams) WithFamily(family *float64) *IpamPrefixesListParams { o.SetFamily(family) @@ -1104,6 +1273,61 @@ func (o *IpamPrefixesListParams) SetVlanVid(vlanVid *float64) { o.VlanVid = vlanVid } +// WithVlanVidGt adds the vlanVidGt to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithVlanVidGt(vlanVidGt *float64) *IpamPrefixesListParams { + o.SetVlanVidGt(vlanVidGt) + return o +} + +// SetVlanVidGt adds the vlanVidGt to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetVlanVidGt(vlanVidGt *float64) { + o.VlanVidGt = vlanVidGt +} + +// WithVlanVidGte adds the vlanVidGte to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithVlanVidGte(vlanVidGte *float64) *IpamPrefixesListParams { + o.SetVlanVidGte(vlanVidGte) + return o +} + +// SetVlanVidGte adds the vlanVidGte to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetVlanVidGte(vlanVidGte *float64) { + o.VlanVidGte = vlanVidGte +} + +// WithVlanVidLt adds the vlanVidLt to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithVlanVidLt(vlanVidLt *float64) *IpamPrefixesListParams { + o.SetVlanVidLt(vlanVidLt) + return o +} + +// SetVlanVidLt adds the vlanVidLt to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetVlanVidLt(vlanVidLt *float64) { + o.VlanVidLt = vlanVidLt +} + +// WithVlanVidLte adds the vlanVidLte to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithVlanVidLte(vlanVidLte *float64) *IpamPrefixesListParams { + o.SetVlanVidLte(vlanVidLte) + return o +} + +// SetVlanVidLte adds the vlanVidLte to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetVlanVidLte(vlanVidLte *float64) { + o.VlanVidLte = vlanVidLte +} + +// WithVlanVidn adds the vlanVidn to the ipam prefixes list params +func (o *IpamPrefixesListParams) WithVlanVidn(vlanVidn *float64) *IpamPrefixesListParams { + o.SetVlanVidn(vlanVidn) + return o +} + +// SetVlanVidn adds the vlanVidN to the ipam prefixes list params +func (o *IpamPrefixesListParams) SetVlanVidn(vlanVidn *float64) { + o.VlanVidn = vlanVidn +} + // WithVrf adds the vrf to the ipam prefixes list params func (o *IpamPrefixesListParams) WithVrf(vrf *string) *IpamPrefixesListParams { o.SetVrf(vrf) @@ -1450,6 +1674,193 @@ func (o *IpamPrefixesListParams) WriteToRequest(r runtime.ClientRequest, reg str } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.Family != nil { // query param family @@ -2334,6 +2745,91 @@ func (o *IpamPrefixesListParams) WriteToRequest(r runtime.ClientRequest, reg str } } + if o.VlanVidGt != nil { + + // query param vlan_vid__gt + var qrVlanVidGt float64 + + if o.VlanVidGt != nil { + qrVlanVidGt = *o.VlanVidGt + } + qVlanVidGt := swag.FormatFloat64(qrVlanVidGt) + if qVlanVidGt != "" { + + if err := r.SetQueryParam("vlan_vid__gt", qVlanVidGt); err != nil { + return err + } + } + } + + if o.VlanVidGte != nil { + + // query param vlan_vid__gte + var qrVlanVidGte float64 + + if o.VlanVidGte != nil { + qrVlanVidGte = *o.VlanVidGte + } + qVlanVidGte := swag.FormatFloat64(qrVlanVidGte) + if qVlanVidGte != "" { + + if err := r.SetQueryParam("vlan_vid__gte", qVlanVidGte); err != nil { + return err + } + } + } + + if o.VlanVidLt != nil { + + // query param vlan_vid__lt + var qrVlanVidLt float64 + + if o.VlanVidLt != nil { + qrVlanVidLt = *o.VlanVidLt + } + qVlanVidLt := swag.FormatFloat64(qrVlanVidLt) + if qVlanVidLt != "" { + + if err := r.SetQueryParam("vlan_vid__lt", qVlanVidLt); err != nil { + return err + } + } + } + + if o.VlanVidLte != nil { + + // query param vlan_vid__lte + var qrVlanVidLte float64 + + if o.VlanVidLte != nil { + qrVlanVidLte = *o.VlanVidLte + } + qVlanVidLte := swag.FormatFloat64(qrVlanVidLte) + if qVlanVidLte != "" { + + if err := r.SetQueryParam("vlan_vid__lte", qVlanVidLte); err != nil { + return err + } + } + } + + if o.VlanVidn != nil { + + // query param vlan_vid__n + var qrVlanVidn float64 + + if o.VlanVidn != nil { + qrVlanVidn = *o.VlanVidn + } + qVlanVidn := swag.FormatFloat64(qrVlanVidn) + if qVlanVidn != "" { + + if err := r.SetQueryParam("vlan_vid__n", qVlanVidn); err != nil { + return err + } + } + } + if o.Vrf != nil { // query param vrf diff --git a/netbox/client/ipam/ipam_rirs_list_parameters.go b/netbox/client/ipam/ipam_rirs_list_parameters.go index 62ebb49c..184677dc 100644 --- a/netbox/client/ipam/ipam_rirs_list_parameters.go +++ b/netbox/client/ipam/ipam_rirs_list_parameters.go @@ -228,6 +228,12 @@ type IpamRirsListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -820,6 +826,28 @@ func (o *IpamRirsListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the ipam rirs list params +func (o *IpamRirsListParams) WithTag(tag *string) *IpamRirsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the ipam rirs list params +func (o *IpamRirsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the ipam rirs list params +func (o *IpamRirsListParams) WithTagn(tagn *string) *IpamRirsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the ipam rirs list params +func (o *IpamRirsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *IpamRirsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -1661,6 +1689,40 @@ func (o *IpamRirsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt. } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/ipam/ipam_roles_list_parameters.go b/netbox/client/ipam/ipam_roles_list_parameters.go index 91a0b260..8558c90c 100644 --- a/netbox/client/ipam/ipam_roles_list_parameters.go +++ b/netbox/client/ipam/ipam_roles_list_parameters.go @@ -84,6 +84,39 @@ type IpamRolesListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // ID. ID *string @@ -192,6 +225,12 @@ type IpamRolesListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -278,6 +317,127 @@ func (o *IpamRolesListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the ipam roles list params +func (o *IpamRolesListParams) WithDescription(description *string) *IpamRolesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the ipam roles list params +func (o *IpamRolesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the ipam roles list params +func (o *IpamRolesListParams) WithDescriptionEmpty(descriptionEmpty *string) *IpamRolesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the ipam roles list params +func (o *IpamRolesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the ipam roles list params +func (o *IpamRolesListParams) WithDescriptionIc(descriptionIc *string) *IpamRolesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the ipam roles list params +func (o *IpamRolesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the ipam roles list params +func (o *IpamRolesListParams) WithDescriptionIe(descriptionIe *string) *IpamRolesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the ipam roles list params +func (o *IpamRolesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the ipam roles list params +func (o *IpamRolesListParams) WithDescriptionIew(descriptionIew *string) *IpamRolesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the ipam roles list params +func (o *IpamRolesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the ipam roles list params +func (o *IpamRolesListParams) WithDescriptionIsw(descriptionIsw *string) *IpamRolesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the ipam roles list params +func (o *IpamRolesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the ipam roles list params +func (o *IpamRolesListParams) WithDescriptionn(descriptionn *string) *IpamRolesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the ipam roles list params +func (o *IpamRolesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the ipam roles list params +func (o *IpamRolesListParams) WithDescriptionNic(descriptionNic *string) *IpamRolesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the ipam roles list params +func (o *IpamRolesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the ipam roles list params +func (o *IpamRolesListParams) WithDescriptionNie(descriptionNie *string) *IpamRolesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the ipam roles list params +func (o *IpamRolesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the ipam roles list params +func (o *IpamRolesListParams) WithDescriptionNiew(descriptionNiew *string) *IpamRolesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the ipam roles list params +func (o *IpamRolesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the ipam roles list params +func (o *IpamRolesListParams) WithDescriptionNisw(descriptionNisw *string) *IpamRolesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the ipam roles list params +func (o *IpamRolesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithID adds the id to the ipam roles list params func (o *IpamRolesListParams) WithID(id *string) *IpamRolesListParams { o.SetID(id) @@ -652,6 +812,28 @@ func (o *IpamRolesListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the ipam roles list params +func (o *IpamRolesListParams) WithTag(tag *string) *IpamRolesListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the ipam roles list params +func (o *IpamRolesListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the ipam roles list params +func (o *IpamRolesListParams) WithTagn(tagn *string) *IpamRolesListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the ipam roles list params +func (o *IpamRolesListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *IpamRolesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -711,6 +893,193 @@ func (o *IpamRolesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.ID != nil { // query param id @@ -1289,6 +1658,40 @@ func (o *IpamRolesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/ipam/ipam_route_targets_list_parameters.go b/netbox/client/ipam/ipam_route_targets_list_parameters.go index 08efd713..5776aa8d 100644 --- a/netbox/client/ipam/ipam_route_targets_list_parameters.go +++ b/netbox/client/ipam/ipam_route_targets_list_parameters.go @@ -84,6 +84,39 @@ type IpamRouteTargetsListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // ExportingVrf. ExportingVrf *string @@ -299,6 +332,127 @@ func (o *IpamRouteTargetsListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the ipam route targets list params +func (o *IpamRouteTargetsListParams) WithDescription(description *string) *IpamRouteTargetsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the ipam route targets list params +func (o *IpamRouteTargetsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the ipam route targets list params +func (o *IpamRouteTargetsListParams) WithDescriptionEmpty(descriptionEmpty *string) *IpamRouteTargetsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the ipam route targets list params +func (o *IpamRouteTargetsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the ipam route targets list params +func (o *IpamRouteTargetsListParams) WithDescriptionIc(descriptionIc *string) *IpamRouteTargetsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the ipam route targets list params +func (o *IpamRouteTargetsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the ipam route targets list params +func (o *IpamRouteTargetsListParams) WithDescriptionIe(descriptionIe *string) *IpamRouteTargetsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the ipam route targets list params +func (o *IpamRouteTargetsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the ipam route targets list params +func (o *IpamRouteTargetsListParams) WithDescriptionIew(descriptionIew *string) *IpamRouteTargetsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the ipam route targets list params +func (o *IpamRouteTargetsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the ipam route targets list params +func (o *IpamRouteTargetsListParams) WithDescriptionIsw(descriptionIsw *string) *IpamRouteTargetsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the ipam route targets list params +func (o *IpamRouteTargetsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the ipam route targets list params +func (o *IpamRouteTargetsListParams) WithDescriptionn(descriptionn *string) *IpamRouteTargetsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the ipam route targets list params +func (o *IpamRouteTargetsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the ipam route targets list params +func (o *IpamRouteTargetsListParams) WithDescriptionNic(descriptionNic *string) *IpamRouteTargetsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the ipam route targets list params +func (o *IpamRouteTargetsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the ipam route targets list params +func (o *IpamRouteTargetsListParams) WithDescriptionNie(descriptionNie *string) *IpamRouteTargetsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the ipam route targets list params +func (o *IpamRouteTargetsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the ipam route targets list params +func (o *IpamRouteTargetsListParams) WithDescriptionNiew(descriptionNiew *string) *IpamRouteTargetsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the ipam route targets list params +func (o *IpamRouteTargetsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the ipam route targets list params +func (o *IpamRouteTargetsListParams) WithDescriptionNisw(descriptionNisw *string) *IpamRouteTargetsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the ipam route targets list params +func (o *IpamRouteTargetsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithExportingVrf adds the exportingVrf to the ipam route targets list params func (o *IpamRouteTargetsListParams) WithExportingVrf(exportingVrf *string) *IpamRouteTargetsListParams { o.SetExportingVrf(exportingVrf) @@ -809,6 +963,193 @@ func (o *IpamRouteTargetsListParams) WriteToRequest(r runtime.ClientRequest, reg } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.ExportingVrf != nil { // query param exporting_vrf diff --git a/netbox/client/ipam/ipam_services_list_parameters.go b/netbox/client/ipam/ipam_services_list_parameters.go index 42348e07..fd9c9890 100644 --- a/netbox/client/ipam/ipam_services_list_parameters.go +++ b/netbox/client/ipam/ipam_services_list_parameters.go @@ -84,6 +84,39 @@ type IpamServicesListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // Device. Device *string @@ -284,6 +317,127 @@ func (o *IpamServicesListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the ipam services list params +func (o *IpamServicesListParams) WithDescription(description *string) *IpamServicesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the ipam services list params +func (o *IpamServicesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the ipam services list params +func (o *IpamServicesListParams) WithDescriptionEmpty(descriptionEmpty *string) *IpamServicesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the ipam services list params +func (o *IpamServicesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the ipam services list params +func (o *IpamServicesListParams) WithDescriptionIc(descriptionIc *string) *IpamServicesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the ipam services list params +func (o *IpamServicesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the ipam services list params +func (o *IpamServicesListParams) WithDescriptionIe(descriptionIe *string) *IpamServicesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the ipam services list params +func (o *IpamServicesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the ipam services list params +func (o *IpamServicesListParams) WithDescriptionIew(descriptionIew *string) *IpamServicesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the ipam services list params +func (o *IpamServicesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the ipam services list params +func (o *IpamServicesListParams) WithDescriptionIsw(descriptionIsw *string) *IpamServicesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the ipam services list params +func (o *IpamServicesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the ipam services list params +func (o *IpamServicesListParams) WithDescriptionn(descriptionn *string) *IpamServicesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the ipam services list params +func (o *IpamServicesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the ipam services list params +func (o *IpamServicesListParams) WithDescriptionNic(descriptionNic *string) *IpamServicesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the ipam services list params +func (o *IpamServicesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the ipam services list params +func (o *IpamServicesListParams) WithDescriptionNie(descriptionNie *string) *IpamServicesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the ipam services list params +func (o *IpamServicesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the ipam services list params +func (o *IpamServicesListParams) WithDescriptionNiew(descriptionNiew *string) *IpamServicesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the ipam services list params +func (o *IpamServicesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the ipam services list params +func (o *IpamServicesListParams) WithDescriptionNisw(descriptionNisw *string) *IpamServicesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the ipam services list params +func (o *IpamServicesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithDevice adds the device to the ipam services list params func (o *IpamServicesListParams) WithDevice(device *string) *IpamServicesListParams { o.SetDevice(device) @@ -739,6 +893,193 @@ func (o *IpamServicesListParams) WriteToRequest(r runtime.ClientRequest, reg str } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.Device != nil { // query param device diff --git a/netbox/client/ipam/ipam_vlan_groups_list_parameters.go b/netbox/client/ipam/ipam_vlan_groups_list_parameters.go index 8d83c2aa..f0fbc51f 100644 --- a/netbox/client/ipam/ipam_vlan_groups_list_parameters.go +++ b/netbox/client/ipam/ipam_vlan_groups_list_parameters.go @@ -270,6 +270,12 @@ type IpamVlanGroupsListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -1016,6 +1022,28 @@ func (o *IpamVlanGroupsListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the ipam vlan groups list params +func (o *IpamVlanGroupsListParams) WithTag(tag *string) *IpamVlanGroupsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the ipam vlan groups list params +func (o *IpamVlanGroupsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the ipam vlan groups list params +func (o *IpamVlanGroupsListParams) WithTagn(tagn *string) *IpamVlanGroupsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the ipam vlan groups list params +func (o *IpamVlanGroupsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *IpamVlanGroupsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -2095,6 +2123,40 @@ func (o *IpamVlanGroupsListParams) WriteToRequest(r runtime.ClientRequest, reg s } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/ipam/ipam_vlans_list_parameters.go b/netbox/client/ipam/ipam_vlans_list_parameters.go index c2ef6259..29d70f75 100644 --- a/netbox/client/ipam/ipam_vlans_list_parameters.go +++ b/netbox/client/ipam/ipam_vlans_list_parameters.go @@ -90,6 +90,39 @@ type IpamVlansListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // Group. Group *string @@ -387,6 +420,127 @@ func (o *IpamVlansListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the ipam vlans list params +func (o *IpamVlansListParams) WithDescription(description *string) *IpamVlansListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the ipam vlans list params +func (o *IpamVlansListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the ipam vlans list params +func (o *IpamVlansListParams) WithDescriptionEmpty(descriptionEmpty *string) *IpamVlansListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the ipam vlans list params +func (o *IpamVlansListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the ipam vlans list params +func (o *IpamVlansListParams) WithDescriptionIc(descriptionIc *string) *IpamVlansListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the ipam vlans list params +func (o *IpamVlansListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the ipam vlans list params +func (o *IpamVlansListParams) WithDescriptionIe(descriptionIe *string) *IpamVlansListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the ipam vlans list params +func (o *IpamVlansListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the ipam vlans list params +func (o *IpamVlansListParams) WithDescriptionIew(descriptionIew *string) *IpamVlansListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the ipam vlans list params +func (o *IpamVlansListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the ipam vlans list params +func (o *IpamVlansListParams) WithDescriptionIsw(descriptionIsw *string) *IpamVlansListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the ipam vlans list params +func (o *IpamVlansListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the ipam vlans list params +func (o *IpamVlansListParams) WithDescriptionn(descriptionn *string) *IpamVlansListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the ipam vlans list params +func (o *IpamVlansListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the ipam vlans list params +func (o *IpamVlansListParams) WithDescriptionNic(descriptionNic *string) *IpamVlansListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the ipam vlans list params +func (o *IpamVlansListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the ipam vlans list params +func (o *IpamVlansListParams) WithDescriptionNie(descriptionNie *string) *IpamVlansListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the ipam vlans list params +func (o *IpamVlansListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the ipam vlans list params +func (o *IpamVlansListParams) WithDescriptionNiew(descriptionNiew *string) *IpamVlansListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the ipam vlans list params +func (o *IpamVlansListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the ipam vlans list params +func (o *IpamVlansListParams) WithDescriptionNisw(descriptionNisw *string) *IpamVlansListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the ipam vlans list params +func (o *IpamVlansListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithGroup adds the group to the ipam vlans list params func (o *IpamVlansListParams) WithGroup(group *string) *IpamVlansListParams { o.SetGroup(group) @@ -1151,6 +1305,193 @@ func (o *IpamVlansListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.Group != nil { // query param group diff --git a/netbox/client/ipam/ipam_vrfs_list_parameters.go b/netbox/client/ipam/ipam_vrfs_list_parameters.go index a7a801be..d9861488 100644 --- a/netbox/client/ipam/ipam_vrfs_list_parameters.go +++ b/netbox/client/ipam/ipam_vrfs_list_parameters.go @@ -84,6 +84,39 @@ type IpamVrfsListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // EnforceUnique. EnforceUnique *string @@ -335,6 +368,127 @@ func (o *IpamVrfsListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the ipam vrfs list params +func (o *IpamVrfsListParams) WithDescription(description *string) *IpamVrfsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the ipam vrfs list params +func (o *IpamVrfsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the ipam vrfs list params +func (o *IpamVrfsListParams) WithDescriptionEmpty(descriptionEmpty *string) *IpamVrfsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the ipam vrfs list params +func (o *IpamVrfsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the ipam vrfs list params +func (o *IpamVrfsListParams) WithDescriptionIc(descriptionIc *string) *IpamVrfsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the ipam vrfs list params +func (o *IpamVrfsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the ipam vrfs list params +func (o *IpamVrfsListParams) WithDescriptionIe(descriptionIe *string) *IpamVrfsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the ipam vrfs list params +func (o *IpamVrfsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the ipam vrfs list params +func (o *IpamVrfsListParams) WithDescriptionIew(descriptionIew *string) *IpamVrfsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the ipam vrfs list params +func (o *IpamVrfsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the ipam vrfs list params +func (o *IpamVrfsListParams) WithDescriptionIsw(descriptionIsw *string) *IpamVrfsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the ipam vrfs list params +func (o *IpamVrfsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the ipam vrfs list params +func (o *IpamVrfsListParams) WithDescriptionn(descriptionn *string) *IpamVrfsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the ipam vrfs list params +func (o *IpamVrfsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the ipam vrfs list params +func (o *IpamVrfsListParams) WithDescriptionNic(descriptionNic *string) *IpamVrfsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the ipam vrfs list params +func (o *IpamVrfsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the ipam vrfs list params +func (o *IpamVrfsListParams) WithDescriptionNie(descriptionNie *string) *IpamVrfsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the ipam vrfs list params +func (o *IpamVrfsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the ipam vrfs list params +func (o *IpamVrfsListParams) WithDescriptionNiew(descriptionNiew *string) *IpamVrfsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the ipam vrfs list params +func (o *IpamVrfsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the ipam vrfs list params +func (o *IpamVrfsListParams) WithDescriptionNisw(descriptionNisw *string) *IpamVrfsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the ipam vrfs list params +func (o *IpamVrfsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithEnforceUnique adds the enforceUnique to the ipam vrfs list params func (o *IpamVrfsListParams) WithEnforceUnique(enforceUnique *string) *IpamVrfsListParams { o.SetEnforceUnique(enforceUnique) @@ -977,6 +1131,193 @@ func (o *IpamVrfsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt. } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.EnforceUnique != nil { // query param enforce_unique diff --git a/netbox/client/net_box_api_client.go b/netbox/client/net_box_api_client.go index e8ee65e2..65100983 100644 --- a/netbox/client/net_box_api_client.go +++ b/netbox/client/net_box_api_client.go @@ -33,6 +33,7 @@ import ( "github.com/smutel/go-netbox/netbox/client/tenancy" "github.com/smutel/go-netbox/netbox/client/users" "github.com/smutel/go-netbox/netbox/client/virtualization" + "github.com/smutel/go-netbox/netbox/client/wireless" ) // Default net box API HTTP client. @@ -85,6 +86,7 @@ func New(transport runtime.ClientTransport, formats strfmt.Registry) *NetBoxAPI cli.Tenancy = tenancy.New(transport, formats) cli.Users = users.New(transport, formats) cli.Virtualization = virtualization.New(transport, formats) + cli.Wireless = wireless.New(transport, formats) return cli } @@ -145,6 +147,8 @@ type NetBoxAPI struct { Virtualization virtualization.ClientService + Wireless wireless.ClientService + Transport runtime.ClientTransport } @@ -159,4 +163,5 @@ func (c *NetBoxAPI) SetTransport(transport runtime.ClientTransport) { c.Tenancy.SetTransport(transport) c.Users.SetTransport(transport) c.Virtualization.SetTransport(transport) + c.Wireless.SetTransport(transport) } diff --git a/netbox/client/tenancy/tenancy_client.go b/netbox/client/tenancy/tenancy_client.go index e4e39e8e..2330a867 100644 --- a/netbox/client/tenancy/tenancy_client.go +++ b/netbox/client/tenancy/tenancy_client.go @@ -45,6 +45,78 @@ type ClientOption func(*runtime.ClientOperation) // ClientService is the interface for Client methods type ClientService interface { + TenancyContactAssignmentsBulkDelete(params *TenancyContactAssignmentsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsBulkDeleteNoContent, error) + + TenancyContactAssignmentsBulkPartialUpdate(params *TenancyContactAssignmentsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsBulkPartialUpdateOK, error) + + TenancyContactAssignmentsBulkUpdate(params *TenancyContactAssignmentsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsBulkUpdateOK, error) + + TenancyContactAssignmentsCreate(params *TenancyContactAssignmentsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsCreateCreated, error) + + TenancyContactAssignmentsDelete(params *TenancyContactAssignmentsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsDeleteNoContent, error) + + TenancyContactAssignmentsList(params *TenancyContactAssignmentsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsListOK, error) + + TenancyContactAssignmentsPartialUpdate(params *TenancyContactAssignmentsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsPartialUpdateOK, error) + + TenancyContactAssignmentsRead(params *TenancyContactAssignmentsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsReadOK, error) + + TenancyContactAssignmentsUpdate(params *TenancyContactAssignmentsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsUpdateOK, error) + + TenancyContactGroupsBulkDelete(params *TenancyContactGroupsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsBulkDeleteNoContent, error) + + TenancyContactGroupsBulkPartialUpdate(params *TenancyContactGroupsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsBulkPartialUpdateOK, error) + + TenancyContactGroupsBulkUpdate(params *TenancyContactGroupsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsBulkUpdateOK, error) + + TenancyContactGroupsCreate(params *TenancyContactGroupsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsCreateCreated, error) + + TenancyContactGroupsDelete(params *TenancyContactGroupsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsDeleteNoContent, error) + + TenancyContactGroupsList(params *TenancyContactGroupsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsListOK, error) + + TenancyContactGroupsPartialUpdate(params *TenancyContactGroupsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsPartialUpdateOK, error) + + TenancyContactGroupsRead(params *TenancyContactGroupsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsReadOK, error) + + TenancyContactGroupsUpdate(params *TenancyContactGroupsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsUpdateOK, error) + + TenancyContactRolesBulkDelete(params *TenancyContactRolesBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesBulkDeleteNoContent, error) + + TenancyContactRolesBulkPartialUpdate(params *TenancyContactRolesBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesBulkPartialUpdateOK, error) + + TenancyContactRolesBulkUpdate(params *TenancyContactRolesBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesBulkUpdateOK, error) + + TenancyContactRolesCreate(params *TenancyContactRolesCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesCreateCreated, error) + + TenancyContactRolesDelete(params *TenancyContactRolesDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesDeleteNoContent, error) + + TenancyContactRolesList(params *TenancyContactRolesListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesListOK, error) + + TenancyContactRolesPartialUpdate(params *TenancyContactRolesPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesPartialUpdateOK, error) + + TenancyContactRolesRead(params *TenancyContactRolesReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesReadOK, error) + + TenancyContactRolesUpdate(params *TenancyContactRolesUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesUpdateOK, error) + + TenancyContactsBulkDelete(params *TenancyContactsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsBulkDeleteNoContent, error) + + TenancyContactsBulkPartialUpdate(params *TenancyContactsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsBulkPartialUpdateOK, error) + + TenancyContactsBulkUpdate(params *TenancyContactsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsBulkUpdateOK, error) + + TenancyContactsCreate(params *TenancyContactsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsCreateCreated, error) + + TenancyContactsDelete(params *TenancyContactsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsDeleteNoContent, error) + + TenancyContactsList(params *TenancyContactsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsListOK, error) + + TenancyContactsPartialUpdate(params *TenancyContactsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsPartialUpdateOK, error) + + TenancyContactsRead(params *TenancyContactsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsReadOK, error) + + TenancyContactsUpdate(params *TenancyContactsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsUpdateOK, error) + TenancyTenantGroupsBulkDelete(params *TenancyTenantGroupsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyTenantGroupsBulkDeleteNoContent, error) TenancyTenantGroupsBulkPartialUpdate(params *TenancyTenantGroupsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyTenantGroupsBulkPartialUpdateOK, error) @@ -84,6 +156,1410 @@ type ClientService interface { SetTransport(transport runtime.ClientTransport) } +/* + TenancyContactAssignmentsBulkDelete tenancy contact assignments bulk delete API +*/ +func (a *Client) TenancyContactAssignmentsBulkDelete(params *TenancyContactAssignmentsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsBulkDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactAssignmentsBulkDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-assignments_bulk_delete", + Method: "DELETE", + PathPattern: "/tenancy/contact-assignments/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactAssignmentsBulkDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactAssignmentsBulkDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-assignments_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactAssignmentsBulkPartialUpdate tenancy contact assignments bulk partial update API +*/ +func (a *Client) TenancyContactAssignmentsBulkPartialUpdate(params *TenancyContactAssignmentsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsBulkPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactAssignmentsBulkPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-assignments_bulk_partial_update", + Method: "PATCH", + PathPattern: "/tenancy/contact-assignments/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactAssignmentsBulkPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactAssignmentsBulkPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-assignments_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactAssignmentsBulkUpdate tenancy contact assignments bulk update API +*/ +func (a *Client) TenancyContactAssignmentsBulkUpdate(params *TenancyContactAssignmentsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsBulkUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactAssignmentsBulkUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-assignments_bulk_update", + Method: "PUT", + PathPattern: "/tenancy/contact-assignments/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactAssignmentsBulkUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactAssignmentsBulkUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-assignments_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactAssignmentsCreate tenancy contact assignments create API +*/ +func (a *Client) TenancyContactAssignmentsCreate(params *TenancyContactAssignmentsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactAssignmentsCreateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-assignments_create", + Method: "POST", + PathPattern: "/tenancy/contact-assignments/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactAssignmentsCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactAssignmentsCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-assignments_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactAssignmentsDelete tenancy contact assignments delete API +*/ +func (a *Client) TenancyContactAssignmentsDelete(params *TenancyContactAssignmentsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactAssignmentsDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-assignments_delete", + Method: "DELETE", + PathPattern: "/tenancy/contact-assignments/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactAssignmentsDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactAssignmentsDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-assignments_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactAssignmentsList Overrides ListModelMixin to allow processing ExportTemplates. +*/ +func (a *Client) TenancyContactAssignmentsList(params *TenancyContactAssignmentsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsListOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactAssignmentsListParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-assignments_list", + Method: "GET", + PathPattern: "/tenancy/contact-assignments/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactAssignmentsListReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactAssignmentsListOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-assignments_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactAssignmentsPartialUpdate tenancy contact assignments partial update API +*/ +func (a *Client) TenancyContactAssignmentsPartialUpdate(params *TenancyContactAssignmentsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactAssignmentsPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-assignments_partial_update", + Method: "PATCH", + PathPattern: "/tenancy/contact-assignments/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactAssignmentsPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactAssignmentsPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-assignments_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactAssignmentsRead tenancy contact assignments read API +*/ +func (a *Client) TenancyContactAssignmentsRead(params *TenancyContactAssignmentsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsReadOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactAssignmentsReadParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-assignments_read", + Method: "GET", + PathPattern: "/tenancy/contact-assignments/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactAssignmentsReadReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactAssignmentsReadOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-assignments_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactAssignmentsUpdate tenancy contact assignments update API +*/ +func (a *Client) TenancyContactAssignmentsUpdate(params *TenancyContactAssignmentsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactAssignmentsUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactAssignmentsUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-assignments_update", + Method: "PUT", + PathPattern: "/tenancy/contact-assignments/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactAssignmentsUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactAssignmentsUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-assignments_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactGroupsBulkDelete tenancy contact groups bulk delete API +*/ +func (a *Client) TenancyContactGroupsBulkDelete(params *TenancyContactGroupsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsBulkDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactGroupsBulkDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-groups_bulk_delete", + Method: "DELETE", + PathPattern: "/tenancy/contact-groups/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactGroupsBulkDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactGroupsBulkDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-groups_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactGroupsBulkPartialUpdate tenancy contact groups bulk partial update API +*/ +func (a *Client) TenancyContactGroupsBulkPartialUpdate(params *TenancyContactGroupsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsBulkPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactGroupsBulkPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-groups_bulk_partial_update", + Method: "PATCH", + PathPattern: "/tenancy/contact-groups/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactGroupsBulkPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactGroupsBulkPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-groups_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactGroupsBulkUpdate tenancy contact groups bulk update API +*/ +func (a *Client) TenancyContactGroupsBulkUpdate(params *TenancyContactGroupsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsBulkUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactGroupsBulkUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-groups_bulk_update", + Method: "PUT", + PathPattern: "/tenancy/contact-groups/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactGroupsBulkUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactGroupsBulkUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-groups_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactGroupsCreate tenancy contact groups create API +*/ +func (a *Client) TenancyContactGroupsCreate(params *TenancyContactGroupsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactGroupsCreateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-groups_create", + Method: "POST", + PathPattern: "/tenancy/contact-groups/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactGroupsCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactGroupsCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-groups_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactGroupsDelete tenancy contact groups delete API +*/ +func (a *Client) TenancyContactGroupsDelete(params *TenancyContactGroupsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactGroupsDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-groups_delete", + Method: "DELETE", + PathPattern: "/tenancy/contact-groups/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactGroupsDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactGroupsDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-groups_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactGroupsList Overrides ListModelMixin to allow processing ExportTemplates. +*/ +func (a *Client) TenancyContactGroupsList(params *TenancyContactGroupsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsListOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactGroupsListParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-groups_list", + Method: "GET", + PathPattern: "/tenancy/contact-groups/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactGroupsListReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactGroupsListOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-groups_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactGroupsPartialUpdate tenancy contact groups partial update API +*/ +func (a *Client) TenancyContactGroupsPartialUpdate(params *TenancyContactGroupsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactGroupsPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-groups_partial_update", + Method: "PATCH", + PathPattern: "/tenancy/contact-groups/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactGroupsPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactGroupsPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-groups_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactGroupsRead tenancy contact groups read API +*/ +func (a *Client) TenancyContactGroupsRead(params *TenancyContactGroupsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsReadOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactGroupsReadParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-groups_read", + Method: "GET", + PathPattern: "/tenancy/contact-groups/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactGroupsReadReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactGroupsReadOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-groups_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactGroupsUpdate tenancy contact groups update API +*/ +func (a *Client) TenancyContactGroupsUpdate(params *TenancyContactGroupsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactGroupsUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactGroupsUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-groups_update", + Method: "PUT", + PathPattern: "/tenancy/contact-groups/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactGroupsUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactGroupsUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-groups_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactRolesBulkDelete tenancy contact roles bulk delete API +*/ +func (a *Client) TenancyContactRolesBulkDelete(params *TenancyContactRolesBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesBulkDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactRolesBulkDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-roles_bulk_delete", + Method: "DELETE", + PathPattern: "/tenancy/contact-roles/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactRolesBulkDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactRolesBulkDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-roles_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactRolesBulkPartialUpdate tenancy contact roles bulk partial update API +*/ +func (a *Client) TenancyContactRolesBulkPartialUpdate(params *TenancyContactRolesBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesBulkPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactRolesBulkPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-roles_bulk_partial_update", + Method: "PATCH", + PathPattern: "/tenancy/contact-roles/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactRolesBulkPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactRolesBulkPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-roles_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactRolesBulkUpdate tenancy contact roles bulk update API +*/ +func (a *Client) TenancyContactRolesBulkUpdate(params *TenancyContactRolesBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesBulkUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactRolesBulkUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-roles_bulk_update", + Method: "PUT", + PathPattern: "/tenancy/contact-roles/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactRolesBulkUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactRolesBulkUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-roles_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactRolesCreate tenancy contact roles create API +*/ +func (a *Client) TenancyContactRolesCreate(params *TenancyContactRolesCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactRolesCreateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-roles_create", + Method: "POST", + PathPattern: "/tenancy/contact-roles/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactRolesCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactRolesCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-roles_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactRolesDelete tenancy contact roles delete API +*/ +func (a *Client) TenancyContactRolesDelete(params *TenancyContactRolesDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactRolesDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-roles_delete", + Method: "DELETE", + PathPattern: "/tenancy/contact-roles/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactRolesDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactRolesDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-roles_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactRolesList Overrides ListModelMixin to allow processing ExportTemplates. +*/ +func (a *Client) TenancyContactRolesList(params *TenancyContactRolesListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesListOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactRolesListParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-roles_list", + Method: "GET", + PathPattern: "/tenancy/contact-roles/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactRolesListReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactRolesListOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-roles_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactRolesPartialUpdate tenancy contact roles partial update API +*/ +func (a *Client) TenancyContactRolesPartialUpdate(params *TenancyContactRolesPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactRolesPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-roles_partial_update", + Method: "PATCH", + PathPattern: "/tenancy/contact-roles/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactRolesPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactRolesPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-roles_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactRolesRead tenancy contact roles read API +*/ +func (a *Client) TenancyContactRolesRead(params *TenancyContactRolesReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesReadOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactRolesReadParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-roles_read", + Method: "GET", + PathPattern: "/tenancy/contact-roles/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactRolesReadReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactRolesReadOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-roles_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactRolesUpdate tenancy contact roles update API +*/ +func (a *Client) TenancyContactRolesUpdate(params *TenancyContactRolesUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactRolesUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactRolesUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contact-roles_update", + Method: "PUT", + PathPattern: "/tenancy/contact-roles/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactRolesUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactRolesUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contact-roles_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactsBulkDelete tenancy contacts bulk delete API +*/ +func (a *Client) TenancyContactsBulkDelete(params *TenancyContactsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsBulkDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactsBulkDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contacts_bulk_delete", + Method: "DELETE", + PathPattern: "/tenancy/contacts/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactsBulkDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactsBulkDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contacts_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactsBulkPartialUpdate tenancy contacts bulk partial update API +*/ +func (a *Client) TenancyContactsBulkPartialUpdate(params *TenancyContactsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsBulkPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactsBulkPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contacts_bulk_partial_update", + Method: "PATCH", + PathPattern: "/tenancy/contacts/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactsBulkPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactsBulkPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contacts_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactsBulkUpdate tenancy contacts bulk update API +*/ +func (a *Client) TenancyContactsBulkUpdate(params *TenancyContactsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsBulkUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactsBulkUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contacts_bulk_update", + Method: "PUT", + PathPattern: "/tenancy/contacts/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactsBulkUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactsBulkUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contacts_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactsCreate tenancy contacts create API +*/ +func (a *Client) TenancyContactsCreate(params *TenancyContactsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactsCreateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contacts_create", + Method: "POST", + PathPattern: "/tenancy/contacts/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactsCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactsCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contacts_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactsDelete tenancy contacts delete API +*/ +func (a *Client) TenancyContactsDelete(params *TenancyContactsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactsDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contacts_delete", + Method: "DELETE", + PathPattern: "/tenancy/contacts/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactsDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactsDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contacts_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactsList Overrides ListModelMixin to allow processing ExportTemplates. +*/ +func (a *Client) TenancyContactsList(params *TenancyContactsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsListOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactsListParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contacts_list", + Method: "GET", + PathPattern: "/tenancy/contacts/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactsListReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactsListOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contacts_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactsPartialUpdate tenancy contacts partial update API +*/ +func (a *Client) TenancyContactsPartialUpdate(params *TenancyContactsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactsPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contacts_partial_update", + Method: "PATCH", + PathPattern: "/tenancy/contacts/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactsPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactsPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contacts_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactsRead tenancy contacts read API +*/ +func (a *Client) TenancyContactsRead(params *TenancyContactsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsReadOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactsReadParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contacts_read", + Method: "GET", + PathPattern: "/tenancy/contacts/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactsReadReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactsReadOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contacts_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + TenancyContactsUpdate tenancy contacts update API +*/ +func (a *Client) TenancyContactsUpdate(params *TenancyContactsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*TenancyContactsUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewTenancyContactsUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "tenancy_contacts_update", + Method: "PUT", + PathPattern: "/tenancy/contacts/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &TenancyContactsUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*TenancyContactsUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for tenancy_contacts_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + /* TenancyTenantGroupsBulkDelete tenancy tenant groups bulk delete API */ diff --git a/netbox/client/tenancy/tenancy_contact_assignments_bulk_delete_parameters.go b/netbox/client/tenancy/tenancy_contact_assignments_bulk_delete_parameters.go new file mode 100644 index 00000000..c554b0ad --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_bulk_delete_parameters.go @@ -0,0 +1,141 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewTenancyContactAssignmentsBulkDeleteParams creates a new TenancyContactAssignmentsBulkDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactAssignmentsBulkDeleteParams() *TenancyContactAssignmentsBulkDeleteParams { + return &TenancyContactAssignmentsBulkDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactAssignmentsBulkDeleteParamsWithTimeout creates a new TenancyContactAssignmentsBulkDeleteParams object +// with the ability to set a timeout on a request. +func NewTenancyContactAssignmentsBulkDeleteParamsWithTimeout(timeout time.Duration) *TenancyContactAssignmentsBulkDeleteParams { + return &TenancyContactAssignmentsBulkDeleteParams{ + timeout: timeout, + } +} + +// NewTenancyContactAssignmentsBulkDeleteParamsWithContext creates a new TenancyContactAssignmentsBulkDeleteParams object +// with the ability to set a context for a request. +func NewTenancyContactAssignmentsBulkDeleteParamsWithContext(ctx context.Context) *TenancyContactAssignmentsBulkDeleteParams { + return &TenancyContactAssignmentsBulkDeleteParams{ + Context: ctx, + } +} + +// NewTenancyContactAssignmentsBulkDeleteParamsWithHTTPClient creates a new TenancyContactAssignmentsBulkDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactAssignmentsBulkDeleteParamsWithHTTPClient(client *http.Client) *TenancyContactAssignmentsBulkDeleteParams { + return &TenancyContactAssignmentsBulkDeleteParams{ + HTTPClient: client, + } +} + +/* TenancyContactAssignmentsBulkDeleteParams contains all the parameters to send to the API endpoint + for the tenancy contact assignments bulk delete operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactAssignmentsBulkDeleteParams struct { + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact assignments bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsBulkDeleteParams) WithDefaults() *TenancyContactAssignmentsBulkDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact assignments bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsBulkDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact assignments bulk delete params +func (o *TenancyContactAssignmentsBulkDeleteParams) WithTimeout(timeout time.Duration) *TenancyContactAssignmentsBulkDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact assignments bulk delete params +func (o *TenancyContactAssignmentsBulkDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact assignments bulk delete params +func (o *TenancyContactAssignmentsBulkDeleteParams) WithContext(ctx context.Context) *TenancyContactAssignmentsBulkDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact assignments bulk delete params +func (o *TenancyContactAssignmentsBulkDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact assignments bulk delete params +func (o *TenancyContactAssignmentsBulkDeleteParams) WithHTTPClient(client *http.Client) *TenancyContactAssignmentsBulkDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact assignments bulk delete params +func (o *TenancyContactAssignmentsBulkDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactAssignmentsBulkDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_bulk_delete_responses.go b/netbox/client/tenancy/tenancy_contact_assignments_bulk_delete_responses.go new file mode 100644 index 00000000..15f5d985 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_bulk_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// TenancyContactAssignmentsBulkDeleteReader is a Reader for the TenancyContactAssignmentsBulkDelete structure. +type TenancyContactAssignmentsBulkDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactAssignmentsBulkDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewTenancyContactAssignmentsBulkDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactAssignmentsBulkDeleteNoContent creates a TenancyContactAssignmentsBulkDeleteNoContent with default headers values +func NewTenancyContactAssignmentsBulkDeleteNoContent() *TenancyContactAssignmentsBulkDeleteNoContent { + return &TenancyContactAssignmentsBulkDeleteNoContent{} +} + +/* TenancyContactAssignmentsBulkDeleteNoContent describes a response with status code 204, with default header values. + +TenancyContactAssignmentsBulkDeleteNoContent tenancy contact assignments bulk delete no content +*/ +type TenancyContactAssignmentsBulkDeleteNoContent struct { +} + +func (o *TenancyContactAssignmentsBulkDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /tenancy/contact-assignments/][%d] tenancyContactAssignmentsBulkDeleteNoContent ", 204) +} + +func (o *TenancyContactAssignmentsBulkDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_bulk_partial_update_parameters.go b/netbox/client/tenancy/tenancy_contact_assignments_bulk_partial_update_parameters.go new file mode 100644 index 00000000..80467028 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_bulk_partial_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactAssignmentsBulkPartialUpdateParams creates a new TenancyContactAssignmentsBulkPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactAssignmentsBulkPartialUpdateParams() *TenancyContactAssignmentsBulkPartialUpdateParams { + return &TenancyContactAssignmentsBulkPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactAssignmentsBulkPartialUpdateParamsWithTimeout creates a new TenancyContactAssignmentsBulkPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactAssignmentsBulkPartialUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactAssignmentsBulkPartialUpdateParams { + return &TenancyContactAssignmentsBulkPartialUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactAssignmentsBulkPartialUpdateParamsWithContext creates a new TenancyContactAssignmentsBulkPartialUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactAssignmentsBulkPartialUpdateParamsWithContext(ctx context.Context) *TenancyContactAssignmentsBulkPartialUpdateParams { + return &TenancyContactAssignmentsBulkPartialUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactAssignmentsBulkPartialUpdateParamsWithHTTPClient creates a new TenancyContactAssignmentsBulkPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactAssignmentsBulkPartialUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactAssignmentsBulkPartialUpdateParams { + return &TenancyContactAssignmentsBulkPartialUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactAssignmentsBulkPartialUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact assignments bulk partial update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactAssignmentsBulkPartialUpdateParams struct { + + // Data. + Data *models.WritableContactAssignment + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact assignments bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsBulkPartialUpdateParams) WithDefaults() *TenancyContactAssignmentsBulkPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact assignments bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsBulkPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact assignments bulk partial update params +func (o *TenancyContactAssignmentsBulkPartialUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactAssignmentsBulkPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact assignments bulk partial update params +func (o *TenancyContactAssignmentsBulkPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact assignments bulk partial update params +func (o *TenancyContactAssignmentsBulkPartialUpdateParams) WithContext(ctx context.Context) *TenancyContactAssignmentsBulkPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact assignments bulk partial update params +func (o *TenancyContactAssignmentsBulkPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact assignments bulk partial update params +func (o *TenancyContactAssignmentsBulkPartialUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactAssignmentsBulkPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact assignments bulk partial update params +func (o *TenancyContactAssignmentsBulkPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact assignments bulk partial update params +func (o *TenancyContactAssignmentsBulkPartialUpdateParams) WithData(data *models.WritableContactAssignment) *TenancyContactAssignmentsBulkPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact assignments bulk partial update params +func (o *TenancyContactAssignmentsBulkPartialUpdateParams) SetData(data *models.WritableContactAssignment) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactAssignmentsBulkPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_bulk_partial_update_responses.go b/netbox/client/tenancy/tenancy_contact_assignments_bulk_partial_update_responses.go new file mode 100644 index 00000000..c89ada5d --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_bulk_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactAssignmentsBulkPartialUpdateReader is a Reader for the TenancyContactAssignmentsBulkPartialUpdate structure. +type TenancyContactAssignmentsBulkPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactAssignmentsBulkPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactAssignmentsBulkPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactAssignmentsBulkPartialUpdateOK creates a TenancyContactAssignmentsBulkPartialUpdateOK with default headers values +func NewTenancyContactAssignmentsBulkPartialUpdateOK() *TenancyContactAssignmentsBulkPartialUpdateOK { + return &TenancyContactAssignmentsBulkPartialUpdateOK{} +} + +/* TenancyContactAssignmentsBulkPartialUpdateOK describes a response with status code 200, with default header values. + +TenancyContactAssignmentsBulkPartialUpdateOK tenancy contact assignments bulk partial update o k +*/ +type TenancyContactAssignmentsBulkPartialUpdateOK struct { + Payload *models.ContactAssignment +} + +func (o *TenancyContactAssignmentsBulkPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /tenancy/contact-assignments/][%d] tenancyContactAssignmentsBulkPartialUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactAssignmentsBulkPartialUpdateOK) GetPayload() *models.ContactAssignment { + return o.Payload +} + +func (o *TenancyContactAssignmentsBulkPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_bulk_update_parameters.go b/netbox/client/tenancy/tenancy_contact_assignments_bulk_update_parameters.go new file mode 100644 index 00000000..40d0cf89 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_bulk_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactAssignmentsBulkUpdateParams creates a new TenancyContactAssignmentsBulkUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactAssignmentsBulkUpdateParams() *TenancyContactAssignmentsBulkUpdateParams { + return &TenancyContactAssignmentsBulkUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactAssignmentsBulkUpdateParamsWithTimeout creates a new TenancyContactAssignmentsBulkUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactAssignmentsBulkUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactAssignmentsBulkUpdateParams { + return &TenancyContactAssignmentsBulkUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactAssignmentsBulkUpdateParamsWithContext creates a new TenancyContactAssignmentsBulkUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactAssignmentsBulkUpdateParamsWithContext(ctx context.Context) *TenancyContactAssignmentsBulkUpdateParams { + return &TenancyContactAssignmentsBulkUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactAssignmentsBulkUpdateParamsWithHTTPClient creates a new TenancyContactAssignmentsBulkUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactAssignmentsBulkUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactAssignmentsBulkUpdateParams { + return &TenancyContactAssignmentsBulkUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactAssignmentsBulkUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact assignments bulk update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactAssignmentsBulkUpdateParams struct { + + // Data. + Data *models.WritableContactAssignment + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact assignments bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsBulkUpdateParams) WithDefaults() *TenancyContactAssignmentsBulkUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact assignments bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsBulkUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact assignments bulk update params +func (o *TenancyContactAssignmentsBulkUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactAssignmentsBulkUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact assignments bulk update params +func (o *TenancyContactAssignmentsBulkUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact assignments bulk update params +func (o *TenancyContactAssignmentsBulkUpdateParams) WithContext(ctx context.Context) *TenancyContactAssignmentsBulkUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact assignments bulk update params +func (o *TenancyContactAssignmentsBulkUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact assignments bulk update params +func (o *TenancyContactAssignmentsBulkUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactAssignmentsBulkUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact assignments bulk update params +func (o *TenancyContactAssignmentsBulkUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact assignments bulk update params +func (o *TenancyContactAssignmentsBulkUpdateParams) WithData(data *models.WritableContactAssignment) *TenancyContactAssignmentsBulkUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact assignments bulk update params +func (o *TenancyContactAssignmentsBulkUpdateParams) SetData(data *models.WritableContactAssignment) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactAssignmentsBulkUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_bulk_update_responses.go b/netbox/client/tenancy/tenancy_contact_assignments_bulk_update_responses.go new file mode 100644 index 00000000..b68e11da --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_bulk_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactAssignmentsBulkUpdateReader is a Reader for the TenancyContactAssignmentsBulkUpdate structure. +type TenancyContactAssignmentsBulkUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactAssignmentsBulkUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactAssignmentsBulkUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactAssignmentsBulkUpdateOK creates a TenancyContactAssignmentsBulkUpdateOK with default headers values +func NewTenancyContactAssignmentsBulkUpdateOK() *TenancyContactAssignmentsBulkUpdateOK { + return &TenancyContactAssignmentsBulkUpdateOK{} +} + +/* TenancyContactAssignmentsBulkUpdateOK describes a response with status code 200, with default header values. + +TenancyContactAssignmentsBulkUpdateOK tenancy contact assignments bulk update o k +*/ +type TenancyContactAssignmentsBulkUpdateOK struct { + Payload *models.ContactAssignment +} + +func (o *TenancyContactAssignmentsBulkUpdateOK) Error() string { + return fmt.Sprintf("[PUT /tenancy/contact-assignments/][%d] tenancyContactAssignmentsBulkUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactAssignmentsBulkUpdateOK) GetPayload() *models.ContactAssignment { + return o.Payload +} + +func (o *TenancyContactAssignmentsBulkUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_create_parameters.go b/netbox/client/tenancy/tenancy_contact_assignments_create_parameters.go new file mode 100644 index 00000000..b9bab797 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_create_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactAssignmentsCreateParams creates a new TenancyContactAssignmentsCreateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactAssignmentsCreateParams() *TenancyContactAssignmentsCreateParams { + return &TenancyContactAssignmentsCreateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactAssignmentsCreateParamsWithTimeout creates a new TenancyContactAssignmentsCreateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactAssignmentsCreateParamsWithTimeout(timeout time.Duration) *TenancyContactAssignmentsCreateParams { + return &TenancyContactAssignmentsCreateParams{ + timeout: timeout, + } +} + +// NewTenancyContactAssignmentsCreateParamsWithContext creates a new TenancyContactAssignmentsCreateParams object +// with the ability to set a context for a request. +func NewTenancyContactAssignmentsCreateParamsWithContext(ctx context.Context) *TenancyContactAssignmentsCreateParams { + return &TenancyContactAssignmentsCreateParams{ + Context: ctx, + } +} + +// NewTenancyContactAssignmentsCreateParamsWithHTTPClient creates a new TenancyContactAssignmentsCreateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactAssignmentsCreateParamsWithHTTPClient(client *http.Client) *TenancyContactAssignmentsCreateParams { + return &TenancyContactAssignmentsCreateParams{ + HTTPClient: client, + } +} + +/* TenancyContactAssignmentsCreateParams contains all the parameters to send to the API endpoint + for the tenancy contact assignments create operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactAssignmentsCreateParams struct { + + // Data. + Data *models.WritableContactAssignment + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact assignments create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsCreateParams) WithDefaults() *TenancyContactAssignmentsCreateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact assignments create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsCreateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact assignments create params +func (o *TenancyContactAssignmentsCreateParams) WithTimeout(timeout time.Duration) *TenancyContactAssignmentsCreateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact assignments create params +func (o *TenancyContactAssignmentsCreateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact assignments create params +func (o *TenancyContactAssignmentsCreateParams) WithContext(ctx context.Context) *TenancyContactAssignmentsCreateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact assignments create params +func (o *TenancyContactAssignmentsCreateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact assignments create params +func (o *TenancyContactAssignmentsCreateParams) WithHTTPClient(client *http.Client) *TenancyContactAssignmentsCreateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact assignments create params +func (o *TenancyContactAssignmentsCreateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact assignments create params +func (o *TenancyContactAssignmentsCreateParams) WithData(data *models.WritableContactAssignment) *TenancyContactAssignmentsCreateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact assignments create params +func (o *TenancyContactAssignmentsCreateParams) SetData(data *models.WritableContactAssignment) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactAssignmentsCreateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_create_responses.go b/netbox/client/tenancy/tenancy_contact_assignments_create_responses.go new file mode 100644 index 00000000..0e12c1af --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_create_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactAssignmentsCreateReader is a Reader for the TenancyContactAssignmentsCreate structure. +type TenancyContactAssignmentsCreateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactAssignmentsCreateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 201: + result := NewTenancyContactAssignmentsCreateCreated() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactAssignmentsCreateCreated creates a TenancyContactAssignmentsCreateCreated with default headers values +func NewTenancyContactAssignmentsCreateCreated() *TenancyContactAssignmentsCreateCreated { + return &TenancyContactAssignmentsCreateCreated{} +} + +/* TenancyContactAssignmentsCreateCreated describes a response with status code 201, with default header values. + +TenancyContactAssignmentsCreateCreated tenancy contact assignments create created +*/ +type TenancyContactAssignmentsCreateCreated struct { + Payload *models.ContactAssignment +} + +func (o *TenancyContactAssignmentsCreateCreated) Error() string { + return fmt.Sprintf("[POST /tenancy/contact-assignments/][%d] tenancyContactAssignmentsCreateCreated %+v", 201, o.Payload) +} +func (o *TenancyContactAssignmentsCreateCreated) GetPayload() *models.ContactAssignment { + return o.Payload +} + +func (o *TenancyContactAssignmentsCreateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_delete_parameters.go b/netbox/client/tenancy/tenancy_contact_assignments_delete_parameters.go new file mode 100644 index 00000000..628b092c --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_delete_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactAssignmentsDeleteParams creates a new TenancyContactAssignmentsDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactAssignmentsDeleteParams() *TenancyContactAssignmentsDeleteParams { + return &TenancyContactAssignmentsDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactAssignmentsDeleteParamsWithTimeout creates a new TenancyContactAssignmentsDeleteParams object +// with the ability to set a timeout on a request. +func NewTenancyContactAssignmentsDeleteParamsWithTimeout(timeout time.Duration) *TenancyContactAssignmentsDeleteParams { + return &TenancyContactAssignmentsDeleteParams{ + timeout: timeout, + } +} + +// NewTenancyContactAssignmentsDeleteParamsWithContext creates a new TenancyContactAssignmentsDeleteParams object +// with the ability to set a context for a request. +func NewTenancyContactAssignmentsDeleteParamsWithContext(ctx context.Context) *TenancyContactAssignmentsDeleteParams { + return &TenancyContactAssignmentsDeleteParams{ + Context: ctx, + } +} + +// NewTenancyContactAssignmentsDeleteParamsWithHTTPClient creates a new TenancyContactAssignmentsDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactAssignmentsDeleteParamsWithHTTPClient(client *http.Client) *TenancyContactAssignmentsDeleteParams { + return &TenancyContactAssignmentsDeleteParams{ + HTTPClient: client, + } +} + +/* TenancyContactAssignmentsDeleteParams contains all the parameters to send to the API endpoint + for the tenancy contact assignments delete operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactAssignmentsDeleteParams struct { + + /* ID. + + A unique integer value identifying this contact assignment. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact assignments delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsDeleteParams) WithDefaults() *TenancyContactAssignmentsDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact assignments delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact assignments delete params +func (o *TenancyContactAssignmentsDeleteParams) WithTimeout(timeout time.Duration) *TenancyContactAssignmentsDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact assignments delete params +func (o *TenancyContactAssignmentsDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact assignments delete params +func (o *TenancyContactAssignmentsDeleteParams) WithContext(ctx context.Context) *TenancyContactAssignmentsDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact assignments delete params +func (o *TenancyContactAssignmentsDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact assignments delete params +func (o *TenancyContactAssignmentsDeleteParams) WithHTTPClient(client *http.Client) *TenancyContactAssignmentsDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact assignments delete params +func (o *TenancyContactAssignmentsDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the tenancy contact assignments delete params +func (o *TenancyContactAssignmentsDeleteParams) WithID(id int64) *TenancyContactAssignmentsDeleteParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact assignments delete params +func (o *TenancyContactAssignmentsDeleteParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactAssignmentsDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_delete_responses.go b/netbox/client/tenancy/tenancy_contact_assignments_delete_responses.go new file mode 100644 index 00000000..dd3dc7d4 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// TenancyContactAssignmentsDeleteReader is a Reader for the TenancyContactAssignmentsDelete structure. +type TenancyContactAssignmentsDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactAssignmentsDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewTenancyContactAssignmentsDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactAssignmentsDeleteNoContent creates a TenancyContactAssignmentsDeleteNoContent with default headers values +func NewTenancyContactAssignmentsDeleteNoContent() *TenancyContactAssignmentsDeleteNoContent { + return &TenancyContactAssignmentsDeleteNoContent{} +} + +/* TenancyContactAssignmentsDeleteNoContent describes a response with status code 204, with default header values. + +TenancyContactAssignmentsDeleteNoContent tenancy contact assignments delete no content +*/ +type TenancyContactAssignmentsDeleteNoContent struct { +} + +func (o *TenancyContactAssignmentsDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /tenancy/contact-assignments/{id}/][%d] tenancyContactAssignmentsDeleteNoContent ", 204) +} + +func (o *TenancyContactAssignmentsDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_list_parameters.go b/netbox/client/tenancy/tenancy_contact_assignments_list_parameters.go new file mode 100644 index 00000000..56204582 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_list_parameters.go @@ -0,0 +1,1141 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactAssignmentsListParams creates a new TenancyContactAssignmentsListParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactAssignmentsListParams() *TenancyContactAssignmentsListParams { + return &TenancyContactAssignmentsListParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactAssignmentsListParamsWithTimeout creates a new TenancyContactAssignmentsListParams object +// with the ability to set a timeout on a request. +func NewTenancyContactAssignmentsListParamsWithTimeout(timeout time.Duration) *TenancyContactAssignmentsListParams { + return &TenancyContactAssignmentsListParams{ + timeout: timeout, + } +} + +// NewTenancyContactAssignmentsListParamsWithContext creates a new TenancyContactAssignmentsListParams object +// with the ability to set a context for a request. +func NewTenancyContactAssignmentsListParamsWithContext(ctx context.Context) *TenancyContactAssignmentsListParams { + return &TenancyContactAssignmentsListParams{ + Context: ctx, + } +} + +// NewTenancyContactAssignmentsListParamsWithHTTPClient creates a new TenancyContactAssignmentsListParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactAssignmentsListParamsWithHTTPClient(client *http.Client) *TenancyContactAssignmentsListParams { + return &TenancyContactAssignmentsListParams{ + HTTPClient: client, + } +} + +/* TenancyContactAssignmentsListParams contains all the parameters to send to the API endpoint + for the tenancy contact assignments list operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactAssignmentsListParams struct { + + // ContactID. + ContactID *string + + // ContactIDn. + ContactIDn *string + + // ContentType. + ContentType *string + + // ContentTypen. + ContentTypen *string + + // ContentTypeID. + ContentTypeID *string + + // ContentTypeIDn. + ContentTypeIDn *string + + // Created. + Created *string + + // CreatedGte. + CreatedGte *string + + // CreatedLte. + CreatedLte *string + + // ID. + ID *string + + // IDGt. + IDGt *string + + // IDGte. + IDGte *string + + // IDLt. + IDLt *string + + // IDLte. + IDLte *string + + // IDn. + IDn *string + + // LastUpdated. + LastUpdated *string + + // LastUpdatedGte. + LastUpdatedGte *string + + // LastUpdatedLte. + LastUpdatedLte *string + + /* Limit. + + Number of results to return per page. + */ + Limit *int64 + + // ObjectID. + ObjectID *string + + // ObjectIDGt. + ObjectIDGt *string + + // ObjectIDGte. + ObjectIDGte *string + + // ObjectIDLt. + ObjectIDLt *string + + // ObjectIDLte. + ObjectIDLte *string + + // ObjectIDn. + ObjectIDn *string + + /* Offset. + + The initial index from which to return the results. + */ + Offset *int64 + + // Priority. + Priority *string + + // Priorityn. + Priorityn *string + + // Role. + Role *string + + // Rolen. + Rolen *string + + // RoleID. + RoleID *string + + // RoleIDn. + RoleIDn *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact assignments list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsListParams) WithDefaults() *TenancyContactAssignmentsListParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact assignments list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsListParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithTimeout(timeout time.Duration) *TenancyContactAssignmentsListParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithContext(ctx context.Context) *TenancyContactAssignmentsListParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithHTTPClient(client *http.Client) *TenancyContactAssignmentsListParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithContactID adds the contactID to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithContactID(contactID *string) *TenancyContactAssignmentsListParams { + o.SetContactID(contactID) + return o +} + +// SetContactID adds the contactId to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetContactID(contactID *string) { + o.ContactID = contactID +} + +// WithContactIDn adds the contactIDn to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithContactIDn(contactIDn *string) *TenancyContactAssignmentsListParams { + o.SetContactIDn(contactIDn) + return o +} + +// SetContactIDn adds the contactIdN to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetContactIDn(contactIDn *string) { + o.ContactIDn = contactIDn +} + +// WithContentType adds the contentType to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithContentType(contentType *string) *TenancyContactAssignmentsListParams { + o.SetContentType(contentType) + return o +} + +// SetContentType adds the contentType to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetContentType(contentType *string) { + o.ContentType = contentType +} + +// WithContentTypen adds the contentTypen to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithContentTypen(contentTypen *string) *TenancyContactAssignmentsListParams { + o.SetContentTypen(contentTypen) + return o +} + +// SetContentTypen adds the contentTypeN to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetContentTypen(contentTypen *string) { + o.ContentTypen = contentTypen +} + +// WithContentTypeID adds the contentTypeID to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithContentTypeID(contentTypeID *string) *TenancyContactAssignmentsListParams { + o.SetContentTypeID(contentTypeID) + return o +} + +// SetContentTypeID adds the contentTypeId to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetContentTypeID(contentTypeID *string) { + o.ContentTypeID = contentTypeID +} + +// WithContentTypeIDn adds the contentTypeIDn to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithContentTypeIDn(contentTypeIDn *string) *TenancyContactAssignmentsListParams { + o.SetContentTypeIDn(contentTypeIDn) + return o +} + +// SetContentTypeIDn adds the contentTypeIdN to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetContentTypeIDn(contentTypeIDn *string) { + o.ContentTypeIDn = contentTypeIDn +} + +// WithCreated adds the created to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithCreated(created *string) *TenancyContactAssignmentsListParams { + o.SetCreated(created) + return o +} + +// SetCreated adds the created to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetCreated(created *string) { + o.Created = created +} + +// WithCreatedGte adds the createdGte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithCreatedGte(createdGte *string) *TenancyContactAssignmentsListParams { + o.SetCreatedGte(createdGte) + return o +} + +// SetCreatedGte adds the createdGte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetCreatedGte(createdGte *string) { + o.CreatedGte = createdGte +} + +// WithCreatedLte adds the createdLte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithCreatedLte(createdLte *string) *TenancyContactAssignmentsListParams { + o.SetCreatedLte(createdLte) + return o +} + +// SetCreatedLte adds the createdLte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetCreatedLte(createdLte *string) { + o.CreatedLte = createdLte +} + +// WithID adds the id to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithID(id *string) *TenancyContactAssignmentsListParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetID(id *string) { + o.ID = id +} + +// WithIDGt adds the iDGt to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithIDGt(iDGt *string) *TenancyContactAssignmentsListParams { + o.SetIDGt(iDGt) + return o +} + +// SetIDGt adds the idGt to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetIDGt(iDGt *string) { + o.IDGt = iDGt +} + +// WithIDGte adds the iDGte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithIDGte(iDGte *string) *TenancyContactAssignmentsListParams { + o.SetIDGte(iDGte) + return o +} + +// SetIDGte adds the idGte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetIDGte(iDGte *string) { + o.IDGte = iDGte +} + +// WithIDLt adds the iDLt to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithIDLt(iDLt *string) *TenancyContactAssignmentsListParams { + o.SetIDLt(iDLt) + return o +} + +// SetIDLt adds the idLt to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetIDLt(iDLt *string) { + o.IDLt = iDLt +} + +// WithIDLte adds the iDLte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithIDLte(iDLte *string) *TenancyContactAssignmentsListParams { + o.SetIDLte(iDLte) + return o +} + +// SetIDLte adds the idLte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetIDLte(iDLte *string) { + o.IDLte = iDLte +} + +// WithIDn adds the iDn to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithIDn(iDn *string) *TenancyContactAssignmentsListParams { + o.SetIDn(iDn) + return o +} + +// SetIDn adds the idN to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetIDn(iDn *string) { + o.IDn = iDn +} + +// WithLastUpdated adds the lastUpdated to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithLastUpdated(lastUpdated *string) *TenancyContactAssignmentsListParams { + o.SetLastUpdated(lastUpdated) + return o +} + +// SetLastUpdated adds the lastUpdated to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetLastUpdated(lastUpdated *string) { + o.LastUpdated = lastUpdated +} + +// WithLastUpdatedGte adds the lastUpdatedGte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithLastUpdatedGte(lastUpdatedGte *string) *TenancyContactAssignmentsListParams { + o.SetLastUpdatedGte(lastUpdatedGte) + return o +} + +// SetLastUpdatedGte adds the lastUpdatedGte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetLastUpdatedGte(lastUpdatedGte *string) { + o.LastUpdatedGte = lastUpdatedGte +} + +// WithLastUpdatedLte adds the lastUpdatedLte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithLastUpdatedLte(lastUpdatedLte *string) *TenancyContactAssignmentsListParams { + o.SetLastUpdatedLte(lastUpdatedLte) + return o +} + +// SetLastUpdatedLte adds the lastUpdatedLte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetLastUpdatedLte(lastUpdatedLte *string) { + o.LastUpdatedLte = lastUpdatedLte +} + +// WithLimit adds the limit to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithLimit(limit *int64) *TenancyContactAssignmentsListParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithObjectID adds the objectID to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithObjectID(objectID *string) *TenancyContactAssignmentsListParams { + o.SetObjectID(objectID) + return o +} + +// SetObjectID adds the objectId to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetObjectID(objectID *string) { + o.ObjectID = objectID +} + +// WithObjectIDGt adds the objectIDGt to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithObjectIDGt(objectIDGt *string) *TenancyContactAssignmentsListParams { + o.SetObjectIDGt(objectIDGt) + return o +} + +// SetObjectIDGt adds the objectIdGt to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetObjectIDGt(objectIDGt *string) { + o.ObjectIDGt = objectIDGt +} + +// WithObjectIDGte adds the objectIDGte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithObjectIDGte(objectIDGte *string) *TenancyContactAssignmentsListParams { + o.SetObjectIDGte(objectIDGte) + return o +} + +// SetObjectIDGte adds the objectIdGte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetObjectIDGte(objectIDGte *string) { + o.ObjectIDGte = objectIDGte +} + +// WithObjectIDLt adds the objectIDLt to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithObjectIDLt(objectIDLt *string) *TenancyContactAssignmentsListParams { + o.SetObjectIDLt(objectIDLt) + return o +} + +// SetObjectIDLt adds the objectIdLt to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetObjectIDLt(objectIDLt *string) { + o.ObjectIDLt = objectIDLt +} + +// WithObjectIDLte adds the objectIDLte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithObjectIDLte(objectIDLte *string) *TenancyContactAssignmentsListParams { + o.SetObjectIDLte(objectIDLte) + return o +} + +// SetObjectIDLte adds the objectIdLte to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetObjectIDLte(objectIDLte *string) { + o.ObjectIDLte = objectIDLte +} + +// WithObjectIDn adds the objectIDn to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithObjectIDn(objectIDn *string) *TenancyContactAssignmentsListParams { + o.SetObjectIDn(objectIDn) + return o +} + +// SetObjectIDn adds the objectIdN to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetObjectIDn(objectIDn *string) { + o.ObjectIDn = objectIDn +} + +// WithOffset adds the offset to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithOffset(offset *int64) *TenancyContactAssignmentsListParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithPriority adds the priority to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithPriority(priority *string) *TenancyContactAssignmentsListParams { + o.SetPriority(priority) + return o +} + +// SetPriority adds the priority to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetPriority(priority *string) { + o.Priority = priority +} + +// WithPriorityn adds the priorityn to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithPriorityn(priorityn *string) *TenancyContactAssignmentsListParams { + o.SetPriorityn(priorityn) + return o +} + +// SetPriorityn adds the priorityN to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetPriorityn(priorityn *string) { + o.Priorityn = priorityn +} + +// WithRole adds the role to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithRole(role *string) *TenancyContactAssignmentsListParams { + o.SetRole(role) + return o +} + +// SetRole adds the role to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetRole(role *string) { + o.Role = role +} + +// WithRolen adds the rolen to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithRolen(rolen *string) *TenancyContactAssignmentsListParams { + o.SetRolen(rolen) + return o +} + +// SetRolen adds the roleN to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetRolen(rolen *string) { + o.Rolen = rolen +} + +// WithRoleID adds the roleID to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithRoleID(roleID *string) *TenancyContactAssignmentsListParams { + o.SetRoleID(roleID) + return o +} + +// SetRoleID adds the roleId to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetRoleID(roleID *string) { + o.RoleID = roleID +} + +// WithRoleIDn adds the roleIDn to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) WithRoleIDn(roleIDn *string) *TenancyContactAssignmentsListParams { + o.SetRoleIDn(roleIDn) + return o +} + +// SetRoleIDn adds the roleIdN to the tenancy contact assignments list params +func (o *TenancyContactAssignmentsListParams) SetRoleIDn(roleIDn *string) { + o.RoleIDn = roleIDn +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactAssignmentsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.ContactID != nil { + + // query param contact_id + var qrContactID string + + if o.ContactID != nil { + qrContactID = *o.ContactID + } + qContactID := qrContactID + if qContactID != "" { + + if err := r.SetQueryParam("contact_id", qContactID); err != nil { + return err + } + } + } + + if o.ContactIDn != nil { + + // query param contact_id__n + var qrContactIDn string + + if o.ContactIDn != nil { + qrContactIDn = *o.ContactIDn + } + qContactIDn := qrContactIDn + if qContactIDn != "" { + + if err := r.SetQueryParam("contact_id__n", qContactIDn); err != nil { + return err + } + } + } + + if o.ContentType != nil { + + // query param content_type + var qrContentType string + + if o.ContentType != nil { + qrContentType = *o.ContentType + } + qContentType := qrContentType + if qContentType != "" { + + if err := r.SetQueryParam("content_type", qContentType); err != nil { + return err + } + } + } + + if o.ContentTypen != nil { + + // query param content_type__n + var qrContentTypen string + + if o.ContentTypen != nil { + qrContentTypen = *o.ContentTypen + } + qContentTypen := qrContentTypen + if qContentTypen != "" { + + if err := r.SetQueryParam("content_type__n", qContentTypen); err != nil { + return err + } + } + } + + if o.ContentTypeID != nil { + + // query param content_type_id + var qrContentTypeID string + + if o.ContentTypeID != nil { + qrContentTypeID = *o.ContentTypeID + } + qContentTypeID := qrContentTypeID + if qContentTypeID != "" { + + if err := r.SetQueryParam("content_type_id", qContentTypeID); err != nil { + return err + } + } + } + + if o.ContentTypeIDn != nil { + + // query param content_type_id__n + var qrContentTypeIDn string + + if o.ContentTypeIDn != nil { + qrContentTypeIDn = *o.ContentTypeIDn + } + qContentTypeIDn := qrContentTypeIDn + if qContentTypeIDn != "" { + + if err := r.SetQueryParam("content_type_id__n", qContentTypeIDn); err != nil { + return err + } + } + } + + if o.Created != nil { + + // query param created + var qrCreated string + + if o.Created != nil { + qrCreated = *o.Created + } + qCreated := qrCreated + if qCreated != "" { + + if err := r.SetQueryParam("created", qCreated); err != nil { + return err + } + } + } + + if o.CreatedGte != nil { + + // query param created__gte + var qrCreatedGte string + + if o.CreatedGte != nil { + qrCreatedGte = *o.CreatedGte + } + qCreatedGte := qrCreatedGte + if qCreatedGte != "" { + + if err := r.SetQueryParam("created__gte", qCreatedGte); err != nil { + return err + } + } + } + + if o.CreatedLte != nil { + + // query param created__lte + var qrCreatedLte string + + if o.CreatedLte != nil { + qrCreatedLte = *o.CreatedLte + } + qCreatedLte := qrCreatedLte + if qCreatedLte != "" { + + if err := r.SetQueryParam("created__lte", qCreatedLte); err != nil { + return err + } + } + } + + if o.ID != nil { + + // query param id + var qrID string + + if o.ID != nil { + qrID = *o.ID + } + qID := qrID + if qID != "" { + + if err := r.SetQueryParam("id", qID); err != nil { + return err + } + } + } + + if o.IDGt != nil { + + // query param id__gt + var qrIDGt string + + if o.IDGt != nil { + qrIDGt = *o.IDGt + } + qIDGt := qrIDGt + if qIDGt != "" { + + if err := r.SetQueryParam("id__gt", qIDGt); err != nil { + return err + } + } + } + + if o.IDGte != nil { + + // query param id__gte + var qrIDGte string + + if o.IDGte != nil { + qrIDGte = *o.IDGte + } + qIDGte := qrIDGte + if qIDGte != "" { + + if err := r.SetQueryParam("id__gte", qIDGte); err != nil { + return err + } + } + } + + if o.IDLt != nil { + + // query param id__lt + var qrIDLt string + + if o.IDLt != nil { + qrIDLt = *o.IDLt + } + qIDLt := qrIDLt + if qIDLt != "" { + + if err := r.SetQueryParam("id__lt", qIDLt); err != nil { + return err + } + } + } + + if o.IDLte != nil { + + // query param id__lte + var qrIDLte string + + if o.IDLte != nil { + qrIDLte = *o.IDLte + } + qIDLte := qrIDLte + if qIDLte != "" { + + if err := r.SetQueryParam("id__lte", qIDLte); err != nil { + return err + } + } + } + + if o.IDn != nil { + + // query param id__n + var qrIDn string + + if o.IDn != nil { + qrIDn = *o.IDn + } + qIDn := qrIDn + if qIDn != "" { + + if err := r.SetQueryParam("id__n", qIDn); err != nil { + return err + } + } + } + + if o.LastUpdated != nil { + + // query param last_updated + var qrLastUpdated string + + if o.LastUpdated != nil { + qrLastUpdated = *o.LastUpdated + } + qLastUpdated := qrLastUpdated + if qLastUpdated != "" { + + if err := r.SetQueryParam("last_updated", qLastUpdated); err != nil { + return err + } + } + } + + if o.LastUpdatedGte != nil { + + // query param last_updated__gte + var qrLastUpdatedGte string + + if o.LastUpdatedGte != nil { + qrLastUpdatedGte = *o.LastUpdatedGte + } + qLastUpdatedGte := qrLastUpdatedGte + if qLastUpdatedGte != "" { + + if err := r.SetQueryParam("last_updated__gte", qLastUpdatedGte); err != nil { + return err + } + } + } + + if o.LastUpdatedLte != nil { + + // query param last_updated__lte + var qrLastUpdatedLte string + + if o.LastUpdatedLte != nil { + qrLastUpdatedLte = *o.LastUpdatedLte + } + qLastUpdatedLte := qrLastUpdatedLte + if qLastUpdatedLte != "" { + + if err := r.SetQueryParam("last_updated__lte", qLastUpdatedLte); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.ObjectID != nil { + + // query param object_id + var qrObjectID string + + if o.ObjectID != nil { + qrObjectID = *o.ObjectID + } + qObjectID := qrObjectID + if qObjectID != "" { + + if err := r.SetQueryParam("object_id", qObjectID); err != nil { + return err + } + } + } + + if o.ObjectIDGt != nil { + + // query param object_id__gt + var qrObjectIDGt string + + if o.ObjectIDGt != nil { + qrObjectIDGt = *o.ObjectIDGt + } + qObjectIDGt := qrObjectIDGt + if qObjectIDGt != "" { + + if err := r.SetQueryParam("object_id__gt", qObjectIDGt); err != nil { + return err + } + } + } + + if o.ObjectIDGte != nil { + + // query param object_id__gte + var qrObjectIDGte string + + if o.ObjectIDGte != nil { + qrObjectIDGte = *o.ObjectIDGte + } + qObjectIDGte := qrObjectIDGte + if qObjectIDGte != "" { + + if err := r.SetQueryParam("object_id__gte", qObjectIDGte); err != nil { + return err + } + } + } + + if o.ObjectIDLt != nil { + + // query param object_id__lt + var qrObjectIDLt string + + if o.ObjectIDLt != nil { + qrObjectIDLt = *o.ObjectIDLt + } + qObjectIDLt := qrObjectIDLt + if qObjectIDLt != "" { + + if err := r.SetQueryParam("object_id__lt", qObjectIDLt); err != nil { + return err + } + } + } + + if o.ObjectIDLte != nil { + + // query param object_id__lte + var qrObjectIDLte string + + if o.ObjectIDLte != nil { + qrObjectIDLte = *o.ObjectIDLte + } + qObjectIDLte := qrObjectIDLte + if qObjectIDLte != "" { + + if err := r.SetQueryParam("object_id__lte", qObjectIDLte); err != nil { + return err + } + } + } + + if o.ObjectIDn != nil { + + // query param object_id__n + var qrObjectIDn string + + if o.ObjectIDn != nil { + qrObjectIDn = *o.ObjectIDn + } + qObjectIDn := qrObjectIDn + if qObjectIDn != "" { + + if err := r.SetQueryParam("object_id__n", qObjectIDn); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.Priority != nil { + + // query param priority + var qrPriority string + + if o.Priority != nil { + qrPriority = *o.Priority + } + qPriority := qrPriority + if qPriority != "" { + + if err := r.SetQueryParam("priority", qPriority); err != nil { + return err + } + } + } + + if o.Priorityn != nil { + + // query param priority__n + var qrPriorityn string + + if o.Priorityn != nil { + qrPriorityn = *o.Priorityn + } + qPriorityn := qrPriorityn + if qPriorityn != "" { + + if err := r.SetQueryParam("priority__n", qPriorityn); err != nil { + return err + } + } + } + + if o.Role != nil { + + // query param role + var qrRole string + + if o.Role != nil { + qrRole = *o.Role + } + qRole := qrRole + if qRole != "" { + + if err := r.SetQueryParam("role", qRole); err != nil { + return err + } + } + } + + if o.Rolen != nil { + + // query param role__n + var qrRolen string + + if o.Rolen != nil { + qrRolen = *o.Rolen + } + qRolen := qrRolen + if qRolen != "" { + + if err := r.SetQueryParam("role__n", qRolen); err != nil { + return err + } + } + } + + if o.RoleID != nil { + + // query param role_id + var qrRoleID string + + if o.RoleID != nil { + qrRoleID = *o.RoleID + } + qRoleID := qrRoleID + if qRoleID != "" { + + if err := r.SetQueryParam("role_id", qRoleID); err != nil { + return err + } + } + } + + if o.RoleIDn != nil { + + // query param role_id__n + var qrRoleIDn string + + if o.RoleIDn != nil { + qrRoleIDn = *o.RoleIDn + } + qRoleIDn := qrRoleIDn + if qRoleIDn != "" { + + if err := r.SetQueryParam("role_id__n", qRoleIDn); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_list_responses.go b/netbox/client/tenancy/tenancy_contact_assignments_list_responses.go new file mode 100644 index 00000000..61325781 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_list_responses.go @@ -0,0 +1,247 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactAssignmentsListReader is a Reader for the TenancyContactAssignmentsList structure. +type TenancyContactAssignmentsListReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactAssignmentsListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactAssignmentsListOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactAssignmentsListOK creates a TenancyContactAssignmentsListOK with default headers values +func NewTenancyContactAssignmentsListOK() *TenancyContactAssignmentsListOK { + return &TenancyContactAssignmentsListOK{} +} + +/* TenancyContactAssignmentsListOK describes a response with status code 200, with default header values. + +TenancyContactAssignmentsListOK tenancy contact assignments list o k +*/ +type TenancyContactAssignmentsListOK struct { + Payload *TenancyContactAssignmentsListOKBody +} + +func (o *TenancyContactAssignmentsListOK) Error() string { + return fmt.Sprintf("[GET /tenancy/contact-assignments/][%d] tenancyContactAssignmentsListOK %+v", 200, o.Payload) +} +func (o *TenancyContactAssignmentsListOK) GetPayload() *TenancyContactAssignmentsListOKBody { + return o.Payload +} + +func (o *TenancyContactAssignmentsListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(TenancyContactAssignmentsListOKBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*TenancyContactAssignmentsListOKBody tenancy contact assignments list o k body +swagger:model TenancyContactAssignmentsListOKBody +*/ +type TenancyContactAssignmentsListOKBody struct { + + // count + // Required: true + Count *int64 `json:"count"` + + // next + // Format: uri + Next *strfmt.URI `json:"next,omitempty"` + + // previous + // Format: uri + Previous *strfmt.URI `json:"previous,omitempty"` + + // results + // Required: true + Results []*models.ContactAssignment `json:"results"` +} + +// Validate validates this tenancy contact assignments list o k body +func (o *TenancyContactAssignmentsListOKBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateCount(formats); err != nil { + res = append(res, err) + } + + if err := o.validateNext(formats); err != nil { + res = append(res, err) + } + + if err := o.validatePrevious(formats); err != nil { + res = append(res, err) + } + + if err := o.validateResults(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *TenancyContactAssignmentsListOKBody) validateCount(formats strfmt.Registry) error { + + if err := validate.Required("tenancyContactAssignmentsListOK"+"."+"count", "body", o.Count); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactAssignmentsListOKBody) validateNext(formats strfmt.Registry) error { + if swag.IsZero(o.Next) { // not required + return nil + } + + if err := validate.FormatOf("tenancyContactAssignmentsListOK"+"."+"next", "body", "uri", o.Next.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactAssignmentsListOKBody) validatePrevious(formats strfmt.Registry) error { + if swag.IsZero(o.Previous) { // not required + return nil + } + + if err := validate.FormatOf("tenancyContactAssignmentsListOK"+"."+"previous", "body", "uri", o.Previous.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactAssignmentsListOKBody) validateResults(formats strfmt.Registry) error { + + if err := validate.Required("tenancyContactAssignmentsListOK"+"."+"results", "body", o.Results); err != nil { + return err + } + + for i := 0; i < len(o.Results); i++ { + if swag.IsZero(o.Results[i]) { // not required + continue + } + + if o.Results[i] != nil { + if err := o.Results[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenancyContactAssignmentsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenancyContactAssignmentsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this tenancy contact assignments list o k body based on the context it is used +func (o *TenancyContactAssignmentsListOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := o.contextValidateResults(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *TenancyContactAssignmentsListOKBody) contextValidateResults(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(o.Results); i++ { + + if o.Results[i] != nil { + if err := o.Results[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenancyContactAssignmentsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenancyContactAssignmentsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (o *TenancyContactAssignmentsListOKBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *TenancyContactAssignmentsListOKBody) UnmarshalBinary(b []byte) error { + var res TenancyContactAssignmentsListOKBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_partial_update_parameters.go b/netbox/client/tenancy/tenancy_contact_assignments_partial_update_parameters.go new file mode 100644 index 00000000..8be80381 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_partial_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactAssignmentsPartialUpdateParams creates a new TenancyContactAssignmentsPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactAssignmentsPartialUpdateParams() *TenancyContactAssignmentsPartialUpdateParams { + return &TenancyContactAssignmentsPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactAssignmentsPartialUpdateParamsWithTimeout creates a new TenancyContactAssignmentsPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactAssignmentsPartialUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactAssignmentsPartialUpdateParams { + return &TenancyContactAssignmentsPartialUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactAssignmentsPartialUpdateParamsWithContext creates a new TenancyContactAssignmentsPartialUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactAssignmentsPartialUpdateParamsWithContext(ctx context.Context) *TenancyContactAssignmentsPartialUpdateParams { + return &TenancyContactAssignmentsPartialUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactAssignmentsPartialUpdateParamsWithHTTPClient creates a new TenancyContactAssignmentsPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactAssignmentsPartialUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactAssignmentsPartialUpdateParams { + return &TenancyContactAssignmentsPartialUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactAssignmentsPartialUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact assignments partial update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactAssignmentsPartialUpdateParams struct { + + // Data. + Data *models.WritableContactAssignment + + /* ID. + + A unique integer value identifying this contact assignment. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact assignments partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsPartialUpdateParams) WithDefaults() *TenancyContactAssignmentsPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact assignments partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact assignments partial update params +func (o *TenancyContactAssignmentsPartialUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactAssignmentsPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact assignments partial update params +func (o *TenancyContactAssignmentsPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact assignments partial update params +func (o *TenancyContactAssignmentsPartialUpdateParams) WithContext(ctx context.Context) *TenancyContactAssignmentsPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact assignments partial update params +func (o *TenancyContactAssignmentsPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact assignments partial update params +func (o *TenancyContactAssignmentsPartialUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactAssignmentsPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact assignments partial update params +func (o *TenancyContactAssignmentsPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact assignments partial update params +func (o *TenancyContactAssignmentsPartialUpdateParams) WithData(data *models.WritableContactAssignment) *TenancyContactAssignmentsPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact assignments partial update params +func (o *TenancyContactAssignmentsPartialUpdateParams) SetData(data *models.WritableContactAssignment) { + o.Data = data +} + +// WithID adds the id to the tenancy contact assignments partial update params +func (o *TenancyContactAssignmentsPartialUpdateParams) WithID(id int64) *TenancyContactAssignmentsPartialUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact assignments partial update params +func (o *TenancyContactAssignmentsPartialUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactAssignmentsPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_partial_update_responses.go b/netbox/client/tenancy/tenancy_contact_assignments_partial_update_responses.go new file mode 100644 index 00000000..7b5d3867 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactAssignmentsPartialUpdateReader is a Reader for the TenancyContactAssignmentsPartialUpdate structure. +type TenancyContactAssignmentsPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactAssignmentsPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactAssignmentsPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactAssignmentsPartialUpdateOK creates a TenancyContactAssignmentsPartialUpdateOK with default headers values +func NewTenancyContactAssignmentsPartialUpdateOK() *TenancyContactAssignmentsPartialUpdateOK { + return &TenancyContactAssignmentsPartialUpdateOK{} +} + +/* TenancyContactAssignmentsPartialUpdateOK describes a response with status code 200, with default header values. + +TenancyContactAssignmentsPartialUpdateOK tenancy contact assignments partial update o k +*/ +type TenancyContactAssignmentsPartialUpdateOK struct { + Payload *models.ContactAssignment +} + +func (o *TenancyContactAssignmentsPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /tenancy/contact-assignments/{id}/][%d] tenancyContactAssignmentsPartialUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactAssignmentsPartialUpdateOK) GetPayload() *models.ContactAssignment { + return o.Payload +} + +func (o *TenancyContactAssignmentsPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_read_parameters.go b/netbox/client/tenancy/tenancy_contact_assignments_read_parameters.go new file mode 100644 index 00000000..7436ff84 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_read_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactAssignmentsReadParams creates a new TenancyContactAssignmentsReadParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactAssignmentsReadParams() *TenancyContactAssignmentsReadParams { + return &TenancyContactAssignmentsReadParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactAssignmentsReadParamsWithTimeout creates a new TenancyContactAssignmentsReadParams object +// with the ability to set a timeout on a request. +func NewTenancyContactAssignmentsReadParamsWithTimeout(timeout time.Duration) *TenancyContactAssignmentsReadParams { + return &TenancyContactAssignmentsReadParams{ + timeout: timeout, + } +} + +// NewTenancyContactAssignmentsReadParamsWithContext creates a new TenancyContactAssignmentsReadParams object +// with the ability to set a context for a request. +func NewTenancyContactAssignmentsReadParamsWithContext(ctx context.Context) *TenancyContactAssignmentsReadParams { + return &TenancyContactAssignmentsReadParams{ + Context: ctx, + } +} + +// NewTenancyContactAssignmentsReadParamsWithHTTPClient creates a new TenancyContactAssignmentsReadParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactAssignmentsReadParamsWithHTTPClient(client *http.Client) *TenancyContactAssignmentsReadParams { + return &TenancyContactAssignmentsReadParams{ + HTTPClient: client, + } +} + +/* TenancyContactAssignmentsReadParams contains all the parameters to send to the API endpoint + for the tenancy contact assignments read operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactAssignmentsReadParams struct { + + /* ID. + + A unique integer value identifying this contact assignment. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact assignments read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsReadParams) WithDefaults() *TenancyContactAssignmentsReadParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact assignments read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsReadParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact assignments read params +func (o *TenancyContactAssignmentsReadParams) WithTimeout(timeout time.Duration) *TenancyContactAssignmentsReadParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact assignments read params +func (o *TenancyContactAssignmentsReadParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact assignments read params +func (o *TenancyContactAssignmentsReadParams) WithContext(ctx context.Context) *TenancyContactAssignmentsReadParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact assignments read params +func (o *TenancyContactAssignmentsReadParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact assignments read params +func (o *TenancyContactAssignmentsReadParams) WithHTTPClient(client *http.Client) *TenancyContactAssignmentsReadParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact assignments read params +func (o *TenancyContactAssignmentsReadParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the tenancy contact assignments read params +func (o *TenancyContactAssignmentsReadParams) WithID(id int64) *TenancyContactAssignmentsReadParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact assignments read params +func (o *TenancyContactAssignmentsReadParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactAssignmentsReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_read_responses.go b/netbox/client/tenancy/tenancy_contact_assignments_read_responses.go new file mode 100644 index 00000000..4b723f07 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_read_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactAssignmentsReadReader is a Reader for the TenancyContactAssignmentsRead structure. +type TenancyContactAssignmentsReadReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactAssignmentsReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactAssignmentsReadOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactAssignmentsReadOK creates a TenancyContactAssignmentsReadOK with default headers values +func NewTenancyContactAssignmentsReadOK() *TenancyContactAssignmentsReadOK { + return &TenancyContactAssignmentsReadOK{} +} + +/* TenancyContactAssignmentsReadOK describes a response with status code 200, with default header values. + +TenancyContactAssignmentsReadOK tenancy contact assignments read o k +*/ +type TenancyContactAssignmentsReadOK struct { + Payload *models.ContactAssignment +} + +func (o *TenancyContactAssignmentsReadOK) Error() string { + return fmt.Sprintf("[GET /tenancy/contact-assignments/{id}/][%d] tenancyContactAssignmentsReadOK %+v", 200, o.Payload) +} +func (o *TenancyContactAssignmentsReadOK) GetPayload() *models.ContactAssignment { + return o.Payload +} + +func (o *TenancyContactAssignmentsReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_update_parameters.go b/netbox/client/tenancy/tenancy_contact_assignments_update_parameters.go new file mode 100644 index 00000000..0a5a76fc --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactAssignmentsUpdateParams creates a new TenancyContactAssignmentsUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactAssignmentsUpdateParams() *TenancyContactAssignmentsUpdateParams { + return &TenancyContactAssignmentsUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactAssignmentsUpdateParamsWithTimeout creates a new TenancyContactAssignmentsUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactAssignmentsUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactAssignmentsUpdateParams { + return &TenancyContactAssignmentsUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactAssignmentsUpdateParamsWithContext creates a new TenancyContactAssignmentsUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactAssignmentsUpdateParamsWithContext(ctx context.Context) *TenancyContactAssignmentsUpdateParams { + return &TenancyContactAssignmentsUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactAssignmentsUpdateParamsWithHTTPClient creates a new TenancyContactAssignmentsUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactAssignmentsUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactAssignmentsUpdateParams { + return &TenancyContactAssignmentsUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactAssignmentsUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact assignments update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactAssignmentsUpdateParams struct { + + // Data. + Data *models.WritableContactAssignment + + /* ID. + + A unique integer value identifying this contact assignment. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact assignments update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsUpdateParams) WithDefaults() *TenancyContactAssignmentsUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact assignments update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactAssignmentsUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact assignments update params +func (o *TenancyContactAssignmentsUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactAssignmentsUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact assignments update params +func (o *TenancyContactAssignmentsUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact assignments update params +func (o *TenancyContactAssignmentsUpdateParams) WithContext(ctx context.Context) *TenancyContactAssignmentsUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact assignments update params +func (o *TenancyContactAssignmentsUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact assignments update params +func (o *TenancyContactAssignmentsUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactAssignmentsUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact assignments update params +func (o *TenancyContactAssignmentsUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact assignments update params +func (o *TenancyContactAssignmentsUpdateParams) WithData(data *models.WritableContactAssignment) *TenancyContactAssignmentsUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact assignments update params +func (o *TenancyContactAssignmentsUpdateParams) SetData(data *models.WritableContactAssignment) { + o.Data = data +} + +// WithID adds the id to the tenancy contact assignments update params +func (o *TenancyContactAssignmentsUpdateParams) WithID(id int64) *TenancyContactAssignmentsUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact assignments update params +func (o *TenancyContactAssignmentsUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactAssignmentsUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_assignments_update_responses.go b/netbox/client/tenancy/tenancy_contact_assignments_update_responses.go new file mode 100644 index 00000000..44a457ce --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_assignments_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactAssignmentsUpdateReader is a Reader for the TenancyContactAssignmentsUpdate structure. +type TenancyContactAssignmentsUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactAssignmentsUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactAssignmentsUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactAssignmentsUpdateOK creates a TenancyContactAssignmentsUpdateOK with default headers values +func NewTenancyContactAssignmentsUpdateOK() *TenancyContactAssignmentsUpdateOK { + return &TenancyContactAssignmentsUpdateOK{} +} + +/* TenancyContactAssignmentsUpdateOK describes a response with status code 200, with default header values. + +TenancyContactAssignmentsUpdateOK tenancy contact assignments update o k +*/ +type TenancyContactAssignmentsUpdateOK struct { + Payload *models.ContactAssignment +} + +func (o *TenancyContactAssignmentsUpdateOK) Error() string { + return fmt.Sprintf("[PUT /tenancy/contact-assignments/{id}/][%d] tenancyContactAssignmentsUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactAssignmentsUpdateOK) GetPayload() *models.ContactAssignment { + return o.Payload +} + +func (o *TenancyContactAssignmentsUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactAssignment) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_bulk_delete_parameters.go b/netbox/client/tenancy/tenancy_contact_groups_bulk_delete_parameters.go new file mode 100644 index 00000000..5afde20e --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_bulk_delete_parameters.go @@ -0,0 +1,141 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewTenancyContactGroupsBulkDeleteParams creates a new TenancyContactGroupsBulkDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactGroupsBulkDeleteParams() *TenancyContactGroupsBulkDeleteParams { + return &TenancyContactGroupsBulkDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactGroupsBulkDeleteParamsWithTimeout creates a new TenancyContactGroupsBulkDeleteParams object +// with the ability to set a timeout on a request. +func NewTenancyContactGroupsBulkDeleteParamsWithTimeout(timeout time.Duration) *TenancyContactGroupsBulkDeleteParams { + return &TenancyContactGroupsBulkDeleteParams{ + timeout: timeout, + } +} + +// NewTenancyContactGroupsBulkDeleteParamsWithContext creates a new TenancyContactGroupsBulkDeleteParams object +// with the ability to set a context for a request. +func NewTenancyContactGroupsBulkDeleteParamsWithContext(ctx context.Context) *TenancyContactGroupsBulkDeleteParams { + return &TenancyContactGroupsBulkDeleteParams{ + Context: ctx, + } +} + +// NewTenancyContactGroupsBulkDeleteParamsWithHTTPClient creates a new TenancyContactGroupsBulkDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactGroupsBulkDeleteParamsWithHTTPClient(client *http.Client) *TenancyContactGroupsBulkDeleteParams { + return &TenancyContactGroupsBulkDeleteParams{ + HTTPClient: client, + } +} + +/* TenancyContactGroupsBulkDeleteParams contains all the parameters to send to the API endpoint + for the tenancy contact groups bulk delete operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactGroupsBulkDeleteParams struct { + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact groups bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsBulkDeleteParams) WithDefaults() *TenancyContactGroupsBulkDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact groups bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsBulkDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact groups bulk delete params +func (o *TenancyContactGroupsBulkDeleteParams) WithTimeout(timeout time.Duration) *TenancyContactGroupsBulkDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact groups bulk delete params +func (o *TenancyContactGroupsBulkDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact groups bulk delete params +func (o *TenancyContactGroupsBulkDeleteParams) WithContext(ctx context.Context) *TenancyContactGroupsBulkDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact groups bulk delete params +func (o *TenancyContactGroupsBulkDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact groups bulk delete params +func (o *TenancyContactGroupsBulkDeleteParams) WithHTTPClient(client *http.Client) *TenancyContactGroupsBulkDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact groups bulk delete params +func (o *TenancyContactGroupsBulkDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactGroupsBulkDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_bulk_delete_responses.go b/netbox/client/tenancy/tenancy_contact_groups_bulk_delete_responses.go new file mode 100644 index 00000000..0f7056fb --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_bulk_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// TenancyContactGroupsBulkDeleteReader is a Reader for the TenancyContactGroupsBulkDelete structure. +type TenancyContactGroupsBulkDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactGroupsBulkDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewTenancyContactGroupsBulkDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactGroupsBulkDeleteNoContent creates a TenancyContactGroupsBulkDeleteNoContent with default headers values +func NewTenancyContactGroupsBulkDeleteNoContent() *TenancyContactGroupsBulkDeleteNoContent { + return &TenancyContactGroupsBulkDeleteNoContent{} +} + +/* TenancyContactGroupsBulkDeleteNoContent describes a response with status code 204, with default header values. + +TenancyContactGroupsBulkDeleteNoContent tenancy contact groups bulk delete no content +*/ +type TenancyContactGroupsBulkDeleteNoContent struct { +} + +func (o *TenancyContactGroupsBulkDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /tenancy/contact-groups/][%d] tenancyContactGroupsBulkDeleteNoContent ", 204) +} + +func (o *TenancyContactGroupsBulkDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_bulk_partial_update_parameters.go b/netbox/client/tenancy/tenancy_contact_groups_bulk_partial_update_parameters.go new file mode 100644 index 00000000..6e3b4919 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_bulk_partial_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactGroupsBulkPartialUpdateParams creates a new TenancyContactGroupsBulkPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactGroupsBulkPartialUpdateParams() *TenancyContactGroupsBulkPartialUpdateParams { + return &TenancyContactGroupsBulkPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactGroupsBulkPartialUpdateParamsWithTimeout creates a new TenancyContactGroupsBulkPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactGroupsBulkPartialUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactGroupsBulkPartialUpdateParams { + return &TenancyContactGroupsBulkPartialUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactGroupsBulkPartialUpdateParamsWithContext creates a new TenancyContactGroupsBulkPartialUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactGroupsBulkPartialUpdateParamsWithContext(ctx context.Context) *TenancyContactGroupsBulkPartialUpdateParams { + return &TenancyContactGroupsBulkPartialUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactGroupsBulkPartialUpdateParamsWithHTTPClient creates a new TenancyContactGroupsBulkPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactGroupsBulkPartialUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactGroupsBulkPartialUpdateParams { + return &TenancyContactGroupsBulkPartialUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactGroupsBulkPartialUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact groups bulk partial update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactGroupsBulkPartialUpdateParams struct { + + // Data. + Data *models.WritableContactGroup + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact groups bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsBulkPartialUpdateParams) WithDefaults() *TenancyContactGroupsBulkPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact groups bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsBulkPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact groups bulk partial update params +func (o *TenancyContactGroupsBulkPartialUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactGroupsBulkPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact groups bulk partial update params +func (o *TenancyContactGroupsBulkPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact groups bulk partial update params +func (o *TenancyContactGroupsBulkPartialUpdateParams) WithContext(ctx context.Context) *TenancyContactGroupsBulkPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact groups bulk partial update params +func (o *TenancyContactGroupsBulkPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact groups bulk partial update params +func (o *TenancyContactGroupsBulkPartialUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactGroupsBulkPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact groups bulk partial update params +func (o *TenancyContactGroupsBulkPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact groups bulk partial update params +func (o *TenancyContactGroupsBulkPartialUpdateParams) WithData(data *models.WritableContactGroup) *TenancyContactGroupsBulkPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact groups bulk partial update params +func (o *TenancyContactGroupsBulkPartialUpdateParams) SetData(data *models.WritableContactGroup) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactGroupsBulkPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_bulk_partial_update_responses.go b/netbox/client/tenancy/tenancy_contact_groups_bulk_partial_update_responses.go new file mode 100644 index 00000000..c3bbc42f --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_bulk_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactGroupsBulkPartialUpdateReader is a Reader for the TenancyContactGroupsBulkPartialUpdate structure. +type TenancyContactGroupsBulkPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactGroupsBulkPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactGroupsBulkPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactGroupsBulkPartialUpdateOK creates a TenancyContactGroupsBulkPartialUpdateOK with default headers values +func NewTenancyContactGroupsBulkPartialUpdateOK() *TenancyContactGroupsBulkPartialUpdateOK { + return &TenancyContactGroupsBulkPartialUpdateOK{} +} + +/* TenancyContactGroupsBulkPartialUpdateOK describes a response with status code 200, with default header values. + +TenancyContactGroupsBulkPartialUpdateOK tenancy contact groups bulk partial update o k +*/ +type TenancyContactGroupsBulkPartialUpdateOK struct { + Payload *models.ContactGroup +} + +func (o *TenancyContactGroupsBulkPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /tenancy/contact-groups/][%d] tenancyContactGroupsBulkPartialUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactGroupsBulkPartialUpdateOK) GetPayload() *models.ContactGroup { + return o.Payload +} + +func (o *TenancyContactGroupsBulkPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_bulk_update_parameters.go b/netbox/client/tenancy/tenancy_contact_groups_bulk_update_parameters.go new file mode 100644 index 00000000..d9fb943e --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_bulk_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactGroupsBulkUpdateParams creates a new TenancyContactGroupsBulkUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactGroupsBulkUpdateParams() *TenancyContactGroupsBulkUpdateParams { + return &TenancyContactGroupsBulkUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactGroupsBulkUpdateParamsWithTimeout creates a new TenancyContactGroupsBulkUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactGroupsBulkUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactGroupsBulkUpdateParams { + return &TenancyContactGroupsBulkUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactGroupsBulkUpdateParamsWithContext creates a new TenancyContactGroupsBulkUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactGroupsBulkUpdateParamsWithContext(ctx context.Context) *TenancyContactGroupsBulkUpdateParams { + return &TenancyContactGroupsBulkUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactGroupsBulkUpdateParamsWithHTTPClient creates a new TenancyContactGroupsBulkUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactGroupsBulkUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactGroupsBulkUpdateParams { + return &TenancyContactGroupsBulkUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactGroupsBulkUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact groups bulk update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactGroupsBulkUpdateParams struct { + + // Data. + Data *models.WritableContactGroup + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact groups bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsBulkUpdateParams) WithDefaults() *TenancyContactGroupsBulkUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact groups bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsBulkUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact groups bulk update params +func (o *TenancyContactGroupsBulkUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactGroupsBulkUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact groups bulk update params +func (o *TenancyContactGroupsBulkUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact groups bulk update params +func (o *TenancyContactGroupsBulkUpdateParams) WithContext(ctx context.Context) *TenancyContactGroupsBulkUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact groups bulk update params +func (o *TenancyContactGroupsBulkUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact groups bulk update params +func (o *TenancyContactGroupsBulkUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactGroupsBulkUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact groups bulk update params +func (o *TenancyContactGroupsBulkUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact groups bulk update params +func (o *TenancyContactGroupsBulkUpdateParams) WithData(data *models.WritableContactGroup) *TenancyContactGroupsBulkUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact groups bulk update params +func (o *TenancyContactGroupsBulkUpdateParams) SetData(data *models.WritableContactGroup) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactGroupsBulkUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_bulk_update_responses.go b/netbox/client/tenancy/tenancy_contact_groups_bulk_update_responses.go new file mode 100644 index 00000000..314157bb --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_bulk_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactGroupsBulkUpdateReader is a Reader for the TenancyContactGroupsBulkUpdate structure. +type TenancyContactGroupsBulkUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactGroupsBulkUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactGroupsBulkUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactGroupsBulkUpdateOK creates a TenancyContactGroupsBulkUpdateOK with default headers values +func NewTenancyContactGroupsBulkUpdateOK() *TenancyContactGroupsBulkUpdateOK { + return &TenancyContactGroupsBulkUpdateOK{} +} + +/* TenancyContactGroupsBulkUpdateOK describes a response with status code 200, with default header values. + +TenancyContactGroupsBulkUpdateOK tenancy contact groups bulk update o k +*/ +type TenancyContactGroupsBulkUpdateOK struct { + Payload *models.ContactGroup +} + +func (o *TenancyContactGroupsBulkUpdateOK) Error() string { + return fmt.Sprintf("[PUT /tenancy/contact-groups/][%d] tenancyContactGroupsBulkUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactGroupsBulkUpdateOK) GetPayload() *models.ContactGroup { + return o.Payload +} + +func (o *TenancyContactGroupsBulkUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_create_parameters.go b/netbox/client/tenancy/tenancy_contact_groups_create_parameters.go new file mode 100644 index 00000000..0f3fc333 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_create_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactGroupsCreateParams creates a new TenancyContactGroupsCreateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactGroupsCreateParams() *TenancyContactGroupsCreateParams { + return &TenancyContactGroupsCreateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactGroupsCreateParamsWithTimeout creates a new TenancyContactGroupsCreateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactGroupsCreateParamsWithTimeout(timeout time.Duration) *TenancyContactGroupsCreateParams { + return &TenancyContactGroupsCreateParams{ + timeout: timeout, + } +} + +// NewTenancyContactGroupsCreateParamsWithContext creates a new TenancyContactGroupsCreateParams object +// with the ability to set a context for a request. +func NewTenancyContactGroupsCreateParamsWithContext(ctx context.Context) *TenancyContactGroupsCreateParams { + return &TenancyContactGroupsCreateParams{ + Context: ctx, + } +} + +// NewTenancyContactGroupsCreateParamsWithHTTPClient creates a new TenancyContactGroupsCreateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactGroupsCreateParamsWithHTTPClient(client *http.Client) *TenancyContactGroupsCreateParams { + return &TenancyContactGroupsCreateParams{ + HTTPClient: client, + } +} + +/* TenancyContactGroupsCreateParams contains all the parameters to send to the API endpoint + for the tenancy contact groups create operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactGroupsCreateParams struct { + + // Data. + Data *models.WritableContactGroup + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact groups create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsCreateParams) WithDefaults() *TenancyContactGroupsCreateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact groups create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsCreateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact groups create params +func (o *TenancyContactGroupsCreateParams) WithTimeout(timeout time.Duration) *TenancyContactGroupsCreateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact groups create params +func (o *TenancyContactGroupsCreateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact groups create params +func (o *TenancyContactGroupsCreateParams) WithContext(ctx context.Context) *TenancyContactGroupsCreateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact groups create params +func (o *TenancyContactGroupsCreateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact groups create params +func (o *TenancyContactGroupsCreateParams) WithHTTPClient(client *http.Client) *TenancyContactGroupsCreateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact groups create params +func (o *TenancyContactGroupsCreateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact groups create params +func (o *TenancyContactGroupsCreateParams) WithData(data *models.WritableContactGroup) *TenancyContactGroupsCreateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact groups create params +func (o *TenancyContactGroupsCreateParams) SetData(data *models.WritableContactGroup) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactGroupsCreateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_create_responses.go b/netbox/client/tenancy/tenancy_contact_groups_create_responses.go new file mode 100644 index 00000000..5a09ae21 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_create_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactGroupsCreateReader is a Reader for the TenancyContactGroupsCreate structure. +type TenancyContactGroupsCreateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactGroupsCreateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 201: + result := NewTenancyContactGroupsCreateCreated() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactGroupsCreateCreated creates a TenancyContactGroupsCreateCreated with default headers values +func NewTenancyContactGroupsCreateCreated() *TenancyContactGroupsCreateCreated { + return &TenancyContactGroupsCreateCreated{} +} + +/* TenancyContactGroupsCreateCreated describes a response with status code 201, with default header values. + +TenancyContactGroupsCreateCreated tenancy contact groups create created +*/ +type TenancyContactGroupsCreateCreated struct { + Payload *models.ContactGroup +} + +func (o *TenancyContactGroupsCreateCreated) Error() string { + return fmt.Sprintf("[POST /tenancy/contact-groups/][%d] tenancyContactGroupsCreateCreated %+v", 201, o.Payload) +} +func (o *TenancyContactGroupsCreateCreated) GetPayload() *models.ContactGroup { + return o.Payload +} + +func (o *TenancyContactGroupsCreateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_delete_parameters.go b/netbox/client/tenancy/tenancy_contact_groups_delete_parameters.go new file mode 100644 index 00000000..7dd4ba69 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_delete_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactGroupsDeleteParams creates a new TenancyContactGroupsDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactGroupsDeleteParams() *TenancyContactGroupsDeleteParams { + return &TenancyContactGroupsDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactGroupsDeleteParamsWithTimeout creates a new TenancyContactGroupsDeleteParams object +// with the ability to set a timeout on a request. +func NewTenancyContactGroupsDeleteParamsWithTimeout(timeout time.Duration) *TenancyContactGroupsDeleteParams { + return &TenancyContactGroupsDeleteParams{ + timeout: timeout, + } +} + +// NewTenancyContactGroupsDeleteParamsWithContext creates a new TenancyContactGroupsDeleteParams object +// with the ability to set a context for a request. +func NewTenancyContactGroupsDeleteParamsWithContext(ctx context.Context) *TenancyContactGroupsDeleteParams { + return &TenancyContactGroupsDeleteParams{ + Context: ctx, + } +} + +// NewTenancyContactGroupsDeleteParamsWithHTTPClient creates a new TenancyContactGroupsDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactGroupsDeleteParamsWithHTTPClient(client *http.Client) *TenancyContactGroupsDeleteParams { + return &TenancyContactGroupsDeleteParams{ + HTTPClient: client, + } +} + +/* TenancyContactGroupsDeleteParams contains all the parameters to send to the API endpoint + for the tenancy contact groups delete operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactGroupsDeleteParams struct { + + /* ID. + + A unique integer value identifying this contact group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact groups delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsDeleteParams) WithDefaults() *TenancyContactGroupsDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact groups delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact groups delete params +func (o *TenancyContactGroupsDeleteParams) WithTimeout(timeout time.Duration) *TenancyContactGroupsDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact groups delete params +func (o *TenancyContactGroupsDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact groups delete params +func (o *TenancyContactGroupsDeleteParams) WithContext(ctx context.Context) *TenancyContactGroupsDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact groups delete params +func (o *TenancyContactGroupsDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact groups delete params +func (o *TenancyContactGroupsDeleteParams) WithHTTPClient(client *http.Client) *TenancyContactGroupsDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact groups delete params +func (o *TenancyContactGroupsDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the tenancy contact groups delete params +func (o *TenancyContactGroupsDeleteParams) WithID(id int64) *TenancyContactGroupsDeleteParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact groups delete params +func (o *TenancyContactGroupsDeleteParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactGroupsDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_delete_responses.go b/netbox/client/tenancy/tenancy_contact_groups_delete_responses.go new file mode 100644 index 00000000..7fce0cb1 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// TenancyContactGroupsDeleteReader is a Reader for the TenancyContactGroupsDelete structure. +type TenancyContactGroupsDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactGroupsDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewTenancyContactGroupsDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactGroupsDeleteNoContent creates a TenancyContactGroupsDeleteNoContent with default headers values +func NewTenancyContactGroupsDeleteNoContent() *TenancyContactGroupsDeleteNoContent { + return &TenancyContactGroupsDeleteNoContent{} +} + +/* TenancyContactGroupsDeleteNoContent describes a response with status code 204, with default header values. + +TenancyContactGroupsDeleteNoContent tenancy contact groups delete no content +*/ +type TenancyContactGroupsDeleteNoContent struct { +} + +func (o *TenancyContactGroupsDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /tenancy/contact-groups/{id}/][%d] tenancyContactGroupsDeleteNoContent ", 204) +} + +func (o *TenancyContactGroupsDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_list_parameters.go b/netbox/client/tenancy/tenancy_contact_groups_list_parameters.go new file mode 100644 index 00000000..4c4bb945 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_list_parameters.go @@ -0,0 +1,1823 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactGroupsListParams creates a new TenancyContactGroupsListParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactGroupsListParams() *TenancyContactGroupsListParams { + return &TenancyContactGroupsListParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactGroupsListParamsWithTimeout creates a new TenancyContactGroupsListParams object +// with the ability to set a timeout on a request. +func NewTenancyContactGroupsListParamsWithTimeout(timeout time.Duration) *TenancyContactGroupsListParams { + return &TenancyContactGroupsListParams{ + timeout: timeout, + } +} + +// NewTenancyContactGroupsListParamsWithContext creates a new TenancyContactGroupsListParams object +// with the ability to set a context for a request. +func NewTenancyContactGroupsListParamsWithContext(ctx context.Context) *TenancyContactGroupsListParams { + return &TenancyContactGroupsListParams{ + Context: ctx, + } +} + +// NewTenancyContactGroupsListParamsWithHTTPClient creates a new TenancyContactGroupsListParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactGroupsListParamsWithHTTPClient(client *http.Client) *TenancyContactGroupsListParams { + return &TenancyContactGroupsListParams{ + HTTPClient: client, + } +} + +/* TenancyContactGroupsListParams contains all the parameters to send to the API endpoint + for the tenancy contact groups list operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactGroupsListParams struct { + + // Created. + Created *string + + // CreatedGte. + CreatedGte *string + + // CreatedLte. + CreatedLte *string + + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + + // ID. + ID *string + + // IDGt. + IDGt *string + + // IDGte. + IDGte *string + + // IDLt. + IDLt *string + + // IDLte. + IDLte *string + + // IDn. + IDn *string + + // LastUpdated. + LastUpdated *string + + // LastUpdatedGte. + LastUpdatedGte *string + + // LastUpdatedLte. + LastUpdatedLte *string + + /* Limit. + + Number of results to return per page. + */ + Limit *int64 + + // Name. + Name *string + + // NameEmpty. + NameEmpty *string + + // NameIc. + NameIc *string + + // NameIe. + NameIe *string + + // NameIew. + NameIew *string + + // NameIsw. + NameIsw *string + + // Namen. + Namen *string + + // NameNic. + NameNic *string + + // NameNie. + NameNie *string + + // NameNiew. + NameNiew *string + + // NameNisw. + NameNisw *string + + /* Offset. + + The initial index from which to return the results. + */ + Offset *int64 + + // Parent. + Parent *string + + // Parentn. + Parentn *string + + // ParentID. + ParentID *string + + // ParentIDn. + ParentIDn *string + + // Q. + Q *string + + // Slug. + Slug *string + + // SlugEmpty. + SlugEmpty *string + + // SlugIc. + SlugIc *string + + // SlugIe. + SlugIe *string + + // SlugIew. + SlugIew *string + + // SlugIsw. + SlugIsw *string + + // Slugn. + Slugn *string + + // SlugNic. + SlugNic *string + + // SlugNie. + SlugNie *string + + // SlugNiew. + SlugNiew *string + + // SlugNisw. + SlugNisw *string + + // Tag. + Tag *string + + // Tagn. + Tagn *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact groups list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsListParams) WithDefaults() *TenancyContactGroupsListParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact groups list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsListParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithTimeout(timeout time.Duration) *TenancyContactGroupsListParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithContext(ctx context.Context) *TenancyContactGroupsListParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithHTTPClient(client *http.Client) *TenancyContactGroupsListParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithCreated adds the created to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithCreated(created *string) *TenancyContactGroupsListParams { + o.SetCreated(created) + return o +} + +// SetCreated adds the created to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetCreated(created *string) { + o.Created = created +} + +// WithCreatedGte adds the createdGte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithCreatedGte(createdGte *string) *TenancyContactGroupsListParams { + o.SetCreatedGte(createdGte) + return o +} + +// SetCreatedGte adds the createdGte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetCreatedGte(createdGte *string) { + o.CreatedGte = createdGte +} + +// WithCreatedLte adds the createdLte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithCreatedLte(createdLte *string) *TenancyContactGroupsListParams { + o.SetCreatedLte(createdLte) + return o +} + +// SetCreatedLte adds the createdLte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetCreatedLte(createdLte *string) { + o.CreatedLte = createdLte +} + +// WithDescription adds the description to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithDescription(description *string) *TenancyContactGroupsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithDescriptionEmpty(descriptionEmpty *string) *TenancyContactGroupsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithDescriptionIc(descriptionIc *string) *TenancyContactGroupsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithDescriptionIe(descriptionIe *string) *TenancyContactGroupsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithDescriptionIew(descriptionIew *string) *TenancyContactGroupsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithDescriptionIsw(descriptionIsw *string) *TenancyContactGroupsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithDescriptionn(descriptionn *string) *TenancyContactGroupsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithDescriptionNic(descriptionNic *string) *TenancyContactGroupsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithDescriptionNie(descriptionNie *string) *TenancyContactGroupsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithDescriptionNiew(descriptionNiew *string) *TenancyContactGroupsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithDescriptionNisw(descriptionNisw *string) *TenancyContactGroupsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + +// WithID adds the id to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithID(id *string) *TenancyContactGroupsListParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetID(id *string) { + o.ID = id +} + +// WithIDGt adds the iDGt to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithIDGt(iDGt *string) *TenancyContactGroupsListParams { + o.SetIDGt(iDGt) + return o +} + +// SetIDGt adds the idGt to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetIDGt(iDGt *string) { + o.IDGt = iDGt +} + +// WithIDGte adds the iDGte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithIDGte(iDGte *string) *TenancyContactGroupsListParams { + o.SetIDGte(iDGte) + return o +} + +// SetIDGte adds the idGte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetIDGte(iDGte *string) { + o.IDGte = iDGte +} + +// WithIDLt adds the iDLt to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithIDLt(iDLt *string) *TenancyContactGroupsListParams { + o.SetIDLt(iDLt) + return o +} + +// SetIDLt adds the idLt to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetIDLt(iDLt *string) { + o.IDLt = iDLt +} + +// WithIDLte adds the iDLte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithIDLte(iDLte *string) *TenancyContactGroupsListParams { + o.SetIDLte(iDLte) + return o +} + +// SetIDLte adds the idLte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetIDLte(iDLte *string) { + o.IDLte = iDLte +} + +// WithIDn adds the iDn to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithIDn(iDn *string) *TenancyContactGroupsListParams { + o.SetIDn(iDn) + return o +} + +// SetIDn adds the idN to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetIDn(iDn *string) { + o.IDn = iDn +} + +// WithLastUpdated adds the lastUpdated to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithLastUpdated(lastUpdated *string) *TenancyContactGroupsListParams { + o.SetLastUpdated(lastUpdated) + return o +} + +// SetLastUpdated adds the lastUpdated to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetLastUpdated(lastUpdated *string) { + o.LastUpdated = lastUpdated +} + +// WithLastUpdatedGte adds the lastUpdatedGte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithLastUpdatedGte(lastUpdatedGte *string) *TenancyContactGroupsListParams { + o.SetLastUpdatedGte(lastUpdatedGte) + return o +} + +// SetLastUpdatedGte adds the lastUpdatedGte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetLastUpdatedGte(lastUpdatedGte *string) { + o.LastUpdatedGte = lastUpdatedGte +} + +// WithLastUpdatedLte adds the lastUpdatedLte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithLastUpdatedLte(lastUpdatedLte *string) *TenancyContactGroupsListParams { + o.SetLastUpdatedLte(lastUpdatedLte) + return o +} + +// SetLastUpdatedLte adds the lastUpdatedLte to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetLastUpdatedLte(lastUpdatedLte *string) { + o.LastUpdatedLte = lastUpdatedLte +} + +// WithLimit adds the limit to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithLimit(limit *int64) *TenancyContactGroupsListParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithName adds the name to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithName(name *string) *TenancyContactGroupsListParams { + o.SetName(name) + return o +} + +// SetName adds the name to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetName(name *string) { + o.Name = name +} + +// WithNameEmpty adds the nameEmpty to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithNameEmpty(nameEmpty *string) *TenancyContactGroupsListParams { + o.SetNameEmpty(nameEmpty) + return o +} + +// SetNameEmpty adds the nameEmpty to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetNameEmpty(nameEmpty *string) { + o.NameEmpty = nameEmpty +} + +// WithNameIc adds the nameIc to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithNameIc(nameIc *string) *TenancyContactGroupsListParams { + o.SetNameIc(nameIc) + return o +} + +// SetNameIc adds the nameIc to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetNameIc(nameIc *string) { + o.NameIc = nameIc +} + +// WithNameIe adds the nameIe to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithNameIe(nameIe *string) *TenancyContactGroupsListParams { + o.SetNameIe(nameIe) + return o +} + +// SetNameIe adds the nameIe to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetNameIe(nameIe *string) { + o.NameIe = nameIe +} + +// WithNameIew adds the nameIew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithNameIew(nameIew *string) *TenancyContactGroupsListParams { + o.SetNameIew(nameIew) + return o +} + +// SetNameIew adds the nameIew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetNameIew(nameIew *string) { + o.NameIew = nameIew +} + +// WithNameIsw adds the nameIsw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithNameIsw(nameIsw *string) *TenancyContactGroupsListParams { + o.SetNameIsw(nameIsw) + return o +} + +// SetNameIsw adds the nameIsw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetNameIsw(nameIsw *string) { + o.NameIsw = nameIsw +} + +// WithNamen adds the namen to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithNamen(namen *string) *TenancyContactGroupsListParams { + o.SetNamen(namen) + return o +} + +// SetNamen adds the nameN to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetNamen(namen *string) { + o.Namen = namen +} + +// WithNameNic adds the nameNic to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithNameNic(nameNic *string) *TenancyContactGroupsListParams { + o.SetNameNic(nameNic) + return o +} + +// SetNameNic adds the nameNic to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetNameNic(nameNic *string) { + o.NameNic = nameNic +} + +// WithNameNie adds the nameNie to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithNameNie(nameNie *string) *TenancyContactGroupsListParams { + o.SetNameNie(nameNie) + return o +} + +// SetNameNie adds the nameNie to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetNameNie(nameNie *string) { + o.NameNie = nameNie +} + +// WithNameNiew adds the nameNiew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithNameNiew(nameNiew *string) *TenancyContactGroupsListParams { + o.SetNameNiew(nameNiew) + return o +} + +// SetNameNiew adds the nameNiew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetNameNiew(nameNiew *string) { + o.NameNiew = nameNiew +} + +// WithNameNisw adds the nameNisw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithNameNisw(nameNisw *string) *TenancyContactGroupsListParams { + o.SetNameNisw(nameNisw) + return o +} + +// SetNameNisw adds the nameNisw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetNameNisw(nameNisw *string) { + o.NameNisw = nameNisw +} + +// WithOffset adds the offset to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithOffset(offset *int64) *TenancyContactGroupsListParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithParent adds the parent to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithParent(parent *string) *TenancyContactGroupsListParams { + o.SetParent(parent) + return o +} + +// SetParent adds the parent to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetParent(parent *string) { + o.Parent = parent +} + +// WithParentn adds the parentn to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithParentn(parentn *string) *TenancyContactGroupsListParams { + o.SetParentn(parentn) + return o +} + +// SetParentn adds the parentN to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetParentn(parentn *string) { + o.Parentn = parentn +} + +// WithParentID adds the parentID to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithParentID(parentID *string) *TenancyContactGroupsListParams { + o.SetParentID(parentID) + return o +} + +// SetParentID adds the parentId to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetParentID(parentID *string) { + o.ParentID = parentID +} + +// WithParentIDn adds the parentIDn to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithParentIDn(parentIDn *string) *TenancyContactGroupsListParams { + o.SetParentIDn(parentIDn) + return o +} + +// SetParentIDn adds the parentIdN to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetParentIDn(parentIDn *string) { + o.ParentIDn = parentIDn +} + +// WithQ adds the q to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithQ(q *string) *TenancyContactGroupsListParams { + o.SetQ(q) + return o +} + +// SetQ adds the q to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetQ(q *string) { + o.Q = q +} + +// WithSlug adds the slug to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithSlug(slug *string) *TenancyContactGroupsListParams { + o.SetSlug(slug) + return o +} + +// SetSlug adds the slug to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetSlug(slug *string) { + o.Slug = slug +} + +// WithSlugEmpty adds the slugEmpty to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithSlugEmpty(slugEmpty *string) *TenancyContactGroupsListParams { + o.SetSlugEmpty(slugEmpty) + return o +} + +// SetSlugEmpty adds the slugEmpty to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetSlugEmpty(slugEmpty *string) { + o.SlugEmpty = slugEmpty +} + +// WithSlugIc adds the slugIc to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithSlugIc(slugIc *string) *TenancyContactGroupsListParams { + o.SetSlugIc(slugIc) + return o +} + +// SetSlugIc adds the slugIc to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetSlugIc(slugIc *string) { + o.SlugIc = slugIc +} + +// WithSlugIe adds the slugIe to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithSlugIe(slugIe *string) *TenancyContactGroupsListParams { + o.SetSlugIe(slugIe) + return o +} + +// SetSlugIe adds the slugIe to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetSlugIe(slugIe *string) { + o.SlugIe = slugIe +} + +// WithSlugIew adds the slugIew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithSlugIew(slugIew *string) *TenancyContactGroupsListParams { + o.SetSlugIew(slugIew) + return o +} + +// SetSlugIew adds the slugIew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetSlugIew(slugIew *string) { + o.SlugIew = slugIew +} + +// WithSlugIsw adds the slugIsw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithSlugIsw(slugIsw *string) *TenancyContactGroupsListParams { + o.SetSlugIsw(slugIsw) + return o +} + +// SetSlugIsw adds the slugIsw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetSlugIsw(slugIsw *string) { + o.SlugIsw = slugIsw +} + +// WithSlugn adds the slugn to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithSlugn(slugn *string) *TenancyContactGroupsListParams { + o.SetSlugn(slugn) + return o +} + +// SetSlugn adds the slugN to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetSlugn(slugn *string) { + o.Slugn = slugn +} + +// WithSlugNic adds the slugNic to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithSlugNic(slugNic *string) *TenancyContactGroupsListParams { + o.SetSlugNic(slugNic) + return o +} + +// SetSlugNic adds the slugNic to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetSlugNic(slugNic *string) { + o.SlugNic = slugNic +} + +// WithSlugNie adds the slugNie to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithSlugNie(slugNie *string) *TenancyContactGroupsListParams { + o.SetSlugNie(slugNie) + return o +} + +// SetSlugNie adds the slugNie to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetSlugNie(slugNie *string) { + o.SlugNie = slugNie +} + +// WithSlugNiew adds the slugNiew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithSlugNiew(slugNiew *string) *TenancyContactGroupsListParams { + o.SetSlugNiew(slugNiew) + return o +} + +// SetSlugNiew adds the slugNiew to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetSlugNiew(slugNiew *string) { + o.SlugNiew = slugNiew +} + +// WithSlugNisw adds the slugNisw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithSlugNisw(slugNisw *string) *TenancyContactGroupsListParams { + o.SetSlugNisw(slugNisw) + return o +} + +// SetSlugNisw adds the slugNisw to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetSlugNisw(slugNisw *string) { + o.SlugNisw = slugNisw +} + +// WithTag adds the tag to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithTag(tag *string) *TenancyContactGroupsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) WithTagn(tagn *string) *TenancyContactGroupsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the tenancy contact groups list params +func (o *TenancyContactGroupsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactGroupsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.Created != nil { + + // query param created + var qrCreated string + + if o.Created != nil { + qrCreated = *o.Created + } + qCreated := qrCreated + if qCreated != "" { + + if err := r.SetQueryParam("created", qCreated); err != nil { + return err + } + } + } + + if o.CreatedGte != nil { + + // query param created__gte + var qrCreatedGte string + + if o.CreatedGte != nil { + qrCreatedGte = *o.CreatedGte + } + qCreatedGte := qrCreatedGte + if qCreatedGte != "" { + + if err := r.SetQueryParam("created__gte", qCreatedGte); err != nil { + return err + } + } + } + + if o.CreatedLte != nil { + + // query param created__lte + var qrCreatedLte string + + if o.CreatedLte != nil { + qrCreatedLte = *o.CreatedLte + } + qCreatedLte := qrCreatedLte + if qCreatedLte != "" { + + if err := r.SetQueryParam("created__lte", qCreatedLte); err != nil { + return err + } + } + } + + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + + if o.ID != nil { + + // query param id + var qrID string + + if o.ID != nil { + qrID = *o.ID + } + qID := qrID + if qID != "" { + + if err := r.SetQueryParam("id", qID); err != nil { + return err + } + } + } + + if o.IDGt != nil { + + // query param id__gt + var qrIDGt string + + if o.IDGt != nil { + qrIDGt = *o.IDGt + } + qIDGt := qrIDGt + if qIDGt != "" { + + if err := r.SetQueryParam("id__gt", qIDGt); err != nil { + return err + } + } + } + + if o.IDGte != nil { + + // query param id__gte + var qrIDGte string + + if o.IDGte != nil { + qrIDGte = *o.IDGte + } + qIDGte := qrIDGte + if qIDGte != "" { + + if err := r.SetQueryParam("id__gte", qIDGte); err != nil { + return err + } + } + } + + if o.IDLt != nil { + + // query param id__lt + var qrIDLt string + + if o.IDLt != nil { + qrIDLt = *o.IDLt + } + qIDLt := qrIDLt + if qIDLt != "" { + + if err := r.SetQueryParam("id__lt", qIDLt); err != nil { + return err + } + } + } + + if o.IDLte != nil { + + // query param id__lte + var qrIDLte string + + if o.IDLte != nil { + qrIDLte = *o.IDLte + } + qIDLte := qrIDLte + if qIDLte != "" { + + if err := r.SetQueryParam("id__lte", qIDLte); err != nil { + return err + } + } + } + + if o.IDn != nil { + + // query param id__n + var qrIDn string + + if o.IDn != nil { + qrIDn = *o.IDn + } + qIDn := qrIDn + if qIDn != "" { + + if err := r.SetQueryParam("id__n", qIDn); err != nil { + return err + } + } + } + + if o.LastUpdated != nil { + + // query param last_updated + var qrLastUpdated string + + if o.LastUpdated != nil { + qrLastUpdated = *o.LastUpdated + } + qLastUpdated := qrLastUpdated + if qLastUpdated != "" { + + if err := r.SetQueryParam("last_updated", qLastUpdated); err != nil { + return err + } + } + } + + if o.LastUpdatedGte != nil { + + // query param last_updated__gte + var qrLastUpdatedGte string + + if o.LastUpdatedGte != nil { + qrLastUpdatedGte = *o.LastUpdatedGte + } + qLastUpdatedGte := qrLastUpdatedGte + if qLastUpdatedGte != "" { + + if err := r.SetQueryParam("last_updated__gte", qLastUpdatedGte); err != nil { + return err + } + } + } + + if o.LastUpdatedLte != nil { + + // query param last_updated__lte + var qrLastUpdatedLte string + + if o.LastUpdatedLte != nil { + qrLastUpdatedLte = *o.LastUpdatedLte + } + qLastUpdatedLte := qrLastUpdatedLte + if qLastUpdatedLte != "" { + + if err := r.SetQueryParam("last_updated__lte", qLastUpdatedLte); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Name != nil { + + // query param name + var qrName string + + if o.Name != nil { + qrName = *o.Name + } + qName := qrName + if qName != "" { + + if err := r.SetQueryParam("name", qName); err != nil { + return err + } + } + } + + if o.NameEmpty != nil { + + // query param name__empty + var qrNameEmpty string + + if o.NameEmpty != nil { + qrNameEmpty = *o.NameEmpty + } + qNameEmpty := qrNameEmpty + if qNameEmpty != "" { + + if err := r.SetQueryParam("name__empty", qNameEmpty); err != nil { + return err + } + } + } + + if o.NameIc != nil { + + // query param name__ic + var qrNameIc string + + if o.NameIc != nil { + qrNameIc = *o.NameIc + } + qNameIc := qrNameIc + if qNameIc != "" { + + if err := r.SetQueryParam("name__ic", qNameIc); err != nil { + return err + } + } + } + + if o.NameIe != nil { + + // query param name__ie + var qrNameIe string + + if o.NameIe != nil { + qrNameIe = *o.NameIe + } + qNameIe := qrNameIe + if qNameIe != "" { + + if err := r.SetQueryParam("name__ie", qNameIe); err != nil { + return err + } + } + } + + if o.NameIew != nil { + + // query param name__iew + var qrNameIew string + + if o.NameIew != nil { + qrNameIew = *o.NameIew + } + qNameIew := qrNameIew + if qNameIew != "" { + + if err := r.SetQueryParam("name__iew", qNameIew); err != nil { + return err + } + } + } + + if o.NameIsw != nil { + + // query param name__isw + var qrNameIsw string + + if o.NameIsw != nil { + qrNameIsw = *o.NameIsw + } + qNameIsw := qrNameIsw + if qNameIsw != "" { + + if err := r.SetQueryParam("name__isw", qNameIsw); err != nil { + return err + } + } + } + + if o.Namen != nil { + + // query param name__n + var qrNamen string + + if o.Namen != nil { + qrNamen = *o.Namen + } + qNamen := qrNamen + if qNamen != "" { + + if err := r.SetQueryParam("name__n", qNamen); err != nil { + return err + } + } + } + + if o.NameNic != nil { + + // query param name__nic + var qrNameNic string + + if o.NameNic != nil { + qrNameNic = *o.NameNic + } + qNameNic := qrNameNic + if qNameNic != "" { + + if err := r.SetQueryParam("name__nic", qNameNic); err != nil { + return err + } + } + } + + if o.NameNie != nil { + + // query param name__nie + var qrNameNie string + + if o.NameNie != nil { + qrNameNie = *o.NameNie + } + qNameNie := qrNameNie + if qNameNie != "" { + + if err := r.SetQueryParam("name__nie", qNameNie); err != nil { + return err + } + } + } + + if o.NameNiew != nil { + + // query param name__niew + var qrNameNiew string + + if o.NameNiew != nil { + qrNameNiew = *o.NameNiew + } + qNameNiew := qrNameNiew + if qNameNiew != "" { + + if err := r.SetQueryParam("name__niew", qNameNiew); err != nil { + return err + } + } + } + + if o.NameNisw != nil { + + // query param name__nisw + var qrNameNisw string + + if o.NameNisw != nil { + qrNameNisw = *o.NameNisw + } + qNameNisw := qrNameNisw + if qNameNisw != "" { + + if err := r.SetQueryParam("name__nisw", qNameNisw); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.Parent != nil { + + // query param parent + var qrParent string + + if o.Parent != nil { + qrParent = *o.Parent + } + qParent := qrParent + if qParent != "" { + + if err := r.SetQueryParam("parent", qParent); err != nil { + return err + } + } + } + + if o.Parentn != nil { + + // query param parent__n + var qrParentn string + + if o.Parentn != nil { + qrParentn = *o.Parentn + } + qParentn := qrParentn + if qParentn != "" { + + if err := r.SetQueryParam("parent__n", qParentn); err != nil { + return err + } + } + } + + if o.ParentID != nil { + + // query param parent_id + var qrParentID string + + if o.ParentID != nil { + qrParentID = *o.ParentID + } + qParentID := qrParentID + if qParentID != "" { + + if err := r.SetQueryParam("parent_id", qParentID); err != nil { + return err + } + } + } + + if o.ParentIDn != nil { + + // query param parent_id__n + var qrParentIDn string + + if o.ParentIDn != nil { + qrParentIDn = *o.ParentIDn + } + qParentIDn := qrParentIDn + if qParentIDn != "" { + + if err := r.SetQueryParam("parent_id__n", qParentIDn); err != nil { + return err + } + } + } + + if o.Q != nil { + + // query param q + var qrQ string + + if o.Q != nil { + qrQ = *o.Q + } + qQ := qrQ + if qQ != "" { + + if err := r.SetQueryParam("q", qQ); err != nil { + return err + } + } + } + + if o.Slug != nil { + + // query param slug + var qrSlug string + + if o.Slug != nil { + qrSlug = *o.Slug + } + qSlug := qrSlug + if qSlug != "" { + + if err := r.SetQueryParam("slug", qSlug); err != nil { + return err + } + } + } + + if o.SlugEmpty != nil { + + // query param slug__empty + var qrSlugEmpty string + + if o.SlugEmpty != nil { + qrSlugEmpty = *o.SlugEmpty + } + qSlugEmpty := qrSlugEmpty + if qSlugEmpty != "" { + + if err := r.SetQueryParam("slug__empty", qSlugEmpty); err != nil { + return err + } + } + } + + if o.SlugIc != nil { + + // query param slug__ic + var qrSlugIc string + + if o.SlugIc != nil { + qrSlugIc = *o.SlugIc + } + qSlugIc := qrSlugIc + if qSlugIc != "" { + + if err := r.SetQueryParam("slug__ic", qSlugIc); err != nil { + return err + } + } + } + + if o.SlugIe != nil { + + // query param slug__ie + var qrSlugIe string + + if o.SlugIe != nil { + qrSlugIe = *o.SlugIe + } + qSlugIe := qrSlugIe + if qSlugIe != "" { + + if err := r.SetQueryParam("slug__ie", qSlugIe); err != nil { + return err + } + } + } + + if o.SlugIew != nil { + + // query param slug__iew + var qrSlugIew string + + if o.SlugIew != nil { + qrSlugIew = *o.SlugIew + } + qSlugIew := qrSlugIew + if qSlugIew != "" { + + if err := r.SetQueryParam("slug__iew", qSlugIew); err != nil { + return err + } + } + } + + if o.SlugIsw != nil { + + // query param slug__isw + var qrSlugIsw string + + if o.SlugIsw != nil { + qrSlugIsw = *o.SlugIsw + } + qSlugIsw := qrSlugIsw + if qSlugIsw != "" { + + if err := r.SetQueryParam("slug__isw", qSlugIsw); err != nil { + return err + } + } + } + + if o.Slugn != nil { + + // query param slug__n + var qrSlugn string + + if o.Slugn != nil { + qrSlugn = *o.Slugn + } + qSlugn := qrSlugn + if qSlugn != "" { + + if err := r.SetQueryParam("slug__n", qSlugn); err != nil { + return err + } + } + } + + if o.SlugNic != nil { + + // query param slug__nic + var qrSlugNic string + + if o.SlugNic != nil { + qrSlugNic = *o.SlugNic + } + qSlugNic := qrSlugNic + if qSlugNic != "" { + + if err := r.SetQueryParam("slug__nic", qSlugNic); err != nil { + return err + } + } + } + + if o.SlugNie != nil { + + // query param slug__nie + var qrSlugNie string + + if o.SlugNie != nil { + qrSlugNie = *o.SlugNie + } + qSlugNie := qrSlugNie + if qSlugNie != "" { + + if err := r.SetQueryParam("slug__nie", qSlugNie); err != nil { + return err + } + } + } + + if o.SlugNiew != nil { + + // query param slug__niew + var qrSlugNiew string + + if o.SlugNiew != nil { + qrSlugNiew = *o.SlugNiew + } + qSlugNiew := qrSlugNiew + if qSlugNiew != "" { + + if err := r.SetQueryParam("slug__niew", qSlugNiew); err != nil { + return err + } + } + } + + if o.SlugNisw != nil { + + // query param slug__nisw + var qrSlugNisw string + + if o.SlugNisw != nil { + qrSlugNisw = *o.SlugNisw + } + qSlugNisw := qrSlugNisw + if qSlugNisw != "" { + + if err := r.SetQueryParam("slug__nisw", qSlugNisw); err != nil { + return err + } + } + } + + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_list_responses.go b/netbox/client/tenancy/tenancy_contact_groups_list_responses.go new file mode 100644 index 00000000..7169c60a --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_list_responses.go @@ -0,0 +1,247 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactGroupsListReader is a Reader for the TenancyContactGroupsList structure. +type TenancyContactGroupsListReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactGroupsListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactGroupsListOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactGroupsListOK creates a TenancyContactGroupsListOK with default headers values +func NewTenancyContactGroupsListOK() *TenancyContactGroupsListOK { + return &TenancyContactGroupsListOK{} +} + +/* TenancyContactGroupsListOK describes a response with status code 200, with default header values. + +TenancyContactGroupsListOK tenancy contact groups list o k +*/ +type TenancyContactGroupsListOK struct { + Payload *TenancyContactGroupsListOKBody +} + +func (o *TenancyContactGroupsListOK) Error() string { + return fmt.Sprintf("[GET /tenancy/contact-groups/][%d] tenancyContactGroupsListOK %+v", 200, o.Payload) +} +func (o *TenancyContactGroupsListOK) GetPayload() *TenancyContactGroupsListOKBody { + return o.Payload +} + +func (o *TenancyContactGroupsListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(TenancyContactGroupsListOKBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*TenancyContactGroupsListOKBody tenancy contact groups list o k body +swagger:model TenancyContactGroupsListOKBody +*/ +type TenancyContactGroupsListOKBody struct { + + // count + // Required: true + Count *int64 `json:"count"` + + // next + // Format: uri + Next *strfmt.URI `json:"next,omitempty"` + + // previous + // Format: uri + Previous *strfmt.URI `json:"previous,omitempty"` + + // results + // Required: true + Results []*models.ContactGroup `json:"results"` +} + +// Validate validates this tenancy contact groups list o k body +func (o *TenancyContactGroupsListOKBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateCount(formats); err != nil { + res = append(res, err) + } + + if err := o.validateNext(formats); err != nil { + res = append(res, err) + } + + if err := o.validatePrevious(formats); err != nil { + res = append(res, err) + } + + if err := o.validateResults(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *TenancyContactGroupsListOKBody) validateCount(formats strfmt.Registry) error { + + if err := validate.Required("tenancyContactGroupsListOK"+"."+"count", "body", o.Count); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactGroupsListOKBody) validateNext(formats strfmt.Registry) error { + if swag.IsZero(o.Next) { // not required + return nil + } + + if err := validate.FormatOf("tenancyContactGroupsListOK"+"."+"next", "body", "uri", o.Next.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactGroupsListOKBody) validatePrevious(formats strfmt.Registry) error { + if swag.IsZero(o.Previous) { // not required + return nil + } + + if err := validate.FormatOf("tenancyContactGroupsListOK"+"."+"previous", "body", "uri", o.Previous.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactGroupsListOKBody) validateResults(formats strfmt.Registry) error { + + if err := validate.Required("tenancyContactGroupsListOK"+"."+"results", "body", o.Results); err != nil { + return err + } + + for i := 0; i < len(o.Results); i++ { + if swag.IsZero(o.Results[i]) { // not required + continue + } + + if o.Results[i] != nil { + if err := o.Results[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenancyContactGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenancyContactGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this tenancy contact groups list o k body based on the context it is used +func (o *TenancyContactGroupsListOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := o.contextValidateResults(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *TenancyContactGroupsListOKBody) contextValidateResults(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(o.Results); i++ { + + if o.Results[i] != nil { + if err := o.Results[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenancyContactGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenancyContactGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (o *TenancyContactGroupsListOKBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *TenancyContactGroupsListOKBody) UnmarshalBinary(b []byte) error { + var res TenancyContactGroupsListOKBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_partial_update_parameters.go b/netbox/client/tenancy/tenancy_contact_groups_partial_update_parameters.go new file mode 100644 index 00000000..e2004ae0 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_partial_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactGroupsPartialUpdateParams creates a new TenancyContactGroupsPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactGroupsPartialUpdateParams() *TenancyContactGroupsPartialUpdateParams { + return &TenancyContactGroupsPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactGroupsPartialUpdateParamsWithTimeout creates a new TenancyContactGroupsPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactGroupsPartialUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactGroupsPartialUpdateParams { + return &TenancyContactGroupsPartialUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactGroupsPartialUpdateParamsWithContext creates a new TenancyContactGroupsPartialUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactGroupsPartialUpdateParamsWithContext(ctx context.Context) *TenancyContactGroupsPartialUpdateParams { + return &TenancyContactGroupsPartialUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactGroupsPartialUpdateParamsWithHTTPClient creates a new TenancyContactGroupsPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactGroupsPartialUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactGroupsPartialUpdateParams { + return &TenancyContactGroupsPartialUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactGroupsPartialUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact groups partial update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactGroupsPartialUpdateParams struct { + + // Data. + Data *models.WritableContactGroup + + /* ID. + + A unique integer value identifying this contact group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact groups partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsPartialUpdateParams) WithDefaults() *TenancyContactGroupsPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact groups partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact groups partial update params +func (o *TenancyContactGroupsPartialUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactGroupsPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact groups partial update params +func (o *TenancyContactGroupsPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact groups partial update params +func (o *TenancyContactGroupsPartialUpdateParams) WithContext(ctx context.Context) *TenancyContactGroupsPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact groups partial update params +func (o *TenancyContactGroupsPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact groups partial update params +func (o *TenancyContactGroupsPartialUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactGroupsPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact groups partial update params +func (o *TenancyContactGroupsPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact groups partial update params +func (o *TenancyContactGroupsPartialUpdateParams) WithData(data *models.WritableContactGroup) *TenancyContactGroupsPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact groups partial update params +func (o *TenancyContactGroupsPartialUpdateParams) SetData(data *models.WritableContactGroup) { + o.Data = data +} + +// WithID adds the id to the tenancy contact groups partial update params +func (o *TenancyContactGroupsPartialUpdateParams) WithID(id int64) *TenancyContactGroupsPartialUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact groups partial update params +func (o *TenancyContactGroupsPartialUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactGroupsPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_partial_update_responses.go b/netbox/client/tenancy/tenancy_contact_groups_partial_update_responses.go new file mode 100644 index 00000000..44526b4c --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactGroupsPartialUpdateReader is a Reader for the TenancyContactGroupsPartialUpdate structure. +type TenancyContactGroupsPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactGroupsPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactGroupsPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactGroupsPartialUpdateOK creates a TenancyContactGroupsPartialUpdateOK with default headers values +func NewTenancyContactGroupsPartialUpdateOK() *TenancyContactGroupsPartialUpdateOK { + return &TenancyContactGroupsPartialUpdateOK{} +} + +/* TenancyContactGroupsPartialUpdateOK describes a response with status code 200, with default header values. + +TenancyContactGroupsPartialUpdateOK tenancy contact groups partial update o k +*/ +type TenancyContactGroupsPartialUpdateOK struct { + Payload *models.ContactGroup +} + +func (o *TenancyContactGroupsPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /tenancy/contact-groups/{id}/][%d] tenancyContactGroupsPartialUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactGroupsPartialUpdateOK) GetPayload() *models.ContactGroup { + return o.Payload +} + +func (o *TenancyContactGroupsPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_read_parameters.go b/netbox/client/tenancy/tenancy_contact_groups_read_parameters.go new file mode 100644 index 00000000..2a4f0d38 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_read_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactGroupsReadParams creates a new TenancyContactGroupsReadParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactGroupsReadParams() *TenancyContactGroupsReadParams { + return &TenancyContactGroupsReadParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactGroupsReadParamsWithTimeout creates a new TenancyContactGroupsReadParams object +// with the ability to set a timeout on a request. +func NewTenancyContactGroupsReadParamsWithTimeout(timeout time.Duration) *TenancyContactGroupsReadParams { + return &TenancyContactGroupsReadParams{ + timeout: timeout, + } +} + +// NewTenancyContactGroupsReadParamsWithContext creates a new TenancyContactGroupsReadParams object +// with the ability to set a context for a request. +func NewTenancyContactGroupsReadParamsWithContext(ctx context.Context) *TenancyContactGroupsReadParams { + return &TenancyContactGroupsReadParams{ + Context: ctx, + } +} + +// NewTenancyContactGroupsReadParamsWithHTTPClient creates a new TenancyContactGroupsReadParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactGroupsReadParamsWithHTTPClient(client *http.Client) *TenancyContactGroupsReadParams { + return &TenancyContactGroupsReadParams{ + HTTPClient: client, + } +} + +/* TenancyContactGroupsReadParams contains all the parameters to send to the API endpoint + for the tenancy contact groups read operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactGroupsReadParams struct { + + /* ID. + + A unique integer value identifying this contact group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact groups read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsReadParams) WithDefaults() *TenancyContactGroupsReadParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact groups read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsReadParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact groups read params +func (o *TenancyContactGroupsReadParams) WithTimeout(timeout time.Duration) *TenancyContactGroupsReadParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact groups read params +func (o *TenancyContactGroupsReadParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact groups read params +func (o *TenancyContactGroupsReadParams) WithContext(ctx context.Context) *TenancyContactGroupsReadParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact groups read params +func (o *TenancyContactGroupsReadParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact groups read params +func (o *TenancyContactGroupsReadParams) WithHTTPClient(client *http.Client) *TenancyContactGroupsReadParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact groups read params +func (o *TenancyContactGroupsReadParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the tenancy contact groups read params +func (o *TenancyContactGroupsReadParams) WithID(id int64) *TenancyContactGroupsReadParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact groups read params +func (o *TenancyContactGroupsReadParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactGroupsReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_read_responses.go b/netbox/client/tenancy/tenancy_contact_groups_read_responses.go new file mode 100644 index 00000000..b6382e33 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_read_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactGroupsReadReader is a Reader for the TenancyContactGroupsRead structure. +type TenancyContactGroupsReadReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactGroupsReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactGroupsReadOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactGroupsReadOK creates a TenancyContactGroupsReadOK with default headers values +func NewTenancyContactGroupsReadOK() *TenancyContactGroupsReadOK { + return &TenancyContactGroupsReadOK{} +} + +/* TenancyContactGroupsReadOK describes a response with status code 200, with default header values. + +TenancyContactGroupsReadOK tenancy contact groups read o k +*/ +type TenancyContactGroupsReadOK struct { + Payload *models.ContactGroup +} + +func (o *TenancyContactGroupsReadOK) Error() string { + return fmt.Sprintf("[GET /tenancy/contact-groups/{id}/][%d] tenancyContactGroupsReadOK %+v", 200, o.Payload) +} +func (o *TenancyContactGroupsReadOK) GetPayload() *models.ContactGroup { + return o.Payload +} + +func (o *TenancyContactGroupsReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_update_parameters.go b/netbox/client/tenancy/tenancy_contact_groups_update_parameters.go new file mode 100644 index 00000000..cec51521 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactGroupsUpdateParams creates a new TenancyContactGroupsUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactGroupsUpdateParams() *TenancyContactGroupsUpdateParams { + return &TenancyContactGroupsUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactGroupsUpdateParamsWithTimeout creates a new TenancyContactGroupsUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactGroupsUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactGroupsUpdateParams { + return &TenancyContactGroupsUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactGroupsUpdateParamsWithContext creates a new TenancyContactGroupsUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactGroupsUpdateParamsWithContext(ctx context.Context) *TenancyContactGroupsUpdateParams { + return &TenancyContactGroupsUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactGroupsUpdateParamsWithHTTPClient creates a new TenancyContactGroupsUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactGroupsUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactGroupsUpdateParams { + return &TenancyContactGroupsUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactGroupsUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact groups update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactGroupsUpdateParams struct { + + // Data. + Data *models.WritableContactGroup + + /* ID. + + A unique integer value identifying this contact group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact groups update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsUpdateParams) WithDefaults() *TenancyContactGroupsUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact groups update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactGroupsUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact groups update params +func (o *TenancyContactGroupsUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactGroupsUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact groups update params +func (o *TenancyContactGroupsUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact groups update params +func (o *TenancyContactGroupsUpdateParams) WithContext(ctx context.Context) *TenancyContactGroupsUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact groups update params +func (o *TenancyContactGroupsUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact groups update params +func (o *TenancyContactGroupsUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactGroupsUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact groups update params +func (o *TenancyContactGroupsUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact groups update params +func (o *TenancyContactGroupsUpdateParams) WithData(data *models.WritableContactGroup) *TenancyContactGroupsUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact groups update params +func (o *TenancyContactGroupsUpdateParams) SetData(data *models.WritableContactGroup) { + o.Data = data +} + +// WithID adds the id to the tenancy contact groups update params +func (o *TenancyContactGroupsUpdateParams) WithID(id int64) *TenancyContactGroupsUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact groups update params +func (o *TenancyContactGroupsUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactGroupsUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_groups_update_responses.go b/netbox/client/tenancy/tenancy_contact_groups_update_responses.go new file mode 100644 index 00000000..024899ad --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_groups_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactGroupsUpdateReader is a Reader for the TenancyContactGroupsUpdate structure. +type TenancyContactGroupsUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactGroupsUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactGroupsUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactGroupsUpdateOK creates a TenancyContactGroupsUpdateOK with default headers values +func NewTenancyContactGroupsUpdateOK() *TenancyContactGroupsUpdateOK { + return &TenancyContactGroupsUpdateOK{} +} + +/* TenancyContactGroupsUpdateOK describes a response with status code 200, with default header values. + +TenancyContactGroupsUpdateOK tenancy contact groups update o k +*/ +type TenancyContactGroupsUpdateOK struct { + Payload *models.ContactGroup +} + +func (o *TenancyContactGroupsUpdateOK) Error() string { + return fmt.Sprintf("[PUT /tenancy/contact-groups/{id}/][%d] tenancyContactGroupsUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactGroupsUpdateOK) GetPayload() *models.ContactGroup { + return o.Payload +} + +func (o *TenancyContactGroupsUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_bulk_delete_parameters.go b/netbox/client/tenancy/tenancy_contact_roles_bulk_delete_parameters.go new file mode 100644 index 00000000..5814561d --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_bulk_delete_parameters.go @@ -0,0 +1,141 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewTenancyContactRolesBulkDeleteParams creates a new TenancyContactRolesBulkDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactRolesBulkDeleteParams() *TenancyContactRolesBulkDeleteParams { + return &TenancyContactRolesBulkDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactRolesBulkDeleteParamsWithTimeout creates a new TenancyContactRolesBulkDeleteParams object +// with the ability to set a timeout on a request. +func NewTenancyContactRolesBulkDeleteParamsWithTimeout(timeout time.Duration) *TenancyContactRolesBulkDeleteParams { + return &TenancyContactRolesBulkDeleteParams{ + timeout: timeout, + } +} + +// NewTenancyContactRolesBulkDeleteParamsWithContext creates a new TenancyContactRolesBulkDeleteParams object +// with the ability to set a context for a request. +func NewTenancyContactRolesBulkDeleteParamsWithContext(ctx context.Context) *TenancyContactRolesBulkDeleteParams { + return &TenancyContactRolesBulkDeleteParams{ + Context: ctx, + } +} + +// NewTenancyContactRolesBulkDeleteParamsWithHTTPClient creates a new TenancyContactRolesBulkDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactRolesBulkDeleteParamsWithHTTPClient(client *http.Client) *TenancyContactRolesBulkDeleteParams { + return &TenancyContactRolesBulkDeleteParams{ + HTTPClient: client, + } +} + +/* TenancyContactRolesBulkDeleteParams contains all the parameters to send to the API endpoint + for the tenancy contact roles bulk delete operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactRolesBulkDeleteParams struct { + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact roles bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesBulkDeleteParams) WithDefaults() *TenancyContactRolesBulkDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact roles bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesBulkDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact roles bulk delete params +func (o *TenancyContactRolesBulkDeleteParams) WithTimeout(timeout time.Duration) *TenancyContactRolesBulkDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact roles bulk delete params +func (o *TenancyContactRolesBulkDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact roles bulk delete params +func (o *TenancyContactRolesBulkDeleteParams) WithContext(ctx context.Context) *TenancyContactRolesBulkDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact roles bulk delete params +func (o *TenancyContactRolesBulkDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact roles bulk delete params +func (o *TenancyContactRolesBulkDeleteParams) WithHTTPClient(client *http.Client) *TenancyContactRolesBulkDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact roles bulk delete params +func (o *TenancyContactRolesBulkDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactRolesBulkDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_bulk_delete_responses.go b/netbox/client/tenancy/tenancy_contact_roles_bulk_delete_responses.go new file mode 100644 index 00000000..1c4afd20 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_bulk_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// TenancyContactRolesBulkDeleteReader is a Reader for the TenancyContactRolesBulkDelete structure. +type TenancyContactRolesBulkDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactRolesBulkDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewTenancyContactRolesBulkDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactRolesBulkDeleteNoContent creates a TenancyContactRolesBulkDeleteNoContent with default headers values +func NewTenancyContactRolesBulkDeleteNoContent() *TenancyContactRolesBulkDeleteNoContent { + return &TenancyContactRolesBulkDeleteNoContent{} +} + +/* TenancyContactRolesBulkDeleteNoContent describes a response with status code 204, with default header values. + +TenancyContactRolesBulkDeleteNoContent tenancy contact roles bulk delete no content +*/ +type TenancyContactRolesBulkDeleteNoContent struct { +} + +func (o *TenancyContactRolesBulkDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /tenancy/contact-roles/][%d] tenancyContactRolesBulkDeleteNoContent ", 204) +} + +func (o *TenancyContactRolesBulkDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_bulk_partial_update_parameters.go b/netbox/client/tenancy/tenancy_contact_roles_bulk_partial_update_parameters.go new file mode 100644 index 00000000..f5bb00ef --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_bulk_partial_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactRolesBulkPartialUpdateParams creates a new TenancyContactRolesBulkPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactRolesBulkPartialUpdateParams() *TenancyContactRolesBulkPartialUpdateParams { + return &TenancyContactRolesBulkPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactRolesBulkPartialUpdateParamsWithTimeout creates a new TenancyContactRolesBulkPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactRolesBulkPartialUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactRolesBulkPartialUpdateParams { + return &TenancyContactRolesBulkPartialUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactRolesBulkPartialUpdateParamsWithContext creates a new TenancyContactRolesBulkPartialUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactRolesBulkPartialUpdateParamsWithContext(ctx context.Context) *TenancyContactRolesBulkPartialUpdateParams { + return &TenancyContactRolesBulkPartialUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactRolesBulkPartialUpdateParamsWithHTTPClient creates a new TenancyContactRolesBulkPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactRolesBulkPartialUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactRolesBulkPartialUpdateParams { + return &TenancyContactRolesBulkPartialUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactRolesBulkPartialUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact roles bulk partial update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactRolesBulkPartialUpdateParams struct { + + // Data. + Data *models.ContactRole + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact roles bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesBulkPartialUpdateParams) WithDefaults() *TenancyContactRolesBulkPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact roles bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesBulkPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact roles bulk partial update params +func (o *TenancyContactRolesBulkPartialUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactRolesBulkPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact roles bulk partial update params +func (o *TenancyContactRolesBulkPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact roles bulk partial update params +func (o *TenancyContactRolesBulkPartialUpdateParams) WithContext(ctx context.Context) *TenancyContactRolesBulkPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact roles bulk partial update params +func (o *TenancyContactRolesBulkPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact roles bulk partial update params +func (o *TenancyContactRolesBulkPartialUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactRolesBulkPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact roles bulk partial update params +func (o *TenancyContactRolesBulkPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact roles bulk partial update params +func (o *TenancyContactRolesBulkPartialUpdateParams) WithData(data *models.ContactRole) *TenancyContactRolesBulkPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact roles bulk partial update params +func (o *TenancyContactRolesBulkPartialUpdateParams) SetData(data *models.ContactRole) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactRolesBulkPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_bulk_partial_update_responses.go b/netbox/client/tenancy/tenancy_contact_roles_bulk_partial_update_responses.go new file mode 100644 index 00000000..276d07c9 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_bulk_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactRolesBulkPartialUpdateReader is a Reader for the TenancyContactRolesBulkPartialUpdate structure. +type TenancyContactRolesBulkPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactRolesBulkPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactRolesBulkPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactRolesBulkPartialUpdateOK creates a TenancyContactRolesBulkPartialUpdateOK with default headers values +func NewTenancyContactRolesBulkPartialUpdateOK() *TenancyContactRolesBulkPartialUpdateOK { + return &TenancyContactRolesBulkPartialUpdateOK{} +} + +/* TenancyContactRolesBulkPartialUpdateOK describes a response with status code 200, with default header values. + +TenancyContactRolesBulkPartialUpdateOK tenancy contact roles bulk partial update o k +*/ +type TenancyContactRolesBulkPartialUpdateOK struct { + Payload *models.ContactRole +} + +func (o *TenancyContactRolesBulkPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /tenancy/contact-roles/][%d] tenancyContactRolesBulkPartialUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactRolesBulkPartialUpdateOK) GetPayload() *models.ContactRole { + return o.Payload +} + +func (o *TenancyContactRolesBulkPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactRole) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_bulk_update_parameters.go b/netbox/client/tenancy/tenancy_contact_roles_bulk_update_parameters.go new file mode 100644 index 00000000..04fbb53e --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_bulk_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactRolesBulkUpdateParams creates a new TenancyContactRolesBulkUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactRolesBulkUpdateParams() *TenancyContactRolesBulkUpdateParams { + return &TenancyContactRolesBulkUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactRolesBulkUpdateParamsWithTimeout creates a new TenancyContactRolesBulkUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactRolesBulkUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactRolesBulkUpdateParams { + return &TenancyContactRolesBulkUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactRolesBulkUpdateParamsWithContext creates a new TenancyContactRolesBulkUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactRolesBulkUpdateParamsWithContext(ctx context.Context) *TenancyContactRolesBulkUpdateParams { + return &TenancyContactRolesBulkUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactRolesBulkUpdateParamsWithHTTPClient creates a new TenancyContactRolesBulkUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactRolesBulkUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactRolesBulkUpdateParams { + return &TenancyContactRolesBulkUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactRolesBulkUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact roles bulk update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactRolesBulkUpdateParams struct { + + // Data. + Data *models.ContactRole + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact roles bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesBulkUpdateParams) WithDefaults() *TenancyContactRolesBulkUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact roles bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesBulkUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact roles bulk update params +func (o *TenancyContactRolesBulkUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactRolesBulkUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact roles bulk update params +func (o *TenancyContactRolesBulkUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact roles bulk update params +func (o *TenancyContactRolesBulkUpdateParams) WithContext(ctx context.Context) *TenancyContactRolesBulkUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact roles bulk update params +func (o *TenancyContactRolesBulkUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact roles bulk update params +func (o *TenancyContactRolesBulkUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactRolesBulkUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact roles bulk update params +func (o *TenancyContactRolesBulkUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact roles bulk update params +func (o *TenancyContactRolesBulkUpdateParams) WithData(data *models.ContactRole) *TenancyContactRolesBulkUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact roles bulk update params +func (o *TenancyContactRolesBulkUpdateParams) SetData(data *models.ContactRole) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactRolesBulkUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_bulk_update_responses.go b/netbox/client/tenancy/tenancy_contact_roles_bulk_update_responses.go new file mode 100644 index 00000000..69332b68 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_bulk_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactRolesBulkUpdateReader is a Reader for the TenancyContactRolesBulkUpdate structure. +type TenancyContactRolesBulkUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactRolesBulkUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactRolesBulkUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactRolesBulkUpdateOK creates a TenancyContactRolesBulkUpdateOK with default headers values +func NewTenancyContactRolesBulkUpdateOK() *TenancyContactRolesBulkUpdateOK { + return &TenancyContactRolesBulkUpdateOK{} +} + +/* TenancyContactRolesBulkUpdateOK describes a response with status code 200, with default header values. + +TenancyContactRolesBulkUpdateOK tenancy contact roles bulk update o k +*/ +type TenancyContactRolesBulkUpdateOK struct { + Payload *models.ContactRole +} + +func (o *TenancyContactRolesBulkUpdateOK) Error() string { + return fmt.Sprintf("[PUT /tenancy/contact-roles/][%d] tenancyContactRolesBulkUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactRolesBulkUpdateOK) GetPayload() *models.ContactRole { + return o.Payload +} + +func (o *TenancyContactRolesBulkUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactRole) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_create_parameters.go b/netbox/client/tenancy/tenancy_contact_roles_create_parameters.go new file mode 100644 index 00000000..47012beb --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_create_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactRolesCreateParams creates a new TenancyContactRolesCreateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactRolesCreateParams() *TenancyContactRolesCreateParams { + return &TenancyContactRolesCreateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactRolesCreateParamsWithTimeout creates a new TenancyContactRolesCreateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactRolesCreateParamsWithTimeout(timeout time.Duration) *TenancyContactRolesCreateParams { + return &TenancyContactRolesCreateParams{ + timeout: timeout, + } +} + +// NewTenancyContactRolesCreateParamsWithContext creates a new TenancyContactRolesCreateParams object +// with the ability to set a context for a request. +func NewTenancyContactRolesCreateParamsWithContext(ctx context.Context) *TenancyContactRolesCreateParams { + return &TenancyContactRolesCreateParams{ + Context: ctx, + } +} + +// NewTenancyContactRolesCreateParamsWithHTTPClient creates a new TenancyContactRolesCreateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactRolesCreateParamsWithHTTPClient(client *http.Client) *TenancyContactRolesCreateParams { + return &TenancyContactRolesCreateParams{ + HTTPClient: client, + } +} + +/* TenancyContactRolesCreateParams contains all the parameters to send to the API endpoint + for the tenancy contact roles create operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactRolesCreateParams struct { + + // Data. + Data *models.ContactRole + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact roles create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesCreateParams) WithDefaults() *TenancyContactRolesCreateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact roles create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesCreateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact roles create params +func (o *TenancyContactRolesCreateParams) WithTimeout(timeout time.Duration) *TenancyContactRolesCreateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact roles create params +func (o *TenancyContactRolesCreateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact roles create params +func (o *TenancyContactRolesCreateParams) WithContext(ctx context.Context) *TenancyContactRolesCreateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact roles create params +func (o *TenancyContactRolesCreateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact roles create params +func (o *TenancyContactRolesCreateParams) WithHTTPClient(client *http.Client) *TenancyContactRolesCreateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact roles create params +func (o *TenancyContactRolesCreateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact roles create params +func (o *TenancyContactRolesCreateParams) WithData(data *models.ContactRole) *TenancyContactRolesCreateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact roles create params +func (o *TenancyContactRolesCreateParams) SetData(data *models.ContactRole) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactRolesCreateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_create_responses.go b/netbox/client/tenancy/tenancy_contact_roles_create_responses.go new file mode 100644 index 00000000..c0ae724a --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_create_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactRolesCreateReader is a Reader for the TenancyContactRolesCreate structure. +type TenancyContactRolesCreateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactRolesCreateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 201: + result := NewTenancyContactRolesCreateCreated() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactRolesCreateCreated creates a TenancyContactRolesCreateCreated with default headers values +func NewTenancyContactRolesCreateCreated() *TenancyContactRolesCreateCreated { + return &TenancyContactRolesCreateCreated{} +} + +/* TenancyContactRolesCreateCreated describes a response with status code 201, with default header values. + +TenancyContactRolesCreateCreated tenancy contact roles create created +*/ +type TenancyContactRolesCreateCreated struct { + Payload *models.ContactRole +} + +func (o *TenancyContactRolesCreateCreated) Error() string { + return fmt.Sprintf("[POST /tenancy/contact-roles/][%d] tenancyContactRolesCreateCreated %+v", 201, o.Payload) +} +func (o *TenancyContactRolesCreateCreated) GetPayload() *models.ContactRole { + return o.Payload +} + +func (o *TenancyContactRolesCreateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactRole) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_delete_parameters.go b/netbox/client/tenancy/tenancy_contact_roles_delete_parameters.go new file mode 100644 index 00000000..37b05f46 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_delete_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactRolesDeleteParams creates a new TenancyContactRolesDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactRolesDeleteParams() *TenancyContactRolesDeleteParams { + return &TenancyContactRolesDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactRolesDeleteParamsWithTimeout creates a new TenancyContactRolesDeleteParams object +// with the ability to set a timeout on a request. +func NewTenancyContactRolesDeleteParamsWithTimeout(timeout time.Duration) *TenancyContactRolesDeleteParams { + return &TenancyContactRolesDeleteParams{ + timeout: timeout, + } +} + +// NewTenancyContactRolesDeleteParamsWithContext creates a new TenancyContactRolesDeleteParams object +// with the ability to set a context for a request. +func NewTenancyContactRolesDeleteParamsWithContext(ctx context.Context) *TenancyContactRolesDeleteParams { + return &TenancyContactRolesDeleteParams{ + Context: ctx, + } +} + +// NewTenancyContactRolesDeleteParamsWithHTTPClient creates a new TenancyContactRolesDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactRolesDeleteParamsWithHTTPClient(client *http.Client) *TenancyContactRolesDeleteParams { + return &TenancyContactRolesDeleteParams{ + HTTPClient: client, + } +} + +/* TenancyContactRolesDeleteParams contains all the parameters to send to the API endpoint + for the tenancy contact roles delete operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactRolesDeleteParams struct { + + /* ID. + + A unique integer value identifying this contact role. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact roles delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesDeleteParams) WithDefaults() *TenancyContactRolesDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact roles delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact roles delete params +func (o *TenancyContactRolesDeleteParams) WithTimeout(timeout time.Duration) *TenancyContactRolesDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact roles delete params +func (o *TenancyContactRolesDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact roles delete params +func (o *TenancyContactRolesDeleteParams) WithContext(ctx context.Context) *TenancyContactRolesDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact roles delete params +func (o *TenancyContactRolesDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact roles delete params +func (o *TenancyContactRolesDeleteParams) WithHTTPClient(client *http.Client) *TenancyContactRolesDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact roles delete params +func (o *TenancyContactRolesDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the tenancy contact roles delete params +func (o *TenancyContactRolesDeleteParams) WithID(id int64) *TenancyContactRolesDeleteParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact roles delete params +func (o *TenancyContactRolesDeleteParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactRolesDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_delete_responses.go b/netbox/client/tenancy/tenancy_contact_roles_delete_responses.go new file mode 100644 index 00000000..c2c3b6f2 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// TenancyContactRolesDeleteReader is a Reader for the TenancyContactRolesDelete structure. +type TenancyContactRolesDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactRolesDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewTenancyContactRolesDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactRolesDeleteNoContent creates a TenancyContactRolesDeleteNoContent with default headers values +func NewTenancyContactRolesDeleteNoContent() *TenancyContactRolesDeleteNoContent { + return &TenancyContactRolesDeleteNoContent{} +} + +/* TenancyContactRolesDeleteNoContent describes a response with status code 204, with default header values. + +TenancyContactRolesDeleteNoContent tenancy contact roles delete no content +*/ +type TenancyContactRolesDeleteNoContent struct { +} + +func (o *TenancyContactRolesDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /tenancy/contact-roles/{id}/][%d] tenancyContactRolesDeleteNoContent ", 204) +} + +func (o *TenancyContactRolesDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_list_parameters.go b/netbox/client/tenancy/tenancy_contact_roles_list_parameters.go new file mode 100644 index 00000000..dd4fd6da --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_list_parameters.go @@ -0,0 +1,1699 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactRolesListParams creates a new TenancyContactRolesListParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactRolesListParams() *TenancyContactRolesListParams { + return &TenancyContactRolesListParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactRolesListParamsWithTimeout creates a new TenancyContactRolesListParams object +// with the ability to set a timeout on a request. +func NewTenancyContactRolesListParamsWithTimeout(timeout time.Duration) *TenancyContactRolesListParams { + return &TenancyContactRolesListParams{ + timeout: timeout, + } +} + +// NewTenancyContactRolesListParamsWithContext creates a new TenancyContactRolesListParams object +// with the ability to set a context for a request. +func NewTenancyContactRolesListParamsWithContext(ctx context.Context) *TenancyContactRolesListParams { + return &TenancyContactRolesListParams{ + Context: ctx, + } +} + +// NewTenancyContactRolesListParamsWithHTTPClient creates a new TenancyContactRolesListParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactRolesListParamsWithHTTPClient(client *http.Client) *TenancyContactRolesListParams { + return &TenancyContactRolesListParams{ + HTTPClient: client, + } +} + +/* TenancyContactRolesListParams contains all the parameters to send to the API endpoint + for the tenancy contact roles list operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactRolesListParams struct { + + // Created. + Created *string + + // CreatedGte. + CreatedGte *string + + // CreatedLte. + CreatedLte *string + + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + + // ID. + ID *string + + // IDGt. + IDGt *string + + // IDGte. + IDGte *string + + // IDLt. + IDLt *string + + // IDLte. + IDLte *string + + // IDn. + IDn *string + + // LastUpdated. + LastUpdated *string + + // LastUpdatedGte. + LastUpdatedGte *string + + // LastUpdatedLte. + LastUpdatedLte *string + + /* Limit. + + Number of results to return per page. + */ + Limit *int64 + + // Name. + Name *string + + // NameEmpty. + NameEmpty *string + + // NameIc. + NameIc *string + + // NameIe. + NameIe *string + + // NameIew. + NameIew *string + + // NameIsw. + NameIsw *string + + // Namen. + Namen *string + + // NameNic. + NameNic *string + + // NameNie. + NameNie *string + + // NameNiew. + NameNiew *string + + // NameNisw. + NameNisw *string + + /* Offset. + + The initial index from which to return the results. + */ + Offset *int64 + + // Q. + Q *string + + // Slug. + Slug *string + + // SlugEmpty. + SlugEmpty *string + + // SlugIc. + SlugIc *string + + // SlugIe. + SlugIe *string + + // SlugIew. + SlugIew *string + + // SlugIsw. + SlugIsw *string + + // Slugn. + Slugn *string + + // SlugNic. + SlugNic *string + + // SlugNie. + SlugNie *string + + // SlugNiew. + SlugNiew *string + + // SlugNisw. + SlugNisw *string + + // Tag. + Tag *string + + // Tagn. + Tagn *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact roles list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesListParams) WithDefaults() *TenancyContactRolesListParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact roles list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesListParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithTimeout(timeout time.Duration) *TenancyContactRolesListParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithContext(ctx context.Context) *TenancyContactRolesListParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithHTTPClient(client *http.Client) *TenancyContactRolesListParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithCreated adds the created to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithCreated(created *string) *TenancyContactRolesListParams { + o.SetCreated(created) + return o +} + +// SetCreated adds the created to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetCreated(created *string) { + o.Created = created +} + +// WithCreatedGte adds the createdGte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithCreatedGte(createdGte *string) *TenancyContactRolesListParams { + o.SetCreatedGte(createdGte) + return o +} + +// SetCreatedGte adds the createdGte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetCreatedGte(createdGte *string) { + o.CreatedGte = createdGte +} + +// WithCreatedLte adds the createdLte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithCreatedLte(createdLte *string) *TenancyContactRolesListParams { + o.SetCreatedLte(createdLte) + return o +} + +// SetCreatedLte adds the createdLte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetCreatedLte(createdLte *string) { + o.CreatedLte = createdLte +} + +// WithDescription adds the description to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithDescription(description *string) *TenancyContactRolesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithDescriptionEmpty(descriptionEmpty *string) *TenancyContactRolesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithDescriptionIc(descriptionIc *string) *TenancyContactRolesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithDescriptionIe(descriptionIe *string) *TenancyContactRolesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithDescriptionIew(descriptionIew *string) *TenancyContactRolesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithDescriptionIsw(descriptionIsw *string) *TenancyContactRolesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithDescriptionn(descriptionn *string) *TenancyContactRolesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithDescriptionNic(descriptionNic *string) *TenancyContactRolesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithDescriptionNie(descriptionNie *string) *TenancyContactRolesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithDescriptionNiew(descriptionNiew *string) *TenancyContactRolesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithDescriptionNisw(descriptionNisw *string) *TenancyContactRolesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + +// WithID adds the id to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithID(id *string) *TenancyContactRolesListParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetID(id *string) { + o.ID = id +} + +// WithIDGt adds the iDGt to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithIDGt(iDGt *string) *TenancyContactRolesListParams { + o.SetIDGt(iDGt) + return o +} + +// SetIDGt adds the idGt to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetIDGt(iDGt *string) { + o.IDGt = iDGt +} + +// WithIDGte adds the iDGte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithIDGte(iDGte *string) *TenancyContactRolesListParams { + o.SetIDGte(iDGte) + return o +} + +// SetIDGte adds the idGte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetIDGte(iDGte *string) { + o.IDGte = iDGte +} + +// WithIDLt adds the iDLt to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithIDLt(iDLt *string) *TenancyContactRolesListParams { + o.SetIDLt(iDLt) + return o +} + +// SetIDLt adds the idLt to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetIDLt(iDLt *string) { + o.IDLt = iDLt +} + +// WithIDLte adds the iDLte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithIDLte(iDLte *string) *TenancyContactRolesListParams { + o.SetIDLte(iDLte) + return o +} + +// SetIDLte adds the idLte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetIDLte(iDLte *string) { + o.IDLte = iDLte +} + +// WithIDn adds the iDn to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithIDn(iDn *string) *TenancyContactRolesListParams { + o.SetIDn(iDn) + return o +} + +// SetIDn adds the idN to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetIDn(iDn *string) { + o.IDn = iDn +} + +// WithLastUpdated adds the lastUpdated to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithLastUpdated(lastUpdated *string) *TenancyContactRolesListParams { + o.SetLastUpdated(lastUpdated) + return o +} + +// SetLastUpdated adds the lastUpdated to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetLastUpdated(lastUpdated *string) { + o.LastUpdated = lastUpdated +} + +// WithLastUpdatedGte adds the lastUpdatedGte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithLastUpdatedGte(lastUpdatedGte *string) *TenancyContactRolesListParams { + o.SetLastUpdatedGte(lastUpdatedGte) + return o +} + +// SetLastUpdatedGte adds the lastUpdatedGte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetLastUpdatedGte(lastUpdatedGte *string) { + o.LastUpdatedGte = lastUpdatedGte +} + +// WithLastUpdatedLte adds the lastUpdatedLte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithLastUpdatedLte(lastUpdatedLte *string) *TenancyContactRolesListParams { + o.SetLastUpdatedLte(lastUpdatedLte) + return o +} + +// SetLastUpdatedLte adds the lastUpdatedLte to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetLastUpdatedLte(lastUpdatedLte *string) { + o.LastUpdatedLte = lastUpdatedLte +} + +// WithLimit adds the limit to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithLimit(limit *int64) *TenancyContactRolesListParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithName adds the name to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithName(name *string) *TenancyContactRolesListParams { + o.SetName(name) + return o +} + +// SetName adds the name to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetName(name *string) { + o.Name = name +} + +// WithNameEmpty adds the nameEmpty to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithNameEmpty(nameEmpty *string) *TenancyContactRolesListParams { + o.SetNameEmpty(nameEmpty) + return o +} + +// SetNameEmpty adds the nameEmpty to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetNameEmpty(nameEmpty *string) { + o.NameEmpty = nameEmpty +} + +// WithNameIc adds the nameIc to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithNameIc(nameIc *string) *TenancyContactRolesListParams { + o.SetNameIc(nameIc) + return o +} + +// SetNameIc adds the nameIc to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetNameIc(nameIc *string) { + o.NameIc = nameIc +} + +// WithNameIe adds the nameIe to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithNameIe(nameIe *string) *TenancyContactRolesListParams { + o.SetNameIe(nameIe) + return o +} + +// SetNameIe adds the nameIe to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetNameIe(nameIe *string) { + o.NameIe = nameIe +} + +// WithNameIew adds the nameIew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithNameIew(nameIew *string) *TenancyContactRolesListParams { + o.SetNameIew(nameIew) + return o +} + +// SetNameIew adds the nameIew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetNameIew(nameIew *string) { + o.NameIew = nameIew +} + +// WithNameIsw adds the nameIsw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithNameIsw(nameIsw *string) *TenancyContactRolesListParams { + o.SetNameIsw(nameIsw) + return o +} + +// SetNameIsw adds the nameIsw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetNameIsw(nameIsw *string) { + o.NameIsw = nameIsw +} + +// WithNamen adds the namen to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithNamen(namen *string) *TenancyContactRolesListParams { + o.SetNamen(namen) + return o +} + +// SetNamen adds the nameN to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetNamen(namen *string) { + o.Namen = namen +} + +// WithNameNic adds the nameNic to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithNameNic(nameNic *string) *TenancyContactRolesListParams { + o.SetNameNic(nameNic) + return o +} + +// SetNameNic adds the nameNic to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetNameNic(nameNic *string) { + o.NameNic = nameNic +} + +// WithNameNie adds the nameNie to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithNameNie(nameNie *string) *TenancyContactRolesListParams { + o.SetNameNie(nameNie) + return o +} + +// SetNameNie adds the nameNie to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetNameNie(nameNie *string) { + o.NameNie = nameNie +} + +// WithNameNiew adds the nameNiew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithNameNiew(nameNiew *string) *TenancyContactRolesListParams { + o.SetNameNiew(nameNiew) + return o +} + +// SetNameNiew adds the nameNiew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetNameNiew(nameNiew *string) { + o.NameNiew = nameNiew +} + +// WithNameNisw adds the nameNisw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithNameNisw(nameNisw *string) *TenancyContactRolesListParams { + o.SetNameNisw(nameNisw) + return o +} + +// SetNameNisw adds the nameNisw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetNameNisw(nameNisw *string) { + o.NameNisw = nameNisw +} + +// WithOffset adds the offset to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithOffset(offset *int64) *TenancyContactRolesListParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithQ adds the q to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithQ(q *string) *TenancyContactRolesListParams { + o.SetQ(q) + return o +} + +// SetQ adds the q to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetQ(q *string) { + o.Q = q +} + +// WithSlug adds the slug to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithSlug(slug *string) *TenancyContactRolesListParams { + o.SetSlug(slug) + return o +} + +// SetSlug adds the slug to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetSlug(slug *string) { + o.Slug = slug +} + +// WithSlugEmpty adds the slugEmpty to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithSlugEmpty(slugEmpty *string) *TenancyContactRolesListParams { + o.SetSlugEmpty(slugEmpty) + return o +} + +// SetSlugEmpty adds the slugEmpty to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetSlugEmpty(slugEmpty *string) { + o.SlugEmpty = slugEmpty +} + +// WithSlugIc adds the slugIc to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithSlugIc(slugIc *string) *TenancyContactRolesListParams { + o.SetSlugIc(slugIc) + return o +} + +// SetSlugIc adds the slugIc to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetSlugIc(slugIc *string) { + o.SlugIc = slugIc +} + +// WithSlugIe adds the slugIe to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithSlugIe(slugIe *string) *TenancyContactRolesListParams { + o.SetSlugIe(slugIe) + return o +} + +// SetSlugIe adds the slugIe to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetSlugIe(slugIe *string) { + o.SlugIe = slugIe +} + +// WithSlugIew adds the slugIew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithSlugIew(slugIew *string) *TenancyContactRolesListParams { + o.SetSlugIew(slugIew) + return o +} + +// SetSlugIew adds the slugIew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetSlugIew(slugIew *string) { + o.SlugIew = slugIew +} + +// WithSlugIsw adds the slugIsw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithSlugIsw(slugIsw *string) *TenancyContactRolesListParams { + o.SetSlugIsw(slugIsw) + return o +} + +// SetSlugIsw adds the slugIsw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetSlugIsw(slugIsw *string) { + o.SlugIsw = slugIsw +} + +// WithSlugn adds the slugn to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithSlugn(slugn *string) *TenancyContactRolesListParams { + o.SetSlugn(slugn) + return o +} + +// SetSlugn adds the slugN to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetSlugn(slugn *string) { + o.Slugn = slugn +} + +// WithSlugNic adds the slugNic to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithSlugNic(slugNic *string) *TenancyContactRolesListParams { + o.SetSlugNic(slugNic) + return o +} + +// SetSlugNic adds the slugNic to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetSlugNic(slugNic *string) { + o.SlugNic = slugNic +} + +// WithSlugNie adds the slugNie to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithSlugNie(slugNie *string) *TenancyContactRolesListParams { + o.SetSlugNie(slugNie) + return o +} + +// SetSlugNie adds the slugNie to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetSlugNie(slugNie *string) { + o.SlugNie = slugNie +} + +// WithSlugNiew adds the slugNiew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithSlugNiew(slugNiew *string) *TenancyContactRolesListParams { + o.SetSlugNiew(slugNiew) + return o +} + +// SetSlugNiew adds the slugNiew to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetSlugNiew(slugNiew *string) { + o.SlugNiew = slugNiew +} + +// WithSlugNisw adds the slugNisw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithSlugNisw(slugNisw *string) *TenancyContactRolesListParams { + o.SetSlugNisw(slugNisw) + return o +} + +// SetSlugNisw adds the slugNisw to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetSlugNisw(slugNisw *string) { + o.SlugNisw = slugNisw +} + +// WithTag adds the tag to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithTag(tag *string) *TenancyContactRolesListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) WithTagn(tagn *string) *TenancyContactRolesListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the tenancy contact roles list params +func (o *TenancyContactRolesListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactRolesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.Created != nil { + + // query param created + var qrCreated string + + if o.Created != nil { + qrCreated = *o.Created + } + qCreated := qrCreated + if qCreated != "" { + + if err := r.SetQueryParam("created", qCreated); err != nil { + return err + } + } + } + + if o.CreatedGte != nil { + + // query param created__gte + var qrCreatedGte string + + if o.CreatedGte != nil { + qrCreatedGte = *o.CreatedGte + } + qCreatedGte := qrCreatedGte + if qCreatedGte != "" { + + if err := r.SetQueryParam("created__gte", qCreatedGte); err != nil { + return err + } + } + } + + if o.CreatedLte != nil { + + // query param created__lte + var qrCreatedLte string + + if o.CreatedLte != nil { + qrCreatedLte = *o.CreatedLte + } + qCreatedLte := qrCreatedLte + if qCreatedLte != "" { + + if err := r.SetQueryParam("created__lte", qCreatedLte); err != nil { + return err + } + } + } + + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + + if o.ID != nil { + + // query param id + var qrID string + + if o.ID != nil { + qrID = *o.ID + } + qID := qrID + if qID != "" { + + if err := r.SetQueryParam("id", qID); err != nil { + return err + } + } + } + + if o.IDGt != nil { + + // query param id__gt + var qrIDGt string + + if o.IDGt != nil { + qrIDGt = *o.IDGt + } + qIDGt := qrIDGt + if qIDGt != "" { + + if err := r.SetQueryParam("id__gt", qIDGt); err != nil { + return err + } + } + } + + if o.IDGte != nil { + + // query param id__gte + var qrIDGte string + + if o.IDGte != nil { + qrIDGte = *o.IDGte + } + qIDGte := qrIDGte + if qIDGte != "" { + + if err := r.SetQueryParam("id__gte", qIDGte); err != nil { + return err + } + } + } + + if o.IDLt != nil { + + // query param id__lt + var qrIDLt string + + if o.IDLt != nil { + qrIDLt = *o.IDLt + } + qIDLt := qrIDLt + if qIDLt != "" { + + if err := r.SetQueryParam("id__lt", qIDLt); err != nil { + return err + } + } + } + + if o.IDLte != nil { + + // query param id__lte + var qrIDLte string + + if o.IDLte != nil { + qrIDLte = *o.IDLte + } + qIDLte := qrIDLte + if qIDLte != "" { + + if err := r.SetQueryParam("id__lte", qIDLte); err != nil { + return err + } + } + } + + if o.IDn != nil { + + // query param id__n + var qrIDn string + + if o.IDn != nil { + qrIDn = *o.IDn + } + qIDn := qrIDn + if qIDn != "" { + + if err := r.SetQueryParam("id__n", qIDn); err != nil { + return err + } + } + } + + if o.LastUpdated != nil { + + // query param last_updated + var qrLastUpdated string + + if o.LastUpdated != nil { + qrLastUpdated = *o.LastUpdated + } + qLastUpdated := qrLastUpdated + if qLastUpdated != "" { + + if err := r.SetQueryParam("last_updated", qLastUpdated); err != nil { + return err + } + } + } + + if o.LastUpdatedGte != nil { + + // query param last_updated__gte + var qrLastUpdatedGte string + + if o.LastUpdatedGte != nil { + qrLastUpdatedGte = *o.LastUpdatedGte + } + qLastUpdatedGte := qrLastUpdatedGte + if qLastUpdatedGte != "" { + + if err := r.SetQueryParam("last_updated__gte", qLastUpdatedGte); err != nil { + return err + } + } + } + + if o.LastUpdatedLte != nil { + + // query param last_updated__lte + var qrLastUpdatedLte string + + if o.LastUpdatedLte != nil { + qrLastUpdatedLte = *o.LastUpdatedLte + } + qLastUpdatedLte := qrLastUpdatedLte + if qLastUpdatedLte != "" { + + if err := r.SetQueryParam("last_updated__lte", qLastUpdatedLte); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Name != nil { + + // query param name + var qrName string + + if o.Name != nil { + qrName = *o.Name + } + qName := qrName + if qName != "" { + + if err := r.SetQueryParam("name", qName); err != nil { + return err + } + } + } + + if o.NameEmpty != nil { + + // query param name__empty + var qrNameEmpty string + + if o.NameEmpty != nil { + qrNameEmpty = *o.NameEmpty + } + qNameEmpty := qrNameEmpty + if qNameEmpty != "" { + + if err := r.SetQueryParam("name__empty", qNameEmpty); err != nil { + return err + } + } + } + + if o.NameIc != nil { + + // query param name__ic + var qrNameIc string + + if o.NameIc != nil { + qrNameIc = *o.NameIc + } + qNameIc := qrNameIc + if qNameIc != "" { + + if err := r.SetQueryParam("name__ic", qNameIc); err != nil { + return err + } + } + } + + if o.NameIe != nil { + + // query param name__ie + var qrNameIe string + + if o.NameIe != nil { + qrNameIe = *o.NameIe + } + qNameIe := qrNameIe + if qNameIe != "" { + + if err := r.SetQueryParam("name__ie", qNameIe); err != nil { + return err + } + } + } + + if o.NameIew != nil { + + // query param name__iew + var qrNameIew string + + if o.NameIew != nil { + qrNameIew = *o.NameIew + } + qNameIew := qrNameIew + if qNameIew != "" { + + if err := r.SetQueryParam("name__iew", qNameIew); err != nil { + return err + } + } + } + + if o.NameIsw != nil { + + // query param name__isw + var qrNameIsw string + + if o.NameIsw != nil { + qrNameIsw = *o.NameIsw + } + qNameIsw := qrNameIsw + if qNameIsw != "" { + + if err := r.SetQueryParam("name__isw", qNameIsw); err != nil { + return err + } + } + } + + if o.Namen != nil { + + // query param name__n + var qrNamen string + + if o.Namen != nil { + qrNamen = *o.Namen + } + qNamen := qrNamen + if qNamen != "" { + + if err := r.SetQueryParam("name__n", qNamen); err != nil { + return err + } + } + } + + if o.NameNic != nil { + + // query param name__nic + var qrNameNic string + + if o.NameNic != nil { + qrNameNic = *o.NameNic + } + qNameNic := qrNameNic + if qNameNic != "" { + + if err := r.SetQueryParam("name__nic", qNameNic); err != nil { + return err + } + } + } + + if o.NameNie != nil { + + // query param name__nie + var qrNameNie string + + if o.NameNie != nil { + qrNameNie = *o.NameNie + } + qNameNie := qrNameNie + if qNameNie != "" { + + if err := r.SetQueryParam("name__nie", qNameNie); err != nil { + return err + } + } + } + + if o.NameNiew != nil { + + // query param name__niew + var qrNameNiew string + + if o.NameNiew != nil { + qrNameNiew = *o.NameNiew + } + qNameNiew := qrNameNiew + if qNameNiew != "" { + + if err := r.SetQueryParam("name__niew", qNameNiew); err != nil { + return err + } + } + } + + if o.NameNisw != nil { + + // query param name__nisw + var qrNameNisw string + + if o.NameNisw != nil { + qrNameNisw = *o.NameNisw + } + qNameNisw := qrNameNisw + if qNameNisw != "" { + + if err := r.SetQueryParam("name__nisw", qNameNisw); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.Q != nil { + + // query param q + var qrQ string + + if o.Q != nil { + qrQ = *o.Q + } + qQ := qrQ + if qQ != "" { + + if err := r.SetQueryParam("q", qQ); err != nil { + return err + } + } + } + + if o.Slug != nil { + + // query param slug + var qrSlug string + + if o.Slug != nil { + qrSlug = *o.Slug + } + qSlug := qrSlug + if qSlug != "" { + + if err := r.SetQueryParam("slug", qSlug); err != nil { + return err + } + } + } + + if o.SlugEmpty != nil { + + // query param slug__empty + var qrSlugEmpty string + + if o.SlugEmpty != nil { + qrSlugEmpty = *o.SlugEmpty + } + qSlugEmpty := qrSlugEmpty + if qSlugEmpty != "" { + + if err := r.SetQueryParam("slug__empty", qSlugEmpty); err != nil { + return err + } + } + } + + if o.SlugIc != nil { + + // query param slug__ic + var qrSlugIc string + + if o.SlugIc != nil { + qrSlugIc = *o.SlugIc + } + qSlugIc := qrSlugIc + if qSlugIc != "" { + + if err := r.SetQueryParam("slug__ic", qSlugIc); err != nil { + return err + } + } + } + + if o.SlugIe != nil { + + // query param slug__ie + var qrSlugIe string + + if o.SlugIe != nil { + qrSlugIe = *o.SlugIe + } + qSlugIe := qrSlugIe + if qSlugIe != "" { + + if err := r.SetQueryParam("slug__ie", qSlugIe); err != nil { + return err + } + } + } + + if o.SlugIew != nil { + + // query param slug__iew + var qrSlugIew string + + if o.SlugIew != nil { + qrSlugIew = *o.SlugIew + } + qSlugIew := qrSlugIew + if qSlugIew != "" { + + if err := r.SetQueryParam("slug__iew", qSlugIew); err != nil { + return err + } + } + } + + if o.SlugIsw != nil { + + // query param slug__isw + var qrSlugIsw string + + if o.SlugIsw != nil { + qrSlugIsw = *o.SlugIsw + } + qSlugIsw := qrSlugIsw + if qSlugIsw != "" { + + if err := r.SetQueryParam("slug__isw", qSlugIsw); err != nil { + return err + } + } + } + + if o.Slugn != nil { + + // query param slug__n + var qrSlugn string + + if o.Slugn != nil { + qrSlugn = *o.Slugn + } + qSlugn := qrSlugn + if qSlugn != "" { + + if err := r.SetQueryParam("slug__n", qSlugn); err != nil { + return err + } + } + } + + if o.SlugNic != nil { + + // query param slug__nic + var qrSlugNic string + + if o.SlugNic != nil { + qrSlugNic = *o.SlugNic + } + qSlugNic := qrSlugNic + if qSlugNic != "" { + + if err := r.SetQueryParam("slug__nic", qSlugNic); err != nil { + return err + } + } + } + + if o.SlugNie != nil { + + // query param slug__nie + var qrSlugNie string + + if o.SlugNie != nil { + qrSlugNie = *o.SlugNie + } + qSlugNie := qrSlugNie + if qSlugNie != "" { + + if err := r.SetQueryParam("slug__nie", qSlugNie); err != nil { + return err + } + } + } + + if o.SlugNiew != nil { + + // query param slug__niew + var qrSlugNiew string + + if o.SlugNiew != nil { + qrSlugNiew = *o.SlugNiew + } + qSlugNiew := qrSlugNiew + if qSlugNiew != "" { + + if err := r.SetQueryParam("slug__niew", qSlugNiew); err != nil { + return err + } + } + } + + if o.SlugNisw != nil { + + // query param slug__nisw + var qrSlugNisw string + + if o.SlugNisw != nil { + qrSlugNisw = *o.SlugNisw + } + qSlugNisw := qrSlugNisw + if qSlugNisw != "" { + + if err := r.SetQueryParam("slug__nisw", qSlugNisw); err != nil { + return err + } + } + } + + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_list_responses.go b/netbox/client/tenancy/tenancy_contact_roles_list_responses.go new file mode 100644 index 00000000..424d5334 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_list_responses.go @@ -0,0 +1,247 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactRolesListReader is a Reader for the TenancyContactRolesList structure. +type TenancyContactRolesListReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactRolesListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactRolesListOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactRolesListOK creates a TenancyContactRolesListOK with default headers values +func NewTenancyContactRolesListOK() *TenancyContactRolesListOK { + return &TenancyContactRolesListOK{} +} + +/* TenancyContactRolesListOK describes a response with status code 200, with default header values. + +TenancyContactRolesListOK tenancy contact roles list o k +*/ +type TenancyContactRolesListOK struct { + Payload *TenancyContactRolesListOKBody +} + +func (o *TenancyContactRolesListOK) Error() string { + return fmt.Sprintf("[GET /tenancy/contact-roles/][%d] tenancyContactRolesListOK %+v", 200, o.Payload) +} +func (o *TenancyContactRolesListOK) GetPayload() *TenancyContactRolesListOKBody { + return o.Payload +} + +func (o *TenancyContactRolesListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(TenancyContactRolesListOKBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*TenancyContactRolesListOKBody tenancy contact roles list o k body +swagger:model TenancyContactRolesListOKBody +*/ +type TenancyContactRolesListOKBody struct { + + // count + // Required: true + Count *int64 `json:"count"` + + // next + // Format: uri + Next *strfmt.URI `json:"next,omitempty"` + + // previous + // Format: uri + Previous *strfmt.URI `json:"previous,omitempty"` + + // results + // Required: true + Results []*models.ContactRole `json:"results"` +} + +// Validate validates this tenancy contact roles list o k body +func (o *TenancyContactRolesListOKBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateCount(formats); err != nil { + res = append(res, err) + } + + if err := o.validateNext(formats); err != nil { + res = append(res, err) + } + + if err := o.validatePrevious(formats); err != nil { + res = append(res, err) + } + + if err := o.validateResults(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *TenancyContactRolesListOKBody) validateCount(formats strfmt.Registry) error { + + if err := validate.Required("tenancyContactRolesListOK"+"."+"count", "body", o.Count); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactRolesListOKBody) validateNext(formats strfmt.Registry) error { + if swag.IsZero(o.Next) { // not required + return nil + } + + if err := validate.FormatOf("tenancyContactRolesListOK"+"."+"next", "body", "uri", o.Next.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactRolesListOKBody) validatePrevious(formats strfmt.Registry) error { + if swag.IsZero(o.Previous) { // not required + return nil + } + + if err := validate.FormatOf("tenancyContactRolesListOK"+"."+"previous", "body", "uri", o.Previous.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactRolesListOKBody) validateResults(formats strfmt.Registry) error { + + if err := validate.Required("tenancyContactRolesListOK"+"."+"results", "body", o.Results); err != nil { + return err + } + + for i := 0; i < len(o.Results); i++ { + if swag.IsZero(o.Results[i]) { // not required + continue + } + + if o.Results[i] != nil { + if err := o.Results[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenancyContactRolesListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenancyContactRolesListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this tenancy contact roles list o k body based on the context it is used +func (o *TenancyContactRolesListOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := o.contextValidateResults(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *TenancyContactRolesListOKBody) contextValidateResults(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(o.Results); i++ { + + if o.Results[i] != nil { + if err := o.Results[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenancyContactRolesListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenancyContactRolesListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (o *TenancyContactRolesListOKBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *TenancyContactRolesListOKBody) UnmarshalBinary(b []byte) error { + var res TenancyContactRolesListOKBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_partial_update_parameters.go b/netbox/client/tenancy/tenancy_contact_roles_partial_update_parameters.go new file mode 100644 index 00000000..332dc3eb --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_partial_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactRolesPartialUpdateParams creates a new TenancyContactRolesPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactRolesPartialUpdateParams() *TenancyContactRolesPartialUpdateParams { + return &TenancyContactRolesPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactRolesPartialUpdateParamsWithTimeout creates a new TenancyContactRolesPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactRolesPartialUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactRolesPartialUpdateParams { + return &TenancyContactRolesPartialUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactRolesPartialUpdateParamsWithContext creates a new TenancyContactRolesPartialUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactRolesPartialUpdateParamsWithContext(ctx context.Context) *TenancyContactRolesPartialUpdateParams { + return &TenancyContactRolesPartialUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactRolesPartialUpdateParamsWithHTTPClient creates a new TenancyContactRolesPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactRolesPartialUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactRolesPartialUpdateParams { + return &TenancyContactRolesPartialUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactRolesPartialUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact roles partial update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactRolesPartialUpdateParams struct { + + // Data. + Data *models.ContactRole + + /* ID. + + A unique integer value identifying this contact role. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact roles partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesPartialUpdateParams) WithDefaults() *TenancyContactRolesPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact roles partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact roles partial update params +func (o *TenancyContactRolesPartialUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactRolesPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact roles partial update params +func (o *TenancyContactRolesPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact roles partial update params +func (o *TenancyContactRolesPartialUpdateParams) WithContext(ctx context.Context) *TenancyContactRolesPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact roles partial update params +func (o *TenancyContactRolesPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact roles partial update params +func (o *TenancyContactRolesPartialUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactRolesPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact roles partial update params +func (o *TenancyContactRolesPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact roles partial update params +func (o *TenancyContactRolesPartialUpdateParams) WithData(data *models.ContactRole) *TenancyContactRolesPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact roles partial update params +func (o *TenancyContactRolesPartialUpdateParams) SetData(data *models.ContactRole) { + o.Data = data +} + +// WithID adds the id to the tenancy contact roles partial update params +func (o *TenancyContactRolesPartialUpdateParams) WithID(id int64) *TenancyContactRolesPartialUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact roles partial update params +func (o *TenancyContactRolesPartialUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactRolesPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_partial_update_responses.go b/netbox/client/tenancy/tenancy_contact_roles_partial_update_responses.go new file mode 100644 index 00000000..19c6b7dc --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactRolesPartialUpdateReader is a Reader for the TenancyContactRolesPartialUpdate structure. +type TenancyContactRolesPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactRolesPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactRolesPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactRolesPartialUpdateOK creates a TenancyContactRolesPartialUpdateOK with default headers values +func NewTenancyContactRolesPartialUpdateOK() *TenancyContactRolesPartialUpdateOK { + return &TenancyContactRolesPartialUpdateOK{} +} + +/* TenancyContactRolesPartialUpdateOK describes a response with status code 200, with default header values. + +TenancyContactRolesPartialUpdateOK tenancy contact roles partial update o k +*/ +type TenancyContactRolesPartialUpdateOK struct { + Payload *models.ContactRole +} + +func (o *TenancyContactRolesPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /tenancy/contact-roles/{id}/][%d] tenancyContactRolesPartialUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactRolesPartialUpdateOK) GetPayload() *models.ContactRole { + return o.Payload +} + +func (o *TenancyContactRolesPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactRole) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_read_parameters.go b/netbox/client/tenancy/tenancy_contact_roles_read_parameters.go new file mode 100644 index 00000000..96e36bfa --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_read_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactRolesReadParams creates a new TenancyContactRolesReadParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactRolesReadParams() *TenancyContactRolesReadParams { + return &TenancyContactRolesReadParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactRolesReadParamsWithTimeout creates a new TenancyContactRolesReadParams object +// with the ability to set a timeout on a request. +func NewTenancyContactRolesReadParamsWithTimeout(timeout time.Duration) *TenancyContactRolesReadParams { + return &TenancyContactRolesReadParams{ + timeout: timeout, + } +} + +// NewTenancyContactRolesReadParamsWithContext creates a new TenancyContactRolesReadParams object +// with the ability to set a context for a request. +func NewTenancyContactRolesReadParamsWithContext(ctx context.Context) *TenancyContactRolesReadParams { + return &TenancyContactRolesReadParams{ + Context: ctx, + } +} + +// NewTenancyContactRolesReadParamsWithHTTPClient creates a new TenancyContactRolesReadParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactRolesReadParamsWithHTTPClient(client *http.Client) *TenancyContactRolesReadParams { + return &TenancyContactRolesReadParams{ + HTTPClient: client, + } +} + +/* TenancyContactRolesReadParams contains all the parameters to send to the API endpoint + for the tenancy contact roles read operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactRolesReadParams struct { + + /* ID. + + A unique integer value identifying this contact role. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact roles read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesReadParams) WithDefaults() *TenancyContactRolesReadParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact roles read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesReadParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact roles read params +func (o *TenancyContactRolesReadParams) WithTimeout(timeout time.Duration) *TenancyContactRolesReadParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact roles read params +func (o *TenancyContactRolesReadParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact roles read params +func (o *TenancyContactRolesReadParams) WithContext(ctx context.Context) *TenancyContactRolesReadParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact roles read params +func (o *TenancyContactRolesReadParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact roles read params +func (o *TenancyContactRolesReadParams) WithHTTPClient(client *http.Client) *TenancyContactRolesReadParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact roles read params +func (o *TenancyContactRolesReadParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the tenancy contact roles read params +func (o *TenancyContactRolesReadParams) WithID(id int64) *TenancyContactRolesReadParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact roles read params +func (o *TenancyContactRolesReadParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactRolesReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_read_responses.go b/netbox/client/tenancy/tenancy_contact_roles_read_responses.go new file mode 100644 index 00000000..5577d5c7 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_read_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactRolesReadReader is a Reader for the TenancyContactRolesRead structure. +type TenancyContactRolesReadReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactRolesReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactRolesReadOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactRolesReadOK creates a TenancyContactRolesReadOK with default headers values +func NewTenancyContactRolesReadOK() *TenancyContactRolesReadOK { + return &TenancyContactRolesReadOK{} +} + +/* TenancyContactRolesReadOK describes a response with status code 200, with default header values. + +TenancyContactRolesReadOK tenancy contact roles read o k +*/ +type TenancyContactRolesReadOK struct { + Payload *models.ContactRole +} + +func (o *TenancyContactRolesReadOK) Error() string { + return fmt.Sprintf("[GET /tenancy/contact-roles/{id}/][%d] tenancyContactRolesReadOK %+v", 200, o.Payload) +} +func (o *TenancyContactRolesReadOK) GetPayload() *models.ContactRole { + return o.Payload +} + +func (o *TenancyContactRolesReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactRole) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_update_parameters.go b/netbox/client/tenancy/tenancy_contact_roles_update_parameters.go new file mode 100644 index 00000000..81083098 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactRolesUpdateParams creates a new TenancyContactRolesUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactRolesUpdateParams() *TenancyContactRolesUpdateParams { + return &TenancyContactRolesUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactRolesUpdateParamsWithTimeout creates a new TenancyContactRolesUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactRolesUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactRolesUpdateParams { + return &TenancyContactRolesUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactRolesUpdateParamsWithContext creates a new TenancyContactRolesUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactRolesUpdateParamsWithContext(ctx context.Context) *TenancyContactRolesUpdateParams { + return &TenancyContactRolesUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactRolesUpdateParamsWithHTTPClient creates a new TenancyContactRolesUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactRolesUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactRolesUpdateParams { + return &TenancyContactRolesUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactRolesUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contact roles update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactRolesUpdateParams struct { + + // Data. + Data *models.ContactRole + + /* ID. + + A unique integer value identifying this contact role. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contact roles update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesUpdateParams) WithDefaults() *TenancyContactRolesUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contact roles update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactRolesUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contact roles update params +func (o *TenancyContactRolesUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactRolesUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contact roles update params +func (o *TenancyContactRolesUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contact roles update params +func (o *TenancyContactRolesUpdateParams) WithContext(ctx context.Context) *TenancyContactRolesUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contact roles update params +func (o *TenancyContactRolesUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contact roles update params +func (o *TenancyContactRolesUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactRolesUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contact roles update params +func (o *TenancyContactRolesUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contact roles update params +func (o *TenancyContactRolesUpdateParams) WithData(data *models.ContactRole) *TenancyContactRolesUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contact roles update params +func (o *TenancyContactRolesUpdateParams) SetData(data *models.ContactRole) { + o.Data = data +} + +// WithID adds the id to the tenancy contact roles update params +func (o *TenancyContactRolesUpdateParams) WithID(id int64) *TenancyContactRolesUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contact roles update params +func (o *TenancyContactRolesUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactRolesUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contact_roles_update_responses.go b/netbox/client/tenancy/tenancy_contact_roles_update_responses.go new file mode 100644 index 00000000..1ff5e96f --- /dev/null +++ b/netbox/client/tenancy/tenancy_contact_roles_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactRolesUpdateReader is a Reader for the TenancyContactRolesUpdate structure. +type TenancyContactRolesUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactRolesUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactRolesUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactRolesUpdateOK creates a TenancyContactRolesUpdateOK with default headers values +func NewTenancyContactRolesUpdateOK() *TenancyContactRolesUpdateOK { + return &TenancyContactRolesUpdateOK{} +} + +/* TenancyContactRolesUpdateOK describes a response with status code 200, with default header values. + +TenancyContactRolesUpdateOK tenancy contact roles update o k +*/ +type TenancyContactRolesUpdateOK struct { + Payload *models.ContactRole +} + +func (o *TenancyContactRolesUpdateOK) Error() string { + return fmt.Sprintf("[PUT /tenancy/contact-roles/{id}/][%d] tenancyContactRolesUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactRolesUpdateOK) GetPayload() *models.ContactRole { + return o.Payload +} + +func (o *TenancyContactRolesUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.ContactRole) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_bulk_delete_parameters.go b/netbox/client/tenancy/tenancy_contacts_bulk_delete_parameters.go new file mode 100644 index 00000000..de6d62f4 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_bulk_delete_parameters.go @@ -0,0 +1,141 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewTenancyContactsBulkDeleteParams creates a new TenancyContactsBulkDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactsBulkDeleteParams() *TenancyContactsBulkDeleteParams { + return &TenancyContactsBulkDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactsBulkDeleteParamsWithTimeout creates a new TenancyContactsBulkDeleteParams object +// with the ability to set a timeout on a request. +func NewTenancyContactsBulkDeleteParamsWithTimeout(timeout time.Duration) *TenancyContactsBulkDeleteParams { + return &TenancyContactsBulkDeleteParams{ + timeout: timeout, + } +} + +// NewTenancyContactsBulkDeleteParamsWithContext creates a new TenancyContactsBulkDeleteParams object +// with the ability to set a context for a request. +func NewTenancyContactsBulkDeleteParamsWithContext(ctx context.Context) *TenancyContactsBulkDeleteParams { + return &TenancyContactsBulkDeleteParams{ + Context: ctx, + } +} + +// NewTenancyContactsBulkDeleteParamsWithHTTPClient creates a new TenancyContactsBulkDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactsBulkDeleteParamsWithHTTPClient(client *http.Client) *TenancyContactsBulkDeleteParams { + return &TenancyContactsBulkDeleteParams{ + HTTPClient: client, + } +} + +/* TenancyContactsBulkDeleteParams contains all the parameters to send to the API endpoint + for the tenancy contacts bulk delete operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactsBulkDeleteParams struct { + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contacts bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsBulkDeleteParams) WithDefaults() *TenancyContactsBulkDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contacts bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsBulkDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contacts bulk delete params +func (o *TenancyContactsBulkDeleteParams) WithTimeout(timeout time.Duration) *TenancyContactsBulkDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contacts bulk delete params +func (o *TenancyContactsBulkDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contacts bulk delete params +func (o *TenancyContactsBulkDeleteParams) WithContext(ctx context.Context) *TenancyContactsBulkDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contacts bulk delete params +func (o *TenancyContactsBulkDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contacts bulk delete params +func (o *TenancyContactsBulkDeleteParams) WithHTTPClient(client *http.Client) *TenancyContactsBulkDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contacts bulk delete params +func (o *TenancyContactsBulkDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactsBulkDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_bulk_delete_responses.go b/netbox/client/tenancy/tenancy_contacts_bulk_delete_responses.go new file mode 100644 index 00000000..c78023cb --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_bulk_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// TenancyContactsBulkDeleteReader is a Reader for the TenancyContactsBulkDelete structure. +type TenancyContactsBulkDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactsBulkDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewTenancyContactsBulkDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactsBulkDeleteNoContent creates a TenancyContactsBulkDeleteNoContent with default headers values +func NewTenancyContactsBulkDeleteNoContent() *TenancyContactsBulkDeleteNoContent { + return &TenancyContactsBulkDeleteNoContent{} +} + +/* TenancyContactsBulkDeleteNoContent describes a response with status code 204, with default header values. + +TenancyContactsBulkDeleteNoContent tenancy contacts bulk delete no content +*/ +type TenancyContactsBulkDeleteNoContent struct { +} + +func (o *TenancyContactsBulkDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /tenancy/contacts/][%d] tenancyContactsBulkDeleteNoContent ", 204) +} + +func (o *TenancyContactsBulkDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_bulk_partial_update_parameters.go b/netbox/client/tenancy/tenancy_contacts_bulk_partial_update_parameters.go new file mode 100644 index 00000000..322747ad --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_bulk_partial_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactsBulkPartialUpdateParams creates a new TenancyContactsBulkPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactsBulkPartialUpdateParams() *TenancyContactsBulkPartialUpdateParams { + return &TenancyContactsBulkPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactsBulkPartialUpdateParamsWithTimeout creates a new TenancyContactsBulkPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactsBulkPartialUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactsBulkPartialUpdateParams { + return &TenancyContactsBulkPartialUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactsBulkPartialUpdateParamsWithContext creates a new TenancyContactsBulkPartialUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactsBulkPartialUpdateParamsWithContext(ctx context.Context) *TenancyContactsBulkPartialUpdateParams { + return &TenancyContactsBulkPartialUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactsBulkPartialUpdateParamsWithHTTPClient creates a new TenancyContactsBulkPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactsBulkPartialUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactsBulkPartialUpdateParams { + return &TenancyContactsBulkPartialUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactsBulkPartialUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contacts bulk partial update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactsBulkPartialUpdateParams struct { + + // Data. + Data *models.WritableContact + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contacts bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsBulkPartialUpdateParams) WithDefaults() *TenancyContactsBulkPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contacts bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsBulkPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contacts bulk partial update params +func (o *TenancyContactsBulkPartialUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactsBulkPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contacts bulk partial update params +func (o *TenancyContactsBulkPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contacts bulk partial update params +func (o *TenancyContactsBulkPartialUpdateParams) WithContext(ctx context.Context) *TenancyContactsBulkPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contacts bulk partial update params +func (o *TenancyContactsBulkPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contacts bulk partial update params +func (o *TenancyContactsBulkPartialUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactsBulkPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contacts bulk partial update params +func (o *TenancyContactsBulkPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contacts bulk partial update params +func (o *TenancyContactsBulkPartialUpdateParams) WithData(data *models.WritableContact) *TenancyContactsBulkPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contacts bulk partial update params +func (o *TenancyContactsBulkPartialUpdateParams) SetData(data *models.WritableContact) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactsBulkPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_bulk_partial_update_responses.go b/netbox/client/tenancy/tenancy_contacts_bulk_partial_update_responses.go new file mode 100644 index 00000000..66cc9543 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_bulk_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactsBulkPartialUpdateReader is a Reader for the TenancyContactsBulkPartialUpdate structure. +type TenancyContactsBulkPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactsBulkPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactsBulkPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactsBulkPartialUpdateOK creates a TenancyContactsBulkPartialUpdateOK with default headers values +func NewTenancyContactsBulkPartialUpdateOK() *TenancyContactsBulkPartialUpdateOK { + return &TenancyContactsBulkPartialUpdateOK{} +} + +/* TenancyContactsBulkPartialUpdateOK describes a response with status code 200, with default header values. + +TenancyContactsBulkPartialUpdateOK tenancy contacts bulk partial update o k +*/ +type TenancyContactsBulkPartialUpdateOK struct { + Payload *models.Contact +} + +func (o *TenancyContactsBulkPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /tenancy/contacts/][%d] tenancyContactsBulkPartialUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactsBulkPartialUpdateOK) GetPayload() *models.Contact { + return o.Payload +} + +func (o *TenancyContactsBulkPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.Contact) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_bulk_update_parameters.go b/netbox/client/tenancy/tenancy_contacts_bulk_update_parameters.go new file mode 100644 index 00000000..2ad7e311 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_bulk_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactsBulkUpdateParams creates a new TenancyContactsBulkUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactsBulkUpdateParams() *TenancyContactsBulkUpdateParams { + return &TenancyContactsBulkUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactsBulkUpdateParamsWithTimeout creates a new TenancyContactsBulkUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactsBulkUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactsBulkUpdateParams { + return &TenancyContactsBulkUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactsBulkUpdateParamsWithContext creates a new TenancyContactsBulkUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactsBulkUpdateParamsWithContext(ctx context.Context) *TenancyContactsBulkUpdateParams { + return &TenancyContactsBulkUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactsBulkUpdateParamsWithHTTPClient creates a new TenancyContactsBulkUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactsBulkUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactsBulkUpdateParams { + return &TenancyContactsBulkUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactsBulkUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contacts bulk update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactsBulkUpdateParams struct { + + // Data. + Data *models.WritableContact + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contacts bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsBulkUpdateParams) WithDefaults() *TenancyContactsBulkUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contacts bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsBulkUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contacts bulk update params +func (o *TenancyContactsBulkUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactsBulkUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contacts bulk update params +func (o *TenancyContactsBulkUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contacts bulk update params +func (o *TenancyContactsBulkUpdateParams) WithContext(ctx context.Context) *TenancyContactsBulkUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contacts bulk update params +func (o *TenancyContactsBulkUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contacts bulk update params +func (o *TenancyContactsBulkUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactsBulkUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contacts bulk update params +func (o *TenancyContactsBulkUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contacts bulk update params +func (o *TenancyContactsBulkUpdateParams) WithData(data *models.WritableContact) *TenancyContactsBulkUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contacts bulk update params +func (o *TenancyContactsBulkUpdateParams) SetData(data *models.WritableContact) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactsBulkUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_bulk_update_responses.go b/netbox/client/tenancy/tenancy_contacts_bulk_update_responses.go new file mode 100644 index 00000000..86c7fff4 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_bulk_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactsBulkUpdateReader is a Reader for the TenancyContactsBulkUpdate structure. +type TenancyContactsBulkUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactsBulkUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactsBulkUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactsBulkUpdateOK creates a TenancyContactsBulkUpdateOK with default headers values +func NewTenancyContactsBulkUpdateOK() *TenancyContactsBulkUpdateOK { + return &TenancyContactsBulkUpdateOK{} +} + +/* TenancyContactsBulkUpdateOK describes a response with status code 200, with default header values. + +TenancyContactsBulkUpdateOK tenancy contacts bulk update o k +*/ +type TenancyContactsBulkUpdateOK struct { + Payload *models.Contact +} + +func (o *TenancyContactsBulkUpdateOK) Error() string { + return fmt.Sprintf("[PUT /tenancy/contacts/][%d] tenancyContactsBulkUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactsBulkUpdateOK) GetPayload() *models.Contact { + return o.Payload +} + +func (o *TenancyContactsBulkUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.Contact) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_create_parameters.go b/netbox/client/tenancy/tenancy_contacts_create_parameters.go new file mode 100644 index 00000000..2fb7beb8 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_create_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactsCreateParams creates a new TenancyContactsCreateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactsCreateParams() *TenancyContactsCreateParams { + return &TenancyContactsCreateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactsCreateParamsWithTimeout creates a new TenancyContactsCreateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactsCreateParamsWithTimeout(timeout time.Duration) *TenancyContactsCreateParams { + return &TenancyContactsCreateParams{ + timeout: timeout, + } +} + +// NewTenancyContactsCreateParamsWithContext creates a new TenancyContactsCreateParams object +// with the ability to set a context for a request. +func NewTenancyContactsCreateParamsWithContext(ctx context.Context) *TenancyContactsCreateParams { + return &TenancyContactsCreateParams{ + Context: ctx, + } +} + +// NewTenancyContactsCreateParamsWithHTTPClient creates a new TenancyContactsCreateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactsCreateParamsWithHTTPClient(client *http.Client) *TenancyContactsCreateParams { + return &TenancyContactsCreateParams{ + HTTPClient: client, + } +} + +/* TenancyContactsCreateParams contains all the parameters to send to the API endpoint + for the tenancy contacts create operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactsCreateParams struct { + + // Data. + Data *models.WritableContact + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contacts create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsCreateParams) WithDefaults() *TenancyContactsCreateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contacts create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsCreateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contacts create params +func (o *TenancyContactsCreateParams) WithTimeout(timeout time.Duration) *TenancyContactsCreateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contacts create params +func (o *TenancyContactsCreateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contacts create params +func (o *TenancyContactsCreateParams) WithContext(ctx context.Context) *TenancyContactsCreateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contacts create params +func (o *TenancyContactsCreateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contacts create params +func (o *TenancyContactsCreateParams) WithHTTPClient(client *http.Client) *TenancyContactsCreateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contacts create params +func (o *TenancyContactsCreateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contacts create params +func (o *TenancyContactsCreateParams) WithData(data *models.WritableContact) *TenancyContactsCreateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contacts create params +func (o *TenancyContactsCreateParams) SetData(data *models.WritableContact) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactsCreateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_create_responses.go b/netbox/client/tenancy/tenancy_contacts_create_responses.go new file mode 100644 index 00000000..990260ce --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_create_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactsCreateReader is a Reader for the TenancyContactsCreate structure. +type TenancyContactsCreateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactsCreateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 201: + result := NewTenancyContactsCreateCreated() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactsCreateCreated creates a TenancyContactsCreateCreated with default headers values +func NewTenancyContactsCreateCreated() *TenancyContactsCreateCreated { + return &TenancyContactsCreateCreated{} +} + +/* TenancyContactsCreateCreated describes a response with status code 201, with default header values. + +TenancyContactsCreateCreated tenancy contacts create created +*/ +type TenancyContactsCreateCreated struct { + Payload *models.Contact +} + +func (o *TenancyContactsCreateCreated) Error() string { + return fmt.Sprintf("[POST /tenancy/contacts/][%d] tenancyContactsCreateCreated %+v", 201, o.Payload) +} +func (o *TenancyContactsCreateCreated) GetPayload() *models.Contact { + return o.Payload +} + +func (o *TenancyContactsCreateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.Contact) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_delete_parameters.go b/netbox/client/tenancy/tenancy_contacts_delete_parameters.go new file mode 100644 index 00000000..0632faed --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_delete_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactsDeleteParams creates a new TenancyContactsDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactsDeleteParams() *TenancyContactsDeleteParams { + return &TenancyContactsDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactsDeleteParamsWithTimeout creates a new TenancyContactsDeleteParams object +// with the ability to set a timeout on a request. +func NewTenancyContactsDeleteParamsWithTimeout(timeout time.Duration) *TenancyContactsDeleteParams { + return &TenancyContactsDeleteParams{ + timeout: timeout, + } +} + +// NewTenancyContactsDeleteParamsWithContext creates a new TenancyContactsDeleteParams object +// with the ability to set a context for a request. +func NewTenancyContactsDeleteParamsWithContext(ctx context.Context) *TenancyContactsDeleteParams { + return &TenancyContactsDeleteParams{ + Context: ctx, + } +} + +// NewTenancyContactsDeleteParamsWithHTTPClient creates a new TenancyContactsDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactsDeleteParamsWithHTTPClient(client *http.Client) *TenancyContactsDeleteParams { + return &TenancyContactsDeleteParams{ + HTTPClient: client, + } +} + +/* TenancyContactsDeleteParams contains all the parameters to send to the API endpoint + for the tenancy contacts delete operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactsDeleteParams struct { + + /* ID. + + A unique integer value identifying this contact. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contacts delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsDeleteParams) WithDefaults() *TenancyContactsDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contacts delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contacts delete params +func (o *TenancyContactsDeleteParams) WithTimeout(timeout time.Duration) *TenancyContactsDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contacts delete params +func (o *TenancyContactsDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contacts delete params +func (o *TenancyContactsDeleteParams) WithContext(ctx context.Context) *TenancyContactsDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contacts delete params +func (o *TenancyContactsDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contacts delete params +func (o *TenancyContactsDeleteParams) WithHTTPClient(client *http.Client) *TenancyContactsDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contacts delete params +func (o *TenancyContactsDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the tenancy contacts delete params +func (o *TenancyContactsDeleteParams) WithID(id int64) *TenancyContactsDeleteParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contacts delete params +func (o *TenancyContactsDeleteParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactsDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_delete_responses.go b/netbox/client/tenancy/tenancy_contacts_delete_responses.go new file mode 100644 index 00000000..65bff98d --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// TenancyContactsDeleteReader is a Reader for the TenancyContactsDelete structure. +type TenancyContactsDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactsDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewTenancyContactsDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactsDeleteNoContent creates a TenancyContactsDeleteNoContent with default headers values +func NewTenancyContactsDeleteNoContent() *TenancyContactsDeleteNoContent { + return &TenancyContactsDeleteNoContent{} +} + +/* TenancyContactsDeleteNoContent describes a response with status code 204, with default header values. + +TenancyContactsDeleteNoContent tenancy contacts delete no content +*/ +type TenancyContactsDeleteNoContent struct { +} + +func (o *TenancyContactsDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /tenancy/contacts/{id}/][%d] tenancyContactsDeleteNoContent ", 204) +} + +func (o *TenancyContactsDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_list_parameters.go b/netbox/client/tenancy/tenancy_contacts_list_parameters.go new file mode 100644 index 00000000..d965f727 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_list_parameters.go @@ -0,0 +1,2505 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactsListParams creates a new TenancyContactsListParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactsListParams() *TenancyContactsListParams { + return &TenancyContactsListParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactsListParamsWithTimeout creates a new TenancyContactsListParams object +// with the ability to set a timeout on a request. +func NewTenancyContactsListParamsWithTimeout(timeout time.Duration) *TenancyContactsListParams { + return &TenancyContactsListParams{ + timeout: timeout, + } +} + +// NewTenancyContactsListParamsWithContext creates a new TenancyContactsListParams object +// with the ability to set a context for a request. +func NewTenancyContactsListParamsWithContext(ctx context.Context) *TenancyContactsListParams { + return &TenancyContactsListParams{ + Context: ctx, + } +} + +// NewTenancyContactsListParamsWithHTTPClient creates a new TenancyContactsListParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactsListParamsWithHTTPClient(client *http.Client) *TenancyContactsListParams { + return &TenancyContactsListParams{ + HTTPClient: client, + } +} + +/* TenancyContactsListParams contains all the parameters to send to the API endpoint + for the tenancy contacts list operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactsListParams struct { + + // Address. + Address *string + + // AddressEmpty. + AddressEmpty *string + + // AddressIc. + AddressIc *string + + // AddressIe. + AddressIe *string + + // AddressIew. + AddressIew *string + + // AddressIsw. + AddressIsw *string + + // Addressn. + Addressn *string + + // AddressNic. + AddressNic *string + + // AddressNie. + AddressNie *string + + // AddressNiew. + AddressNiew *string + + // AddressNisw. + AddressNisw *string + + // Created. + Created *string + + // CreatedGte. + CreatedGte *string + + // CreatedLte. + CreatedLte *string + + // Email. + Email *string + + // EmailEmpty. + EmailEmpty *string + + // EmailIc. + EmailIc *string + + // EmailIe. + EmailIe *string + + // EmailIew. + EmailIew *string + + // EmailIsw. + EmailIsw *string + + // Emailn. + Emailn *string + + // EmailNic. + EmailNic *string + + // EmailNie. + EmailNie *string + + // EmailNiew. + EmailNiew *string + + // EmailNisw. + EmailNisw *string + + // Group. + Group *string + + // Groupn. + Groupn *string + + // GroupID. + GroupID *string + + // GroupIDn. + GroupIDn *string + + // ID. + ID *string + + // IDGt. + IDGt *string + + // IDGte. + IDGte *string + + // IDLt. + IDLt *string + + // IDLte. + IDLte *string + + // IDn. + IDn *string + + // LastUpdated. + LastUpdated *string + + // LastUpdatedGte. + LastUpdatedGte *string + + // LastUpdatedLte. + LastUpdatedLte *string + + /* Limit. + + Number of results to return per page. + */ + Limit *int64 + + // Name. + Name *string + + // NameEmpty. + NameEmpty *string + + // NameIc. + NameIc *string + + // NameIe. + NameIe *string + + // NameIew. + NameIew *string + + // NameIsw. + NameIsw *string + + // Namen. + Namen *string + + // NameNic. + NameNic *string + + // NameNie. + NameNie *string + + // NameNiew. + NameNiew *string + + // NameNisw. + NameNisw *string + + /* Offset. + + The initial index from which to return the results. + */ + Offset *int64 + + // Phone. + Phone *string + + // PhoneEmpty. + PhoneEmpty *string + + // PhoneIc. + PhoneIc *string + + // PhoneIe. + PhoneIe *string + + // PhoneIew. + PhoneIew *string + + // PhoneIsw. + PhoneIsw *string + + // Phonen. + Phonen *string + + // PhoneNic. + PhoneNic *string + + // PhoneNie. + PhoneNie *string + + // PhoneNiew. + PhoneNiew *string + + // PhoneNisw. + PhoneNisw *string + + // Q. + Q *string + + // Tag. + Tag *string + + // Tagn. + Tagn *string + + // Title. + Title *string + + // TitleEmpty. + TitleEmpty *string + + // TitleIc. + TitleIc *string + + // TitleIe. + TitleIe *string + + // TitleIew. + TitleIew *string + + // TitleIsw. + TitleIsw *string + + // Titlen. + Titlen *string + + // TitleNic. + TitleNic *string + + // TitleNie. + TitleNie *string + + // TitleNiew. + TitleNiew *string + + // TitleNisw. + TitleNisw *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contacts list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsListParams) WithDefaults() *TenancyContactsListParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contacts list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsListParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTimeout(timeout time.Duration) *TenancyContactsListParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contacts list params +func (o *TenancyContactsListParams) WithContext(ctx context.Context) *TenancyContactsListParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contacts list params +func (o *TenancyContactsListParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contacts list params +func (o *TenancyContactsListParams) WithHTTPClient(client *http.Client) *TenancyContactsListParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contacts list params +func (o *TenancyContactsListParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAddress adds the address to the tenancy contacts list params +func (o *TenancyContactsListParams) WithAddress(address *string) *TenancyContactsListParams { + o.SetAddress(address) + return o +} + +// SetAddress adds the address to the tenancy contacts list params +func (o *TenancyContactsListParams) SetAddress(address *string) { + o.Address = address +} + +// WithAddressEmpty adds the addressEmpty to the tenancy contacts list params +func (o *TenancyContactsListParams) WithAddressEmpty(addressEmpty *string) *TenancyContactsListParams { + o.SetAddressEmpty(addressEmpty) + return o +} + +// SetAddressEmpty adds the addressEmpty to the tenancy contacts list params +func (o *TenancyContactsListParams) SetAddressEmpty(addressEmpty *string) { + o.AddressEmpty = addressEmpty +} + +// WithAddressIc adds the addressIc to the tenancy contacts list params +func (o *TenancyContactsListParams) WithAddressIc(addressIc *string) *TenancyContactsListParams { + o.SetAddressIc(addressIc) + return o +} + +// SetAddressIc adds the addressIc to the tenancy contacts list params +func (o *TenancyContactsListParams) SetAddressIc(addressIc *string) { + o.AddressIc = addressIc +} + +// WithAddressIe adds the addressIe to the tenancy contacts list params +func (o *TenancyContactsListParams) WithAddressIe(addressIe *string) *TenancyContactsListParams { + o.SetAddressIe(addressIe) + return o +} + +// SetAddressIe adds the addressIe to the tenancy contacts list params +func (o *TenancyContactsListParams) SetAddressIe(addressIe *string) { + o.AddressIe = addressIe +} + +// WithAddressIew adds the addressIew to the tenancy contacts list params +func (o *TenancyContactsListParams) WithAddressIew(addressIew *string) *TenancyContactsListParams { + o.SetAddressIew(addressIew) + return o +} + +// SetAddressIew adds the addressIew to the tenancy contacts list params +func (o *TenancyContactsListParams) SetAddressIew(addressIew *string) { + o.AddressIew = addressIew +} + +// WithAddressIsw adds the addressIsw to the tenancy contacts list params +func (o *TenancyContactsListParams) WithAddressIsw(addressIsw *string) *TenancyContactsListParams { + o.SetAddressIsw(addressIsw) + return o +} + +// SetAddressIsw adds the addressIsw to the tenancy contacts list params +func (o *TenancyContactsListParams) SetAddressIsw(addressIsw *string) { + o.AddressIsw = addressIsw +} + +// WithAddressn adds the addressn to the tenancy contacts list params +func (o *TenancyContactsListParams) WithAddressn(addressn *string) *TenancyContactsListParams { + o.SetAddressn(addressn) + return o +} + +// SetAddressn adds the addressN to the tenancy contacts list params +func (o *TenancyContactsListParams) SetAddressn(addressn *string) { + o.Addressn = addressn +} + +// WithAddressNic adds the addressNic to the tenancy contacts list params +func (o *TenancyContactsListParams) WithAddressNic(addressNic *string) *TenancyContactsListParams { + o.SetAddressNic(addressNic) + return o +} + +// SetAddressNic adds the addressNic to the tenancy contacts list params +func (o *TenancyContactsListParams) SetAddressNic(addressNic *string) { + o.AddressNic = addressNic +} + +// WithAddressNie adds the addressNie to the tenancy contacts list params +func (o *TenancyContactsListParams) WithAddressNie(addressNie *string) *TenancyContactsListParams { + o.SetAddressNie(addressNie) + return o +} + +// SetAddressNie adds the addressNie to the tenancy contacts list params +func (o *TenancyContactsListParams) SetAddressNie(addressNie *string) { + o.AddressNie = addressNie +} + +// WithAddressNiew adds the addressNiew to the tenancy contacts list params +func (o *TenancyContactsListParams) WithAddressNiew(addressNiew *string) *TenancyContactsListParams { + o.SetAddressNiew(addressNiew) + return o +} + +// SetAddressNiew adds the addressNiew to the tenancy contacts list params +func (o *TenancyContactsListParams) SetAddressNiew(addressNiew *string) { + o.AddressNiew = addressNiew +} + +// WithAddressNisw adds the addressNisw to the tenancy contacts list params +func (o *TenancyContactsListParams) WithAddressNisw(addressNisw *string) *TenancyContactsListParams { + o.SetAddressNisw(addressNisw) + return o +} + +// SetAddressNisw adds the addressNisw to the tenancy contacts list params +func (o *TenancyContactsListParams) SetAddressNisw(addressNisw *string) { + o.AddressNisw = addressNisw +} + +// WithCreated adds the created to the tenancy contacts list params +func (o *TenancyContactsListParams) WithCreated(created *string) *TenancyContactsListParams { + o.SetCreated(created) + return o +} + +// SetCreated adds the created to the tenancy contacts list params +func (o *TenancyContactsListParams) SetCreated(created *string) { + o.Created = created +} + +// WithCreatedGte adds the createdGte to the tenancy contacts list params +func (o *TenancyContactsListParams) WithCreatedGte(createdGte *string) *TenancyContactsListParams { + o.SetCreatedGte(createdGte) + return o +} + +// SetCreatedGte adds the createdGte to the tenancy contacts list params +func (o *TenancyContactsListParams) SetCreatedGte(createdGte *string) { + o.CreatedGte = createdGte +} + +// WithCreatedLte adds the createdLte to the tenancy contacts list params +func (o *TenancyContactsListParams) WithCreatedLte(createdLte *string) *TenancyContactsListParams { + o.SetCreatedLte(createdLte) + return o +} + +// SetCreatedLte adds the createdLte to the tenancy contacts list params +func (o *TenancyContactsListParams) SetCreatedLte(createdLte *string) { + o.CreatedLte = createdLte +} + +// WithEmail adds the email to the tenancy contacts list params +func (o *TenancyContactsListParams) WithEmail(email *string) *TenancyContactsListParams { + o.SetEmail(email) + return o +} + +// SetEmail adds the email to the tenancy contacts list params +func (o *TenancyContactsListParams) SetEmail(email *string) { + o.Email = email +} + +// WithEmailEmpty adds the emailEmpty to the tenancy contacts list params +func (o *TenancyContactsListParams) WithEmailEmpty(emailEmpty *string) *TenancyContactsListParams { + o.SetEmailEmpty(emailEmpty) + return o +} + +// SetEmailEmpty adds the emailEmpty to the tenancy contacts list params +func (o *TenancyContactsListParams) SetEmailEmpty(emailEmpty *string) { + o.EmailEmpty = emailEmpty +} + +// WithEmailIc adds the emailIc to the tenancy contacts list params +func (o *TenancyContactsListParams) WithEmailIc(emailIc *string) *TenancyContactsListParams { + o.SetEmailIc(emailIc) + return o +} + +// SetEmailIc adds the emailIc to the tenancy contacts list params +func (o *TenancyContactsListParams) SetEmailIc(emailIc *string) { + o.EmailIc = emailIc +} + +// WithEmailIe adds the emailIe to the tenancy contacts list params +func (o *TenancyContactsListParams) WithEmailIe(emailIe *string) *TenancyContactsListParams { + o.SetEmailIe(emailIe) + return o +} + +// SetEmailIe adds the emailIe to the tenancy contacts list params +func (o *TenancyContactsListParams) SetEmailIe(emailIe *string) { + o.EmailIe = emailIe +} + +// WithEmailIew adds the emailIew to the tenancy contacts list params +func (o *TenancyContactsListParams) WithEmailIew(emailIew *string) *TenancyContactsListParams { + o.SetEmailIew(emailIew) + return o +} + +// SetEmailIew adds the emailIew to the tenancy contacts list params +func (o *TenancyContactsListParams) SetEmailIew(emailIew *string) { + o.EmailIew = emailIew +} + +// WithEmailIsw adds the emailIsw to the tenancy contacts list params +func (o *TenancyContactsListParams) WithEmailIsw(emailIsw *string) *TenancyContactsListParams { + o.SetEmailIsw(emailIsw) + return o +} + +// SetEmailIsw adds the emailIsw to the tenancy contacts list params +func (o *TenancyContactsListParams) SetEmailIsw(emailIsw *string) { + o.EmailIsw = emailIsw +} + +// WithEmailn adds the emailn to the tenancy contacts list params +func (o *TenancyContactsListParams) WithEmailn(emailn *string) *TenancyContactsListParams { + o.SetEmailn(emailn) + return o +} + +// SetEmailn adds the emailN to the tenancy contacts list params +func (o *TenancyContactsListParams) SetEmailn(emailn *string) { + o.Emailn = emailn +} + +// WithEmailNic adds the emailNic to the tenancy contacts list params +func (o *TenancyContactsListParams) WithEmailNic(emailNic *string) *TenancyContactsListParams { + o.SetEmailNic(emailNic) + return o +} + +// SetEmailNic adds the emailNic to the tenancy contacts list params +func (o *TenancyContactsListParams) SetEmailNic(emailNic *string) { + o.EmailNic = emailNic +} + +// WithEmailNie adds the emailNie to the tenancy contacts list params +func (o *TenancyContactsListParams) WithEmailNie(emailNie *string) *TenancyContactsListParams { + o.SetEmailNie(emailNie) + return o +} + +// SetEmailNie adds the emailNie to the tenancy contacts list params +func (o *TenancyContactsListParams) SetEmailNie(emailNie *string) { + o.EmailNie = emailNie +} + +// WithEmailNiew adds the emailNiew to the tenancy contacts list params +func (o *TenancyContactsListParams) WithEmailNiew(emailNiew *string) *TenancyContactsListParams { + o.SetEmailNiew(emailNiew) + return o +} + +// SetEmailNiew adds the emailNiew to the tenancy contacts list params +func (o *TenancyContactsListParams) SetEmailNiew(emailNiew *string) { + o.EmailNiew = emailNiew +} + +// WithEmailNisw adds the emailNisw to the tenancy contacts list params +func (o *TenancyContactsListParams) WithEmailNisw(emailNisw *string) *TenancyContactsListParams { + o.SetEmailNisw(emailNisw) + return o +} + +// SetEmailNisw adds the emailNisw to the tenancy contacts list params +func (o *TenancyContactsListParams) SetEmailNisw(emailNisw *string) { + o.EmailNisw = emailNisw +} + +// WithGroup adds the group to the tenancy contacts list params +func (o *TenancyContactsListParams) WithGroup(group *string) *TenancyContactsListParams { + o.SetGroup(group) + return o +} + +// SetGroup adds the group to the tenancy contacts list params +func (o *TenancyContactsListParams) SetGroup(group *string) { + o.Group = group +} + +// WithGroupn adds the groupn to the tenancy contacts list params +func (o *TenancyContactsListParams) WithGroupn(groupn *string) *TenancyContactsListParams { + o.SetGroupn(groupn) + return o +} + +// SetGroupn adds the groupN to the tenancy contacts list params +func (o *TenancyContactsListParams) SetGroupn(groupn *string) { + o.Groupn = groupn +} + +// WithGroupID adds the groupID to the tenancy contacts list params +func (o *TenancyContactsListParams) WithGroupID(groupID *string) *TenancyContactsListParams { + o.SetGroupID(groupID) + return o +} + +// SetGroupID adds the groupId to the tenancy contacts list params +func (o *TenancyContactsListParams) SetGroupID(groupID *string) { + o.GroupID = groupID +} + +// WithGroupIDn adds the groupIDn to the tenancy contacts list params +func (o *TenancyContactsListParams) WithGroupIDn(groupIDn *string) *TenancyContactsListParams { + o.SetGroupIDn(groupIDn) + return o +} + +// SetGroupIDn adds the groupIdN to the tenancy contacts list params +func (o *TenancyContactsListParams) SetGroupIDn(groupIDn *string) { + o.GroupIDn = groupIDn +} + +// WithID adds the id to the tenancy contacts list params +func (o *TenancyContactsListParams) WithID(id *string) *TenancyContactsListParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contacts list params +func (o *TenancyContactsListParams) SetID(id *string) { + o.ID = id +} + +// WithIDGt adds the iDGt to the tenancy contacts list params +func (o *TenancyContactsListParams) WithIDGt(iDGt *string) *TenancyContactsListParams { + o.SetIDGt(iDGt) + return o +} + +// SetIDGt adds the idGt to the tenancy contacts list params +func (o *TenancyContactsListParams) SetIDGt(iDGt *string) { + o.IDGt = iDGt +} + +// WithIDGte adds the iDGte to the tenancy contacts list params +func (o *TenancyContactsListParams) WithIDGte(iDGte *string) *TenancyContactsListParams { + o.SetIDGte(iDGte) + return o +} + +// SetIDGte adds the idGte to the tenancy contacts list params +func (o *TenancyContactsListParams) SetIDGte(iDGte *string) { + o.IDGte = iDGte +} + +// WithIDLt adds the iDLt to the tenancy contacts list params +func (o *TenancyContactsListParams) WithIDLt(iDLt *string) *TenancyContactsListParams { + o.SetIDLt(iDLt) + return o +} + +// SetIDLt adds the idLt to the tenancy contacts list params +func (o *TenancyContactsListParams) SetIDLt(iDLt *string) { + o.IDLt = iDLt +} + +// WithIDLte adds the iDLte to the tenancy contacts list params +func (o *TenancyContactsListParams) WithIDLte(iDLte *string) *TenancyContactsListParams { + o.SetIDLte(iDLte) + return o +} + +// SetIDLte adds the idLte to the tenancy contacts list params +func (o *TenancyContactsListParams) SetIDLte(iDLte *string) { + o.IDLte = iDLte +} + +// WithIDn adds the iDn to the tenancy contacts list params +func (o *TenancyContactsListParams) WithIDn(iDn *string) *TenancyContactsListParams { + o.SetIDn(iDn) + return o +} + +// SetIDn adds the idN to the tenancy contacts list params +func (o *TenancyContactsListParams) SetIDn(iDn *string) { + o.IDn = iDn +} + +// WithLastUpdated adds the lastUpdated to the tenancy contacts list params +func (o *TenancyContactsListParams) WithLastUpdated(lastUpdated *string) *TenancyContactsListParams { + o.SetLastUpdated(lastUpdated) + return o +} + +// SetLastUpdated adds the lastUpdated to the tenancy contacts list params +func (o *TenancyContactsListParams) SetLastUpdated(lastUpdated *string) { + o.LastUpdated = lastUpdated +} + +// WithLastUpdatedGte adds the lastUpdatedGte to the tenancy contacts list params +func (o *TenancyContactsListParams) WithLastUpdatedGte(lastUpdatedGte *string) *TenancyContactsListParams { + o.SetLastUpdatedGte(lastUpdatedGte) + return o +} + +// SetLastUpdatedGte adds the lastUpdatedGte to the tenancy contacts list params +func (o *TenancyContactsListParams) SetLastUpdatedGte(lastUpdatedGte *string) { + o.LastUpdatedGte = lastUpdatedGte +} + +// WithLastUpdatedLte adds the lastUpdatedLte to the tenancy contacts list params +func (o *TenancyContactsListParams) WithLastUpdatedLte(lastUpdatedLte *string) *TenancyContactsListParams { + o.SetLastUpdatedLte(lastUpdatedLte) + return o +} + +// SetLastUpdatedLte adds the lastUpdatedLte to the tenancy contacts list params +func (o *TenancyContactsListParams) SetLastUpdatedLte(lastUpdatedLte *string) { + o.LastUpdatedLte = lastUpdatedLte +} + +// WithLimit adds the limit to the tenancy contacts list params +func (o *TenancyContactsListParams) WithLimit(limit *int64) *TenancyContactsListParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the tenancy contacts list params +func (o *TenancyContactsListParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithName adds the name to the tenancy contacts list params +func (o *TenancyContactsListParams) WithName(name *string) *TenancyContactsListParams { + o.SetName(name) + return o +} + +// SetName adds the name to the tenancy contacts list params +func (o *TenancyContactsListParams) SetName(name *string) { + o.Name = name +} + +// WithNameEmpty adds the nameEmpty to the tenancy contacts list params +func (o *TenancyContactsListParams) WithNameEmpty(nameEmpty *string) *TenancyContactsListParams { + o.SetNameEmpty(nameEmpty) + return o +} + +// SetNameEmpty adds the nameEmpty to the tenancy contacts list params +func (o *TenancyContactsListParams) SetNameEmpty(nameEmpty *string) { + o.NameEmpty = nameEmpty +} + +// WithNameIc adds the nameIc to the tenancy contacts list params +func (o *TenancyContactsListParams) WithNameIc(nameIc *string) *TenancyContactsListParams { + o.SetNameIc(nameIc) + return o +} + +// SetNameIc adds the nameIc to the tenancy contacts list params +func (o *TenancyContactsListParams) SetNameIc(nameIc *string) { + o.NameIc = nameIc +} + +// WithNameIe adds the nameIe to the tenancy contacts list params +func (o *TenancyContactsListParams) WithNameIe(nameIe *string) *TenancyContactsListParams { + o.SetNameIe(nameIe) + return o +} + +// SetNameIe adds the nameIe to the tenancy contacts list params +func (o *TenancyContactsListParams) SetNameIe(nameIe *string) { + o.NameIe = nameIe +} + +// WithNameIew adds the nameIew to the tenancy contacts list params +func (o *TenancyContactsListParams) WithNameIew(nameIew *string) *TenancyContactsListParams { + o.SetNameIew(nameIew) + return o +} + +// SetNameIew adds the nameIew to the tenancy contacts list params +func (o *TenancyContactsListParams) SetNameIew(nameIew *string) { + o.NameIew = nameIew +} + +// WithNameIsw adds the nameIsw to the tenancy contacts list params +func (o *TenancyContactsListParams) WithNameIsw(nameIsw *string) *TenancyContactsListParams { + o.SetNameIsw(nameIsw) + return o +} + +// SetNameIsw adds the nameIsw to the tenancy contacts list params +func (o *TenancyContactsListParams) SetNameIsw(nameIsw *string) { + o.NameIsw = nameIsw +} + +// WithNamen adds the namen to the tenancy contacts list params +func (o *TenancyContactsListParams) WithNamen(namen *string) *TenancyContactsListParams { + o.SetNamen(namen) + return o +} + +// SetNamen adds the nameN to the tenancy contacts list params +func (o *TenancyContactsListParams) SetNamen(namen *string) { + o.Namen = namen +} + +// WithNameNic adds the nameNic to the tenancy contacts list params +func (o *TenancyContactsListParams) WithNameNic(nameNic *string) *TenancyContactsListParams { + o.SetNameNic(nameNic) + return o +} + +// SetNameNic adds the nameNic to the tenancy contacts list params +func (o *TenancyContactsListParams) SetNameNic(nameNic *string) { + o.NameNic = nameNic +} + +// WithNameNie adds the nameNie to the tenancy contacts list params +func (o *TenancyContactsListParams) WithNameNie(nameNie *string) *TenancyContactsListParams { + o.SetNameNie(nameNie) + return o +} + +// SetNameNie adds the nameNie to the tenancy contacts list params +func (o *TenancyContactsListParams) SetNameNie(nameNie *string) { + o.NameNie = nameNie +} + +// WithNameNiew adds the nameNiew to the tenancy contacts list params +func (o *TenancyContactsListParams) WithNameNiew(nameNiew *string) *TenancyContactsListParams { + o.SetNameNiew(nameNiew) + return o +} + +// SetNameNiew adds the nameNiew to the tenancy contacts list params +func (o *TenancyContactsListParams) SetNameNiew(nameNiew *string) { + o.NameNiew = nameNiew +} + +// WithNameNisw adds the nameNisw to the tenancy contacts list params +func (o *TenancyContactsListParams) WithNameNisw(nameNisw *string) *TenancyContactsListParams { + o.SetNameNisw(nameNisw) + return o +} + +// SetNameNisw adds the nameNisw to the tenancy contacts list params +func (o *TenancyContactsListParams) SetNameNisw(nameNisw *string) { + o.NameNisw = nameNisw +} + +// WithOffset adds the offset to the tenancy contacts list params +func (o *TenancyContactsListParams) WithOffset(offset *int64) *TenancyContactsListParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the tenancy contacts list params +func (o *TenancyContactsListParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithPhone adds the phone to the tenancy contacts list params +func (o *TenancyContactsListParams) WithPhone(phone *string) *TenancyContactsListParams { + o.SetPhone(phone) + return o +} + +// SetPhone adds the phone to the tenancy contacts list params +func (o *TenancyContactsListParams) SetPhone(phone *string) { + o.Phone = phone +} + +// WithPhoneEmpty adds the phoneEmpty to the tenancy contacts list params +func (o *TenancyContactsListParams) WithPhoneEmpty(phoneEmpty *string) *TenancyContactsListParams { + o.SetPhoneEmpty(phoneEmpty) + return o +} + +// SetPhoneEmpty adds the phoneEmpty to the tenancy contacts list params +func (o *TenancyContactsListParams) SetPhoneEmpty(phoneEmpty *string) { + o.PhoneEmpty = phoneEmpty +} + +// WithPhoneIc adds the phoneIc to the tenancy contacts list params +func (o *TenancyContactsListParams) WithPhoneIc(phoneIc *string) *TenancyContactsListParams { + o.SetPhoneIc(phoneIc) + return o +} + +// SetPhoneIc adds the phoneIc to the tenancy contacts list params +func (o *TenancyContactsListParams) SetPhoneIc(phoneIc *string) { + o.PhoneIc = phoneIc +} + +// WithPhoneIe adds the phoneIe to the tenancy contacts list params +func (o *TenancyContactsListParams) WithPhoneIe(phoneIe *string) *TenancyContactsListParams { + o.SetPhoneIe(phoneIe) + return o +} + +// SetPhoneIe adds the phoneIe to the tenancy contacts list params +func (o *TenancyContactsListParams) SetPhoneIe(phoneIe *string) { + o.PhoneIe = phoneIe +} + +// WithPhoneIew adds the phoneIew to the tenancy contacts list params +func (o *TenancyContactsListParams) WithPhoneIew(phoneIew *string) *TenancyContactsListParams { + o.SetPhoneIew(phoneIew) + return o +} + +// SetPhoneIew adds the phoneIew to the tenancy contacts list params +func (o *TenancyContactsListParams) SetPhoneIew(phoneIew *string) { + o.PhoneIew = phoneIew +} + +// WithPhoneIsw adds the phoneIsw to the tenancy contacts list params +func (o *TenancyContactsListParams) WithPhoneIsw(phoneIsw *string) *TenancyContactsListParams { + o.SetPhoneIsw(phoneIsw) + return o +} + +// SetPhoneIsw adds the phoneIsw to the tenancy contacts list params +func (o *TenancyContactsListParams) SetPhoneIsw(phoneIsw *string) { + o.PhoneIsw = phoneIsw +} + +// WithPhonen adds the phonen to the tenancy contacts list params +func (o *TenancyContactsListParams) WithPhonen(phonen *string) *TenancyContactsListParams { + o.SetPhonen(phonen) + return o +} + +// SetPhonen adds the phoneN to the tenancy contacts list params +func (o *TenancyContactsListParams) SetPhonen(phonen *string) { + o.Phonen = phonen +} + +// WithPhoneNic adds the phoneNic to the tenancy contacts list params +func (o *TenancyContactsListParams) WithPhoneNic(phoneNic *string) *TenancyContactsListParams { + o.SetPhoneNic(phoneNic) + return o +} + +// SetPhoneNic adds the phoneNic to the tenancy contacts list params +func (o *TenancyContactsListParams) SetPhoneNic(phoneNic *string) { + o.PhoneNic = phoneNic +} + +// WithPhoneNie adds the phoneNie to the tenancy contacts list params +func (o *TenancyContactsListParams) WithPhoneNie(phoneNie *string) *TenancyContactsListParams { + o.SetPhoneNie(phoneNie) + return o +} + +// SetPhoneNie adds the phoneNie to the tenancy contacts list params +func (o *TenancyContactsListParams) SetPhoneNie(phoneNie *string) { + o.PhoneNie = phoneNie +} + +// WithPhoneNiew adds the phoneNiew to the tenancy contacts list params +func (o *TenancyContactsListParams) WithPhoneNiew(phoneNiew *string) *TenancyContactsListParams { + o.SetPhoneNiew(phoneNiew) + return o +} + +// SetPhoneNiew adds the phoneNiew to the tenancy contacts list params +func (o *TenancyContactsListParams) SetPhoneNiew(phoneNiew *string) { + o.PhoneNiew = phoneNiew +} + +// WithPhoneNisw adds the phoneNisw to the tenancy contacts list params +func (o *TenancyContactsListParams) WithPhoneNisw(phoneNisw *string) *TenancyContactsListParams { + o.SetPhoneNisw(phoneNisw) + return o +} + +// SetPhoneNisw adds the phoneNisw to the tenancy contacts list params +func (o *TenancyContactsListParams) SetPhoneNisw(phoneNisw *string) { + o.PhoneNisw = phoneNisw +} + +// WithQ adds the q to the tenancy contacts list params +func (o *TenancyContactsListParams) WithQ(q *string) *TenancyContactsListParams { + o.SetQ(q) + return o +} + +// SetQ adds the q to the tenancy contacts list params +func (o *TenancyContactsListParams) SetQ(q *string) { + o.Q = q +} + +// WithTag adds the tag to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTag(tag *string) *TenancyContactsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTagn(tagn *string) *TenancyContactsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + +// WithTitle adds the title to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTitle(title *string) *TenancyContactsListParams { + o.SetTitle(title) + return o +} + +// SetTitle adds the title to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTitle(title *string) { + o.Title = title +} + +// WithTitleEmpty adds the titleEmpty to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTitleEmpty(titleEmpty *string) *TenancyContactsListParams { + o.SetTitleEmpty(titleEmpty) + return o +} + +// SetTitleEmpty adds the titleEmpty to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTitleEmpty(titleEmpty *string) { + o.TitleEmpty = titleEmpty +} + +// WithTitleIc adds the titleIc to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTitleIc(titleIc *string) *TenancyContactsListParams { + o.SetTitleIc(titleIc) + return o +} + +// SetTitleIc adds the titleIc to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTitleIc(titleIc *string) { + o.TitleIc = titleIc +} + +// WithTitleIe adds the titleIe to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTitleIe(titleIe *string) *TenancyContactsListParams { + o.SetTitleIe(titleIe) + return o +} + +// SetTitleIe adds the titleIe to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTitleIe(titleIe *string) { + o.TitleIe = titleIe +} + +// WithTitleIew adds the titleIew to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTitleIew(titleIew *string) *TenancyContactsListParams { + o.SetTitleIew(titleIew) + return o +} + +// SetTitleIew adds the titleIew to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTitleIew(titleIew *string) { + o.TitleIew = titleIew +} + +// WithTitleIsw adds the titleIsw to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTitleIsw(titleIsw *string) *TenancyContactsListParams { + o.SetTitleIsw(titleIsw) + return o +} + +// SetTitleIsw adds the titleIsw to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTitleIsw(titleIsw *string) { + o.TitleIsw = titleIsw +} + +// WithTitlen adds the titlen to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTitlen(titlen *string) *TenancyContactsListParams { + o.SetTitlen(titlen) + return o +} + +// SetTitlen adds the titleN to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTitlen(titlen *string) { + o.Titlen = titlen +} + +// WithTitleNic adds the titleNic to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTitleNic(titleNic *string) *TenancyContactsListParams { + o.SetTitleNic(titleNic) + return o +} + +// SetTitleNic adds the titleNic to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTitleNic(titleNic *string) { + o.TitleNic = titleNic +} + +// WithTitleNie adds the titleNie to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTitleNie(titleNie *string) *TenancyContactsListParams { + o.SetTitleNie(titleNie) + return o +} + +// SetTitleNie adds the titleNie to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTitleNie(titleNie *string) { + o.TitleNie = titleNie +} + +// WithTitleNiew adds the titleNiew to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTitleNiew(titleNiew *string) *TenancyContactsListParams { + o.SetTitleNiew(titleNiew) + return o +} + +// SetTitleNiew adds the titleNiew to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTitleNiew(titleNiew *string) { + o.TitleNiew = titleNiew +} + +// WithTitleNisw adds the titleNisw to the tenancy contacts list params +func (o *TenancyContactsListParams) WithTitleNisw(titleNisw *string) *TenancyContactsListParams { + o.SetTitleNisw(titleNisw) + return o +} + +// SetTitleNisw adds the titleNisw to the tenancy contacts list params +func (o *TenancyContactsListParams) SetTitleNisw(titleNisw *string) { + o.TitleNisw = titleNisw +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.Address != nil { + + // query param address + var qrAddress string + + if o.Address != nil { + qrAddress = *o.Address + } + qAddress := qrAddress + if qAddress != "" { + + if err := r.SetQueryParam("address", qAddress); err != nil { + return err + } + } + } + + if o.AddressEmpty != nil { + + // query param address__empty + var qrAddressEmpty string + + if o.AddressEmpty != nil { + qrAddressEmpty = *o.AddressEmpty + } + qAddressEmpty := qrAddressEmpty + if qAddressEmpty != "" { + + if err := r.SetQueryParam("address__empty", qAddressEmpty); err != nil { + return err + } + } + } + + if o.AddressIc != nil { + + // query param address__ic + var qrAddressIc string + + if o.AddressIc != nil { + qrAddressIc = *o.AddressIc + } + qAddressIc := qrAddressIc + if qAddressIc != "" { + + if err := r.SetQueryParam("address__ic", qAddressIc); err != nil { + return err + } + } + } + + if o.AddressIe != nil { + + // query param address__ie + var qrAddressIe string + + if o.AddressIe != nil { + qrAddressIe = *o.AddressIe + } + qAddressIe := qrAddressIe + if qAddressIe != "" { + + if err := r.SetQueryParam("address__ie", qAddressIe); err != nil { + return err + } + } + } + + if o.AddressIew != nil { + + // query param address__iew + var qrAddressIew string + + if o.AddressIew != nil { + qrAddressIew = *o.AddressIew + } + qAddressIew := qrAddressIew + if qAddressIew != "" { + + if err := r.SetQueryParam("address__iew", qAddressIew); err != nil { + return err + } + } + } + + if o.AddressIsw != nil { + + // query param address__isw + var qrAddressIsw string + + if o.AddressIsw != nil { + qrAddressIsw = *o.AddressIsw + } + qAddressIsw := qrAddressIsw + if qAddressIsw != "" { + + if err := r.SetQueryParam("address__isw", qAddressIsw); err != nil { + return err + } + } + } + + if o.Addressn != nil { + + // query param address__n + var qrAddressn string + + if o.Addressn != nil { + qrAddressn = *o.Addressn + } + qAddressn := qrAddressn + if qAddressn != "" { + + if err := r.SetQueryParam("address__n", qAddressn); err != nil { + return err + } + } + } + + if o.AddressNic != nil { + + // query param address__nic + var qrAddressNic string + + if o.AddressNic != nil { + qrAddressNic = *o.AddressNic + } + qAddressNic := qrAddressNic + if qAddressNic != "" { + + if err := r.SetQueryParam("address__nic", qAddressNic); err != nil { + return err + } + } + } + + if o.AddressNie != nil { + + // query param address__nie + var qrAddressNie string + + if o.AddressNie != nil { + qrAddressNie = *o.AddressNie + } + qAddressNie := qrAddressNie + if qAddressNie != "" { + + if err := r.SetQueryParam("address__nie", qAddressNie); err != nil { + return err + } + } + } + + if o.AddressNiew != nil { + + // query param address__niew + var qrAddressNiew string + + if o.AddressNiew != nil { + qrAddressNiew = *o.AddressNiew + } + qAddressNiew := qrAddressNiew + if qAddressNiew != "" { + + if err := r.SetQueryParam("address__niew", qAddressNiew); err != nil { + return err + } + } + } + + if o.AddressNisw != nil { + + // query param address__nisw + var qrAddressNisw string + + if o.AddressNisw != nil { + qrAddressNisw = *o.AddressNisw + } + qAddressNisw := qrAddressNisw + if qAddressNisw != "" { + + if err := r.SetQueryParam("address__nisw", qAddressNisw); err != nil { + return err + } + } + } + + if o.Created != nil { + + // query param created + var qrCreated string + + if o.Created != nil { + qrCreated = *o.Created + } + qCreated := qrCreated + if qCreated != "" { + + if err := r.SetQueryParam("created", qCreated); err != nil { + return err + } + } + } + + if o.CreatedGte != nil { + + // query param created__gte + var qrCreatedGte string + + if o.CreatedGte != nil { + qrCreatedGte = *o.CreatedGte + } + qCreatedGte := qrCreatedGte + if qCreatedGte != "" { + + if err := r.SetQueryParam("created__gte", qCreatedGte); err != nil { + return err + } + } + } + + if o.CreatedLte != nil { + + // query param created__lte + var qrCreatedLte string + + if o.CreatedLte != nil { + qrCreatedLte = *o.CreatedLte + } + qCreatedLte := qrCreatedLte + if qCreatedLte != "" { + + if err := r.SetQueryParam("created__lte", qCreatedLte); err != nil { + return err + } + } + } + + if o.Email != nil { + + // query param email + var qrEmail string + + if o.Email != nil { + qrEmail = *o.Email + } + qEmail := qrEmail + if qEmail != "" { + + if err := r.SetQueryParam("email", qEmail); err != nil { + return err + } + } + } + + if o.EmailEmpty != nil { + + // query param email__empty + var qrEmailEmpty string + + if o.EmailEmpty != nil { + qrEmailEmpty = *o.EmailEmpty + } + qEmailEmpty := qrEmailEmpty + if qEmailEmpty != "" { + + if err := r.SetQueryParam("email__empty", qEmailEmpty); err != nil { + return err + } + } + } + + if o.EmailIc != nil { + + // query param email__ic + var qrEmailIc string + + if o.EmailIc != nil { + qrEmailIc = *o.EmailIc + } + qEmailIc := qrEmailIc + if qEmailIc != "" { + + if err := r.SetQueryParam("email__ic", qEmailIc); err != nil { + return err + } + } + } + + if o.EmailIe != nil { + + // query param email__ie + var qrEmailIe string + + if o.EmailIe != nil { + qrEmailIe = *o.EmailIe + } + qEmailIe := qrEmailIe + if qEmailIe != "" { + + if err := r.SetQueryParam("email__ie", qEmailIe); err != nil { + return err + } + } + } + + if o.EmailIew != nil { + + // query param email__iew + var qrEmailIew string + + if o.EmailIew != nil { + qrEmailIew = *o.EmailIew + } + qEmailIew := qrEmailIew + if qEmailIew != "" { + + if err := r.SetQueryParam("email__iew", qEmailIew); err != nil { + return err + } + } + } + + if o.EmailIsw != nil { + + // query param email__isw + var qrEmailIsw string + + if o.EmailIsw != nil { + qrEmailIsw = *o.EmailIsw + } + qEmailIsw := qrEmailIsw + if qEmailIsw != "" { + + if err := r.SetQueryParam("email__isw", qEmailIsw); err != nil { + return err + } + } + } + + if o.Emailn != nil { + + // query param email__n + var qrEmailn string + + if o.Emailn != nil { + qrEmailn = *o.Emailn + } + qEmailn := qrEmailn + if qEmailn != "" { + + if err := r.SetQueryParam("email__n", qEmailn); err != nil { + return err + } + } + } + + if o.EmailNic != nil { + + // query param email__nic + var qrEmailNic string + + if o.EmailNic != nil { + qrEmailNic = *o.EmailNic + } + qEmailNic := qrEmailNic + if qEmailNic != "" { + + if err := r.SetQueryParam("email__nic", qEmailNic); err != nil { + return err + } + } + } + + if o.EmailNie != nil { + + // query param email__nie + var qrEmailNie string + + if o.EmailNie != nil { + qrEmailNie = *o.EmailNie + } + qEmailNie := qrEmailNie + if qEmailNie != "" { + + if err := r.SetQueryParam("email__nie", qEmailNie); err != nil { + return err + } + } + } + + if o.EmailNiew != nil { + + // query param email__niew + var qrEmailNiew string + + if o.EmailNiew != nil { + qrEmailNiew = *o.EmailNiew + } + qEmailNiew := qrEmailNiew + if qEmailNiew != "" { + + if err := r.SetQueryParam("email__niew", qEmailNiew); err != nil { + return err + } + } + } + + if o.EmailNisw != nil { + + // query param email__nisw + var qrEmailNisw string + + if o.EmailNisw != nil { + qrEmailNisw = *o.EmailNisw + } + qEmailNisw := qrEmailNisw + if qEmailNisw != "" { + + if err := r.SetQueryParam("email__nisw", qEmailNisw); err != nil { + return err + } + } + } + + if o.Group != nil { + + // query param group + var qrGroup string + + if o.Group != nil { + qrGroup = *o.Group + } + qGroup := qrGroup + if qGroup != "" { + + if err := r.SetQueryParam("group", qGroup); err != nil { + return err + } + } + } + + if o.Groupn != nil { + + // query param group__n + var qrGroupn string + + if o.Groupn != nil { + qrGroupn = *o.Groupn + } + qGroupn := qrGroupn + if qGroupn != "" { + + if err := r.SetQueryParam("group__n", qGroupn); err != nil { + return err + } + } + } + + if o.GroupID != nil { + + // query param group_id + var qrGroupID string + + if o.GroupID != nil { + qrGroupID = *o.GroupID + } + qGroupID := qrGroupID + if qGroupID != "" { + + if err := r.SetQueryParam("group_id", qGroupID); err != nil { + return err + } + } + } + + if o.GroupIDn != nil { + + // query param group_id__n + var qrGroupIDn string + + if o.GroupIDn != nil { + qrGroupIDn = *o.GroupIDn + } + qGroupIDn := qrGroupIDn + if qGroupIDn != "" { + + if err := r.SetQueryParam("group_id__n", qGroupIDn); err != nil { + return err + } + } + } + + if o.ID != nil { + + // query param id + var qrID string + + if o.ID != nil { + qrID = *o.ID + } + qID := qrID + if qID != "" { + + if err := r.SetQueryParam("id", qID); err != nil { + return err + } + } + } + + if o.IDGt != nil { + + // query param id__gt + var qrIDGt string + + if o.IDGt != nil { + qrIDGt = *o.IDGt + } + qIDGt := qrIDGt + if qIDGt != "" { + + if err := r.SetQueryParam("id__gt", qIDGt); err != nil { + return err + } + } + } + + if o.IDGte != nil { + + // query param id__gte + var qrIDGte string + + if o.IDGte != nil { + qrIDGte = *o.IDGte + } + qIDGte := qrIDGte + if qIDGte != "" { + + if err := r.SetQueryParam("id__gte", qIDGte); err != nil { + return err + } + } + } + + if o.IDLt != nil { + + // query param id__lt + var qrIDLt string + + if o.IDLt != nil { + qrIDLt = *o.IDLt + } + qIDLt := qrIDLt + if qIDLt != "" { + + if err := r.SetQueryParam("id__lt", qIDLt); err != nil { + return err + } + } + } + + if o.IDLte != nil { + + // query param id__lte + var qrIDLte string + + if o.IDLte != nil { + qrIDLte = *o.IDLte + } + qIDLte := qrIDLte + if qIDLte != "" { + + if err := r.SetQueryParam("id__lte", qIDLte); err != nil { + return err + } + } + } + + if o.IDn != nil { + + // query param id__n + var qrIDn string + + if o.IDn != nil { + qrIDn = *o.IDn + } + qIDn := qrIDn + if qIDn != "" { + + if err := r.SetQueryParam("id__n", qIDn); err != nil { + return err + } + } + } + + if o.LastUpdated != nil { + + // query param last_updated + var qrLastUpdated string + + if o.LastUpdated != nil { + qrLastUpdated = *o.LastUpdated + } + qLastUpdated := qrLastUpdated + if qLastUpdated != "" { + + if err := r.SetQueryParam("last_updated", qLastUpdated); err != nil { + return err + } + } + } + + if o.LastUpdatedGte != nil { + + // query param last_updated__gte + var qrLastUpdatedGte string + + if o.LastUpdatedGte != nil { + qrLastUpdatedGte = *o.LastUpdatedGte + } + qLastUpdatedGte := qrLastUpdatedGte + if qLastUpdatedGte != "" { + + if err := r.SetQueryParam("last_updated__gte", qLastUpdatedGte); err != nil { + return err + } + } + } + + if o.LastUpdatedLte != nil { + + // query param last_updated__lte + var qrLastUpdatedLte string + + if o.LastUpdatedLte != nil { + qrLastUpdatedLte = *o.LastUpdatedLte + } + qLastUpdatedLte := qrLastUpdatedLte + if qLastUpdatedLte != "" { + + if err := r.SetQueryParam("last_updated__lte", qLastUpdatedLte); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Name != nil { + + // query param name + var qrName string + + if o.Name != nil { + qrName = *o.Name + } + qName := qrName + if qName != "" { + + if err := r.SetQueryParam("name", qName); err != nil { + return err + } + } + } + + if o.NameEmpty != nil { + + // query param name__empty + var qrNameEmpty string + + if o.NameEmpty != nil { + qrNameEmpty = *o.NameEmpty + } + qNameEmpty := qrNameEmpty + if qNameEmpty != "" { + + if err := r.SetQueryParam("name__empty", qNameEmpty); err != nil { + return err + } + } + } + + if o.NameIc != nil { + + // query param name__ic + var qrNameIc string + + if o.NameIc != nil { + qrNameIc = *o.NameIc + } + qNameIc := qrNameIc + if qNameIc != "" { + + if err := r.SetQueryParam("name__ic", qNameIc); err != nil { + return err + } + } + } + + if o.NameIe != nil { + + // query param name__ie + var qrNameIe string + + if o.NameIe != nil { + qrNameIe = *o.NameIe + } + qNameIe := qrNameIe + if qNameIe != "" { + + if err := r.SetQueryParam("name__ie", qNameIe); err != nil { + return err + } + } + } + + if o.NameIew != nil { + + // query param name__iew + var qrNameIew string + + if o.NameIew != nil { + qrNameIew = *o.NameIew + } + qNameIew := qrNameIew + if qNameIew != "" { + + if err := r.SetQueryParam("name__iew", qNameIew); err != nil { + return err + } + } + } + + if o.NameIsw != nil { + + // query param name__isw + var qrNameIsw string + + if o.NameIsw != nil { + qrNameIsw = *o.NameIsw + } + qNameIsw := qrNameIsw + if qNameIsw != "" { + + if err := r.SetQueryParam("name__isw", qNameIsw); err != nil { + return err + } + } + } + + if o.Namen != nil { + + // query param name__n + var qrNamen string + + if o.Namen != nil { + qrNamen = *o.Namen + } + qNamen := qrNamen + if qNamen != "" { + + if err := r.SetQueryParam("name__n", qNamen); err != nil { + return err + } + } + } + + if o.NameNic != nil { + + // query param name__nic + var qrNameNic string + + if o.NameNic != nil { + qrNameNic = *o.NameNic + } + qNameNic := qrNameNic + if qNameNic != "" { + + if err := r.SetQueryParam("name__nic", qNameNic); err != nil { + return err + } + } + } + + if o.NameNie != nil { + + // query param name__nie + var qrNameNie string + + if o.NameNie != nil { + qrNameNie = *o.NameNie + } + qNameNie := qrNameNie + if qNameNie != "" { + + if err := r.SetQueryParam("name__nie", qNameNie); err != nil { + return err + } + } + } + + if o.NameNiew != nil { + + // query param name__niew + var qrNameNiew string + + if o.NameNiew != nil { + qrNameNiew = *o.NameNiew + } + qNameNiew := qrNameNiew + if qNameNiew != "" { + + if err := r.SetQueryParam("name__niew", qNameNiew); err != nil { + return err + } + } + } + + if o.NameNisw != nil { + + // query param name__nisw + var qrNameNisw string + + if o.NameNisw != nil { + qrNameNisw = *o.NameNisw + } + qNameNisw := qrNameNisw + if qNameNisw != "" { + + if err := r.SetQueryParam("name__nisw", qNameNisw); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.Phone != nil { + + // query param phone + var qrPhone string + + if o.Phone != nil { + qrPhone = *o.Phone + } + qPhone := qrPhone + if qPhone != "" { + + if err := r.SetQueryParam("phone", qPhone); err != nil { + return err + } + } + } + + if o.PhoneEmpty != nil { + + // query param phone__empty + var qrPhoneEmpty string + + if o.PhoneEmpty != nil { + qrPhoneEmpty = *o.PhoneEmpty + } + qPhoneEmpty := qrPhoneEmpty + if qPhoneEmpty != "" { + + if err := r.SetQueryParam("phone__empty", qPhoneEmpty); err != nil { + return err + } + } + } + + if o.PhoneIc != nil { + + // query param phone__ic + var qrPhoneIc string + + if o.PhoneIc != nil { + qrPhoneIc = *o.PhoneIc + } + qPhoneIc := qrPhoneIc + if qPhoneIc != "" { + + if err := r.SetQueryParam("phone__ic", qPhoneIc); err != nil { + return err + } + } + } + + if o.PhoneIe != nil { + + // query param phone__ie + var qrPhoneIe string + + if o.PhoneIe != nil { + qrPhoneIe = *o.PhoneIe + } + qPhoneIe := qrPhoneIe + if qPhoneIe != "" { + + if err := r.SetQueryParam("phone__ie", qPhoneIe); err != nil { + return err + } + } + } + + if o.PhoneIew != nil { + + // query param phone__iew + var qrPhoneIew string + + if o.PhoneIew != nil { + qrPhoneIew = *o.PhoneIew + } + qPhoneIew := qrPhoneIew + if qPhoneIew != "" { + + if err := r.SetQueryParam("phone__iew", qPhoneIew); err != nil { + return err + } + } + } + + if o.PhoneIsw != nil { + + // query param phone__isw + var qrPhoneIsw string + + if o.PhoneIsw != nil { + qrPhoneIsw = *o.PhoneIsw + } + qPhoneIsw := qrPhoneIsw + if qPhoneIsw != "" { + + if err := r.SetQueryParam("phone__isw", qPhoneIsw); err != nil { + return err + } + } + } + + if o.Phonen != nil { + + // query param phone__n + var qrPhonen string + + if o.Phonen != nil { + qrPhonen = *o.Phonen + } + qPhonen := qrPhonen + if qPhonen != "" { + + if err := r.SetQueryParam("phone__n", qPhonen); err != nil { + return err + } + } + } + + if o.PhoneNic != nil { + + // query param phone__nic + var qrPhoneNic string + + if o.PhoneNic != nil { + qrPhoneNic = *o.PhoneNic + } + qPhoneNic := qrPhoneNic + if qPhoneNic != "" { + + if err := r.SetQueryParam("phone__nic", qPhoneNic); err != nil { + return err + } + } + } + + if o.PhoneNie != nil { + + // query param phone__nie + var qrPhoneNie string + + if o.PhoneNie != nil { + qrPhoneNie = *o.PhoneNie + } + qPhoneNie := qrPhoneNie + if qPhoneNie != "" { + + if err := r.SetQueryParam("phone__nie", qPhoneNie); err != nil { + return err + } + } + } + + if o.PhoneNiew != nil { + + // query param phone__niew + var qrPhoneNiew string + + if o.PhoneNiew != nil { + qrPhoneNiew = *o.PhoneNiew + } + qPhoneNiew := qrPhoneNiew + if qPhoneNiew != "" { + + if err := r.SetQueryParam("phone__niew", qPhoneNiew); err != nil { + return err + } + } + } + + if o.PhoneNisw != nil { + + // query param phone__nisw + var qrPhoneNisw string + + if o.PhoneNisw != nil { + qrPhoneNisw = *o.PhoneNisw + } + qPhoneNisw := qrPhoneNisw + if qPhoneNisw != "" { + + if err := r.SetQueryParam("phone__nisw", qPhoneNisw); err != nil { + return err + } + } + } + + if o.Q != nil { + + // query param q + var qrQ string + + if o.Q != nil { + qrQ = *o.Q + } + qQ := qrQ + if qQ != "" { + + if err := r.SetQueryParam("q", qQ); err != nil { + return err + } + } + } + + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + + if o.Title != nil { + + // query param title + var qrTitle string + + if o.Title != nil { + qrTitle = *o.Title + } + qTitle := qrTitle + if qTitle != "" { + + if err := r.SetQueryParam("title", qTitle); err != nil { + return err + } + } + } + + if o.TitleEmpty != nil { + + // query param title__empty + var qrTitleEmpty string + + if o.TitleEmpty != nil { + qrTitleEmpty = *o.TitleEmpty + } + qTitleEmpty := qrTitleEmpty + if qTitleEmpty != "" { + + if err := r.SetQueryParam("title__empty", qTitleEmpty); err != nil { + return err + } + } + } + + if o.TitleIc != nil { + + // query param title__ic + var qrTitleIc string + + if o.TitleIc != nil { + qrTitleIc = *o.TitleIc + } + qTitleIc := qrTitleIc + if qTitleIc != "" { + + if err := r.SetQueryParam("title__ic", qTitleIc); err != nil { + return err + } + } + } + + if o.TitleIe != nil { + + // query param title__ie + var qrTitleIe string + + if o.TitleIe != nil { + qrTitleIe = *o.TitleIe + } + qTitleIe := qrTitleIe + if qTitleIe != "" { + + if err := r.SetQueryParam("title__ie", qTitleIe); err != nil { + return err + } + } + } + + if o.TitleIew != nil { + + // query param title__iew + var qrTitleIew string + + if o.TitleIew != nil { + qrTitleIew = *o.TitleIew + } + qTitleIew := qrTitleIew + if qTitleIew != "" { + + if err := r.SetQueryParam("title__iew", qTitleIew); err != nil { + return err + } + } + } + + if o.TitleIsw != nil { + + // query param title__isw + var qrTitleIsw string + + if o.TitleIsw != nil { + qrTitleIsw = *o.TitleIsw + } + qTitleIsw := qrTitleIsw + if qTitleIsw != "" { + + if err := r.SetQueryParam("title__isw", qTitleIsw); err != nil { + return err + } + } + } + + if o.Titlen != nil { + + // query param title__n + var qrTitlen string + + if o.Titlen != nil { + qrTitlen = *o.Titlen + } + qTitlen := qrTitlen + if qTitlen != "" { + + if err := r.SetQueryParam("title__n", qTitlen); err != nil { + return err + } + } + } + + if o.TitleNic != nil { + + // query param title__nic + var qrTitleNic string + + if o.TitleNic != nil { + qrTitleNic = *o.TitleNic + } + qTitleNic := qrTitleNic + if qTitleNic != "" { + + if err := r.SetQueryParam("title__nic", qTitleNic); err != nil { + return err + } + } + } + + if o.TitleNie != nil { + + // query param title__nie + var qrTitleNie string + + if o.TitleNie != nil { + qrTitleNie = *o.TitleNie + } + qTitleNie := qrTitleNie + if qTitleNie != "" { + + if err := r.SetQueryParam("title__nie", qTitleNie); err != nil { + return err + } + } + } + + if o.TitleNiew != nil { + + // query param title__niew + var qrTitleNiew string + + if o.TitleNiew != nil { + qrTitleNiew = *o.TitleNiew + } + qTitleNiew := qrTitleNiew + if qTitleNiew != "" { + + if err := r.SetQueryParam("title__niew", qTitleNiew); err != nil { + return err + } + } + } + + if o.TitleNisw != nil { + + // query param title__nisw + var qrTitleNisw string + + if o.TitleNisw != nil { + qrTitleNisw = *o.TitleNisw + } + qTitleNisw := qrTitleNisw + if qTitleNisw != "" { + + if err := r.SetQueryParam("title__nisw", qTitleNisw); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_list_responses.go b/netbox/client/tenancy/tenancy_contacts_list_responses.go new file mode 100644 index 00000000..d7cf7c5c --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_list_responses.go @@ -0,0 +1,247 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactsListReader is a Reader for the TenancyContactsList structure. +type TenancyContactsListReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactsListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactsListOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactsListOK creates a TenancyContactsListOK with default headers values +func NewTenancyContactsListOK() *TenancyContactsListOK { + return &TenancyContactsListOK{} +} + +/* TenancyContactsListOK describes a response with status code 200, with default header values. + +TenancyContactsListOK tenancy contacts list o k +*/ +type TenancyContactsListOK struct { + Payload *TenancyContactsListOKBody +} + +func (o *TenancyContactsListOK) Error() string { + return fmt.Sprintf("[GET /tenancy/contacts/][%d] tenancyContactsListOK %+v", 200, o.Payload) +} +func (o *TenancyContactsListOK) GetPayload() *TenancyContactsListOKBody { + return o.Payload +} + +func (o *TenancyContactsListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(TenancyContactsListOKBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*TenancyContactsListOKBody tenancy contacts list o k body +swagger:model TenancyContactsListOKBody +*/ +type TenancyContactsListOKBody struct { + + // count + // Required: true + Count *int64 `json:"count"` + + // next + // Format: uri + Next *strfmt.URI `json:"next,omitempty"` + + // previous + // Format: uri + Previous *strfmt.URI `json:"previous,omitempty"` + + // results + // Required: true + Results []*models.Contact `json:"results"` +} + +// Validate validates this tenancy contacts list o k body +func (o *TenancyContactsListOKBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateCount(formats); err != nil { + res = append(res, err) + } + + if err := o.validateNext(formats); err != nil { + res = append(res, err) + } + + if err := o.validatePrevious(formats); err != nil { + res = append(res, err) + } + + if err := o.validateResults(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *TenancyContactsListOKBody) validateCount(formats strfmt.Registry) error { + + if err := validate.Required("tenancyContactsListOK"+"."+"count", "body", o.Count); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactsListOKBody) validateNext(formats strfmt.Registry) error { + if swag.IsZero(o.Next) { // not required + return nil + } + + if err := validate.FormatOf("tenancyContactsListOK"+"."+"next", "body", "uri", o.Next.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactsListOKBody) validatePrevious(formats strfmt.Registry) error { + if swag.IsZero(o.Previous) { // not required + return nil + } + + if err := validate.FormatOf("tenancyContactsListOK"+"."+"previous", "body", "uri", o.Previous.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *TenancyContactsListOKBody) validateResults(formats strfmt.Registry) error { + + if err := validate.Required("tenancyContactsListOK"+"."+"results", "body", o.Results); err != nil { + return err + } + + for i := 0; i < len(o.Results); i++ { + if swag.IsZero(o.Results[i]) { // not required + continue + } + + if o.Results[i] != nil { + if err := o.Results[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenancyContactsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenancyContactsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this tenancy contacts list o k body based on the context it is used +func (o *TenancyContactsListOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := o.contextValidateResults(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *TenancyContactsListOKBody) contextValidateResults(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(o.Results); i++ { + + if o.Results[i] != nil { + if err := o.Results[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenancyContactsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenancyContactsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (o *TenancyContactsListOKBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *TenancyContactsListOKBody) UnmarshalBinary(b []byte) error { + var res TenancyContactsListOKBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_partial_update_parameters.go b/netbox/client/tenancy/tenancy_contacts_partial_update_parameters.go new file mode 100644 index 00000000..3d963766 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_partial_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactsPartialUpdateParams creates a new TenancyContactsPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactsPartialUpdateParams() *TenancyContactsPartialUpdateParams { + return &TenancyContactsPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactsPartialUpdateParamsWithTimeout creates a new TenancyContactsPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactsPartialUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactsPartialUpdateParams { + return &TenancyContactsPartialUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactsPartialUpdateParamsWithContext creates a new TenancyContactsPartialUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactsPartialUpdateParamsWithContext(ctx context.Context) *TenancyContactsPartialUpdateParams { + return &TenancyContactsPartialUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactsPartialUpdateParamsWithHTTPClient creates a new TenancyContactsPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactsPartialUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactsPartialUpdateParams { + return &TenancyContactsPartialUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactsPartialUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contacts partial update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactsPartialUpdateParams struct { + + // Data. + Data *models.WritableContact + + /* ID. + + A unique integer value identifying this contact. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contacts partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsPartialUpdateParams) WithDefaults() *TenancyContactsPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contacts partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contacts partial update params +func (o *TenancyContactsPartialUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactsPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contacts partial update params +func (o *TenancyContactsPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contacts partial update params +func (o *TenancyContactsPartialUpdateParams) WithContext(ctx context.Context) *TenancyContactsPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contacts partial update params +func (o *TenancyContactsPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contacts partial update params +func (o *TenancyContactsPartialUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactsPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contacts partial update params +func (o *TenancyContactsPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contacts partial update params +func (o *TenancyContactsPartialUpdateParams) WithData(data *models.WritableContact) *TenancyContactsPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contacts partial update params +func (o *TenancyContactsPartialUpdateParams) SetData(data *models.WritableContact) { + o.Data = data +} + +// WithID adds the id to the tenancy contacts partial update params +func (o *TenancyContactsPartialUpdateParams) WithID(id int64) *TenancyContactsPartialUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contacts partial update params +func (o *TenancyContactsPartialUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactsPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_partial_update_responses.go b/netbox/client/tenancy/tenancy_contacts_partial_update_responses.go new file mode 100644 index 00000000..59662a83 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactsPartialUpdateReader is a Reader for the TenancyContactsPartialUpdate structure. +type TenancyContactsPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactsPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactsPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactsPartialUpdateOK creates a TenancyContactsPartialUpdateOK with default headers values +func NewTenancyContactsPartialUpdateOK() *TenancyContactsPartialUpdateOK { + return &TenancyContactsPartialUpdateOK{} +} + +/* TenancyContactsPartialUpdateOK describes a response with status code 200, with default header values. + +TenancyContactsPartialUpdateOK tenancy contacts partial update o k +*/ +type TenancyContactsPartialUpdateOK struct { + Payload *models.Contact +} + +func (o *TenancyContactsPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /tenancy/contacts/{id}/][%d] tenancyContactsPartialUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactsPartialUpdateOK) GetPayload() *models.Contact { + return o.Payload +} + +func (o *TenancyContactsPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.Contact) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_read_parameters.go b/netbox/client/tenancy/tenancy_contacts_read_parameters.go new file mode 100644 index 00000000..3ae1e71b --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_read_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewTenancyContactsReadParams creates a new TenancyContactsReadParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactsReadParams() *TenancyContactsReadParams { + return &TenancyContactsReadParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactsReadParamsWithTimeout creates a new TenancyContactsReadParams object +// with the ability to set a timeout on a request. +func NewTenancyContactsReadParamsWithTimeout(timeout time.Duration) *TenancyContactsReadParams { + return &TenancyContactsReadParams{ + timeout: timeout, + } +} + +// NewTenancyContactsReadParamsWithContext creates a new TenancyContactsReadParams object +// with the ability to set a context for a request. +func NewTenancyContactsReadParamsWithContext(ctx context.Context) *TenancyContactsReadParams { + return &TenancyContactsReadParams{ + Context: ctx, + } +} + +// NewTenancyContactsReadParamsWithHTTPClient creates a new TenancyContactsReadParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactsReadParamsWithHTTPClient(client *http.Client) *TenancyContactsReadParams { + return &TenancyContactsReadParams{ + HTTPClient: client, + } +} + +/* TenancyContactsReadParams contains all the parameters to send to the API endpoint + for the tenancy contacts read operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactsReadParams struct { + + /* ID. + + A unique integer value identifying this contact. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contacts read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsReadParams) WithDefaults() *TenancyContactsReadParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contacts read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsReadParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contacts read params +func (o *TenancyContactsReadParams) WithTimeout(timeout time.Duration) *TenancyContactsReadParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contacts read params +func (o *TenancyContactsReadParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contacts read params +func (o *TenancyContactsReadParams) WithContext(ctx context.Context) *TenancyContactsReadParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contacts read params +func (o *TenancyContactsReadParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contacts read params +func (o *TenancyContactsReadParams) WithHTTPClient(client *http.Client) *TenancyContactsReadParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contacts read params +func (o *TenancyContactsReadParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the tenancy contacts read params +func (o *TenancyContactsReadParams) WithID(id int64) *TenancyContactsReadParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contacts read params +func (o *TenancyContactsReadParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactsReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_read_responses.go b/netbox/client/tenancy/tenancy_contacts_read_responses.go new file mode 100644 index 00000000..07ab7f61 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_read_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactsReadReader is a Reader for the TenancyContactsRead structure. +type TenancyContactsReadReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactsReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactsReadOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactsReadOK creates a TenancyContactsReadOK with default headers values +func NewTenancyContactsReadOK() *TenancyContactsReadOK { + return &TenancyContactsReadOK{} +} + +/* TenancyContactsReadOK describes a response with status code 200, with default header values. + +TenancyContactsReadOK tenancy contacts read o k +*/ +type TenancyContactsReadOK struct { + Payload *models.Contact +} + +func (o *TenancyContactsReadOK) Error() string { + return fmt.Sprintf("[GET /tenancy/contacts/{id}/][%d] tenancyContactsReadOK %+v", 200, o.Payload) +} +func (o *TenancyContactsReadOK) GetPayload() *models.Contact { + return o.Payload +} + +func (o *TenancyContactsReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.Contact) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_update_parameters.go b/netbox/client/tenancy/tenancy_contacts_update_parameters.go new file mode 100644 index 00000000..a51e96f7 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewTenancyContactsUpdateParams creates a new TenancyContactsUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewTenancyContactsUpdateParams() *TenancyContactsUpdateParams { + return &TenancyContactsUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewTenancyContactsUpdateParamsWithTimeout creates a new TenancyContactsUpdateParams object +// with the ability to set a timeout on a request. +func NewTenancyContactsUpdateParamsWithTimeout(timeout time.Duration) *TenancyContactsUpdateParams { + return &TenancyContactsUpdateParams{ + timeout: timeout, + } +} + +// NewTenancyContactsUpdateParamsWithContext creates a new TenancyContactsUpdateParams object +// with the ability to set a context for a request. +func NewTenancyContactsUpdateParamsWithContext(ctx context.Context) *TenancyContactsUpdateParams { + return &TenancyContactsUpdateParams{ + Context: ctx, + } +} + +// NewTenancyContactsUpdateParamsWithHTTPClient creates a new TenancyContactsUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewTenancyContactsUpdateParamsWithHTTPClient(client *http.Client) *TenancyContactsUpdateParams { + return &TenancyContactsUpdateParams{ + HTTPClient: client, + } +} + +/* TenancyContactsUpdateParams contains all the parameters to send to the API endpoint + for the tenancy contacts update operation. + + Typically these are written to a http.Request. +*/ +type TenancyContactsUpdateParams struct { + + // Data. + Data *models.WritableContact + + /* ID. + + A unique integer value identifying this contact. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the tenancy contacts update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsUpdateParams) WithDefaults() *TenancyContactsUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the tenancy contacts update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *TenancyContactsUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the tenancy contacts update params +func (o *TenancyContactsUpdateParams) WithTimeout(timeout time.Duration) *TenancyContactsUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the tenancy contacts update params +func (o *TenancyContactsUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the tenancy contacts update params +func (o *TenancyContactsUpdateParams) WithContext(ctx context.Context) *TenancyContactsUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the tenancy contacts update params +func (o *TenancyContactsUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the tenancy contacts update params +func (o *TenancyContactsUpdateParams) WithHTTPClient(client *http.Client) *TenancyContactsUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the tenancy contacts update params +func (o *TenancyContactsUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the tenancy contacts update params +func (o *TenancyContactsUpdateParams) WithData(data *models.WritableContact) *TenancyContactsUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the tenancy contacts update params +func (o *TenancyContactsUpdateParams) SetData(data *models.WritableContact) { + o.Data = data +} + +// WithID adds the id to the tenancy contacts update params +func (o *TenancyContactsUpdateParams) WithID(id int64) *TenancyContactsUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the tenancy contacts update params +func (o *TenancyContactsUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *TenancyContactsUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/tenancy/tenancy_contacts_update_responses.go b/netbox/client/tenancy/tenancy_contacts_update_responses.go new file mode 100644 index 00000000..bfc580d2 --- /dev/null +++ b/netbox/client/tenancy/tenancy_contacts_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package tenancy + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// TenancyContactsUpdateReader is a Reader for the TenancyContactsUpdate structure. +type TenancyContactsUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *TenancyContactsUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewTenancyContactsUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewTenancyContactsUpdateOK creates a TenancyContactsUpdateOK with default headers values +func NewTenancyContactsUpdateOK() *TenancyContactsUpdateOK { + return &TenancyContactsUpdateOK{} +} + +/* TenancyContactsUpdateOK describes a response with status code 200, with default header values. + +TenancyContactsUpdateOK tenancy contacts update o k +*/ +type TenancyContactsUpdateOK struct { + Payload *models.Contact +} + +func (o *TenancyContactsUpdateOK) Error() string { + return fmt.Sprintf("[PUT /tenancy/contacts/{id}/][%d] tenancyContactsUpdateOK %+v", 200, o.Payload) +} +func (o *TenancyContactsUpdateOK) GetPayload() *models.Contact { + return o.Payload +} + +func (o *TenancyContactsUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.Contact) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/tenancy/tenancy_tenant_groups_list_parameters.go b/netbox/client/tenancy/tenancy_tenant_groups_list_parameters.go index 851e34f2..b9265e3a 100644 --- a/netbox/client/tenancy/tenancy_tenant_groups_list_parameters.go +++ b/netbox/client/tenancy/tenancy_tenant_groups_list_parameters.go @@ -237,6 +237,12 @@ type TenancyTenantGroupsListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -862,6 +868,28 @@ func (o *TenancyTenantGroupsListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the tenancy tenant groups list params +func (o *TenancyTenantGroupsListParams) WithTag(tag *string) *TenancyTenantGroupsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the tenancy tenant groups list params +func (o *TenancyTenantGroupsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the tenancy tenant groups list params +func (o *TenancyTenantGroupsListParams) WithTagn(tagn *string) *TenancyTenantGroupsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the tenancy tenant groups list params +func (o *TenancyTenantGroupsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *TenancyTenantGroupsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -1754,6 +1782,40 @@ func (o *TenancyTenantGroupsListParams) WriteToRequest(r runtime.ClientRequest, } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/tenancy/tenancy_tenants_list_parameters.go b/netbox/client/tenancy/tenancy_tenants_list_parameters.go index 448d76b5..58dd8a9d 100644 --- a/netbox/client/tenancy/tenancy_tenants_list_parameters.go +++ b/netbox/client/tenancy/tenancy_tenants_list_parameters.go @@ -75,6 +75,18 @@ func NewTenancyTenantsListParamsWithHTTPClient(client *http.Client) *TenancyTena */ type TenancyTenantsListParams struct { + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -84,6 +96,39 @@ type TenancyTenantsListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // Group. Group *string @@ -263,6 +308,50 @@ func (o *TenancyTenantsListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithContact adds the contact to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithContact(contact *string) *TenancyTenantsListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithContactn(contactn *string) *TenancyTenantsListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithContactRole(contactRole *string) *TenancyTenantsListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithContactRolen(contactRolen *string) *TenancyTenantsListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the tenancy tenants list params func (o *TenancyTenantsListParams) WithCreated(created *string) *TenancyTenantsListParams { o.SetCreated(created) @@ -296,6 +385,127 @@ func (o *TenancyTenantsListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithDescription(description *string) *TenancyTenantsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithDescriptionEmpty(descriptionEmpty *string) *TenancyTenantsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithDescriptionIc(descriptionIc *string) *TenancyTenantsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithDescriptionIe(descriptionIe *string) *TenancyTenantsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithDescriptionIew(descriptionIew *string) *TenancyTenantsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithDescriptionIsw(descriptionIsw *string) *TenancyTenantsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithDescriptionn(descriptionn *string) *TenancyTenantsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithDescriptionNic(descriptionNic *string) *TenancyTenantsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithDescriptionNie(descriptionNie *string) *TenancyTenantsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithDescriptionNiew(descriptionNiew *string) *TenancyTenantsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the tenancy tenants list params +func (o *TenancyTenantsListParams) WithDescriptionNisw(descriptionNisw *string) *TenancyTenantsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the tenancy tenants list params +func (o *TenancyTenantsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithGroup adds the group to the tenancy tenants list params func (o *TenancyTenantsListParams) WithGroup(group *string) *TenancyTenantsListParams { o.SetGroup(group) @@ -744,6 +954,74 @@ func (o *TenancyTenantsListParams) WriteToRequest(r runtime.ClientRequest, reg s } var res []error + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created @@ -795,6 +1073,193 @@ func (o *TenancyTenantsListParams) WriteToRequest(r runtime.ClientRequest, reg s } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.Group != nil { // query param group diff --git a/netbox/client/users/users_permissions_list_parameters.go b/netbox/client/users/users_permissions_list_parameters.go index 592f5d3f..8054603d 100644 --- a/netbox/client/users/users_permissions_list_parameters.go +++ b/netbox/client/users/users_permissions_list_parameters.go @@ -75,6 +75,39 @@ func NewUsersPermissionsListParamsWithHTTPClient(client *http.Client) *UsersPerm */ type UsersPermissionsListParams struct { + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // Enabled. Enabled *string @@ -227,6 +260,127 @@ func (o *UsersPermissionsListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithDescription adds the description to the users permissions list params +func (o *UsersPermissionsListParams) WithDescription(description *string) *UsersPermissionsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the users permissions list params +func (o *UsersPermissionsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the users permissions list params +func (o *UsersPermissionsListParams) WithDescriptionEmpty(descriptionEmpty *string) *UsersPermissionsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the users permissions list params +func (o *UsersPermissionsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the users permissions list params +func (o *UsersPermissionsListParams) WithDescriptionIc(descriptionIc *string) *UsersPermissionsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the users permissions list params +func (o *UsersPermissionsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the users permissions list params +func (o *UsersPermissionsListParams) WithDescriptionIe(descriptionIe *string) *UsersPermissionsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the users permissions list params +func (o *UsersPermissionsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the users permissions list params +func (o *UsersPermissionsListParams) WithDescriptionIew(descriptionIew *string) *UsersPermissionsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the users permissions list params +func (o *UsersPermissionsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the users permissions list params +func (o *UsersPermissionsListParams) WithDescriptionIsw(descriptionIsw *string) *UsersPermissionsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the users permissions list params +func (o *UsersPermissionsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the users permissions list params +func (o *UsersPermissionsListParams) WithDescriptionn(descriptionn *string) *UsersPermissionsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the users permissions list params +func (o *UsersPermissionsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the users permissions list params +func (o *UsersPermissionsListParams) WithDescriptionNic(descriptionNic *string) *UsersPermissionsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the users permissions list params +func (o *UsersPermissionsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the users permissions list params +func (o *UsersPermissionsListParams) WithDescriptionNie(descriptionNie *string) *UsersPermissionsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the users permissions list params +func (o *UsersPermissionsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the users permissions list params +func (o *UsersPermissionsListParams) WithDescriptionNiew(descriptionNiew *string) *UsersPermissionsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the users permissions list params +func (o *UsersPermissionsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the users permissions list params +func (o *UsersPermissionsListParams) WithDescriptionNisw(descriptionNisw *string) *UsersPermissionsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the users permissions list params +func (o *UsersPermissionsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithEnabled adds the enabled to the users permissions list params func (o *UsersPermissionsListParams) WithEnabled(enabled *string) *UsersPermissionsListParams { o.SetEnabled(enabled) @@ -576,6 +730,193 @@ func (o *UsersPermissionsListParams) WriteToRequest(r runtime.ClientRequest, reg } var res []error + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.Enabled != nil { // query param enabled diff --git a/netbox/client/users/users_tokens_list_parameters.go b/netbox/client/users/users_tokens_list_parameters.go index 5ab2d84d..641f6022 100644 --- a/netbox/client/users/users_tokens_list_parameters.go +++ b/netbox/client/users/users_tokens_list_parameters.go @@ -84,6 +84,39 @@ type UsersTokensListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // Expires. Expires *string @@ -260,6 +293,127 @@ func (o *UsersTokensListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the users tokens list params +func (o *UsersTokensListParams) WithDescription(description *string) *UsersTokensListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the users tokens list params +func (o *UsersTokensListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the users tokens list params +func (o *UsersTokensListParams) WithDescriptionEmpty(descriptionEmpty *string) *UsersTokensListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the users tokens list params +func (o *UsersTokensListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the users tokens list params +func (o *UsersTokensListParams) WithDescriptionIc(descriptionIc *string) *UsersTokensListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the users tokens list params +func (o *UsersTokensListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the users tokens list params +func (o *UsersTokensListParams) WithDescriptionIe(descriptionIe *string) *UsersTokensListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the users tokens list params +func (o *UsersTokensListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the users tokens list params +func (o *UsersTokensListParams) WithDescriptionIew(descriptionIew *string) *UsersTokensListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the users tokens list params +func (o *UsersTokensListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the users tokens list params +func (o *UsersTokensListParams) WithDescriptionIsw(descriptionIsw *string) *UsersTokensListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the users tokens list params +func (o *UsersTokensListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the users tokens list params +func (o *UsersTokensListParams) WithDescriptionn(descriptionn *string) *UsersTokensListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the users tokens list params +func (o *UsersTokensListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the users tokens list params +func (o *UsersTokensListParams) WithDescriptionNic(descriptionNic *string) *UsersTokensListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the users tokens list params +func (o *UsersTokensListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the users tokens list params +func (o *UsersTokensListParams) WithDescriptionNie(descriptionNie *string) *UsersTokensListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the users tokens list params +func (o *UsersTokensListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the users tokens list params +func (o *UsersTokensListParams) WithDescriptionNiew(descriptionNiew *string) *UsersTokensListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the users tokens list params +func (o *UsersTokensListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the users tokens list params +func (o *UsersTokensListParams) WithDescriptionNisw(descriptionNisw *string) *UsersTokensListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the users tokens list params +func (o *UsersTokensListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithExpires adds the expires to the users tokens list params func (o *UsersTokensListParams) WithExpires(expires *string) *UsersTokensListParams { o.SetExpires(expires) @@ -627,6 +781,193 @@ func (o *UsersTokensListParams) WriteToRequest(r runtime.ClientRequest, reg strf } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.Expires != nil { // query param expires diff --git a/netbox/client/virtualization/virtualization_cluster_groups_list_parameters.go b/netbox/client/virtualization/virtualization_cluster_groups_list_parameters.go index 07e176b2..6edc7d00 100644 --- a/netbox/client/virtualization/virtualization_cluster_groups_list_parameters.go +++ b/netbox/client/virtualization/virtualization_cluster_groups_list_parameters.go @@ -75,6 +75,18 @@ func NewVirtualizationClusterGroupsListParamsWithHTTPClient(client *http.Client) */ type VirtualizationClusterGroupsListParams struct { + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -225,6 +237,12 @@ type VirtualizationClusterGroupsListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -278,6 +296,50 @@ func (o *VirtualizationClusterGroupsListParams) SetHTTPClient(client *http.Clien o.HTTPClient = client } +// WithContact adds the contact to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) WithContact(contact *string) *VirtualizationClusterGroupsListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) WithContactn(contactn *string) *VirtualizationClusterGroupsListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) WithContactRole(contactRole *string) *VirtualizationClusterGroupsListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) WithContactRolen(contactRolen *string) *VirtualizationClusterGroupsListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the virtualization cluster groups list params func (o *VirtualizationClusterGroupsListParams) WithCreated(created *string) *VirtualizationClusterGroupsListParams { o.SetCreated(created) @@ -806,6 +868,28 @@ func (o *VirtualizationClusterGroupsListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) WithTag(tag *string) *VirtualizationClusterGroupsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) WithTagn(tagn *string) *VirtualizationClusterGroupsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the virtualization cluster groups list params +func (o *VirtualizationClusterGroupsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *VirtualizationClusterGroupsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -814,6 +898,74 @@ func (o *VirtualizationClusterGroupsListParams) WriteToRequest(r runtime.ClientR } var res []error + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created @@ -1630,6 +1782,40 @@ func (o *VirtualizationClusterGroupsListParams) WriteToRequest(r runtime.ClientR } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/virtualization/virtualization_cluster_types_list_parameters.go b/netbox/client/virtualization/virtualization_cluster_types_list_parameters.go index 9a05e58e..37d1c245 100644 --- a/netbox/client/virtualization/virtualization_cluster_types_list_parameters.go +++ b/netbox/client/virtualization/virtualization_cluster_types_list_parameters.go @@ -225,6 +225,12 @@ type VirtualizationClusterTypesListParams struct { // SlugNisw. SlugNisw *string + // Tag. + Tag *string + + // Tagn. + Tagn *string + timeout time.Duration Context context.Context HTTPClient *http.Client @@ -806,6 +812,28 @@ func (o *VirtualizationClusterTypesListParams) SetSlugNisw(slugNisw *string) { o.SlugNisw = slugNisw } +// WithTag adds the tag to the virtualization cluster types list params +func (o *VirtualizationClusterTypesListParams) WithTag(tag *string) *VirtualizationClusterTypesListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the virtualization cluster types list params +func (o *VirtualizationClusterTypesListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the virtualization cluster types list params +func (o *VirtualizationClusterTypesListParams) WithTagn(tagn *string) *VirtualizationClusterTypesListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the virtualization cluster types list params +func (o *VirtualizationClusterTypesListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + // WriteToRequest writes these params to a swagger request func (o *VirtualizationClusterTypesListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { @@ -1630,6 +1658,40 @@ func (o *VirtualizationClusterTypesListParams) WriteToRequest(r runtime.ClientRe } } + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } diff --git a/netbox/client/virtualization/virtualization_clusters_list_parameters.go b/netbox/client/virtualization/virtualization_clusters_list_parameters.go index a6f6ba1d..213a3b22 100644 --- a/netbox/client/virtualization/virtualization_clusters_list_parameters.go +++ b/netbox/client/virtualization/virtualization_clusters_list_parameters.go @@ -75,6 +75,18 @@ func NewVirtualizationClustersListParamsWithHTTPClient(client *http.Client) *Vir */ type VirtualizationClustersListParams struct { + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -302,6 +314,50 @@ func (o *VirtualizationClustersListParams) SetHTTPClient(client *http.Client) { o.HTTPClient = client } +// WithContact adds the contact to the virtualization clusters list params +func (o *VirtualizationClustersListParams) WithContact(contact *string) *VirtualizationClustersListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the virtualization clusters list params +func (o *VirtualizationClustersListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the virtualization clusters list params +func (o *VirtualizationClustersListParams) WithContactn(contactn *string) *VirtualizationClustersListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the virtualization clusters list params +func (o *VirtualizationClustersListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the virtualization clusters list params +func (o *VirtualizationClustersListParams) WithContactRole(contactRole *string) *VirtualizationClustersListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the virtualization clusters list params +func (o *VirtualizationClustersListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the virtualization clusters list params +func (o *VirtualizationClustersListParams) WithContactRolen(contactRolen *string) *VirtualizationClustersListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the virtualization clusters list params +func (o *VirtualizationClustersListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the virtualization clusters list params func (o *VirtualizationClustersListParams) WithCreated(created *string) *VirtualizationClustersListParams { o.SetCreated(created) @@ -926,6 +982,74 @@ func (o *VirtualizationClustersListParams) WriteToRequest(r runtime.ClientReques } var res []error + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created diff --git a/netbox/client/virtualization/virtualization_interfaces_list_parameters.go b/netbox/client/virtualization/virtualization_interfaces_list_parameters.go index 74e33439..8ece9a3b 100644 --- a/netbox/client/virtualization/virtualization_interfaces_list_parameters.go +++ b/netbox/client/virtualization/virtualization_interfaces_list_parameters.go @@ -75,6 +75,12 @@ func NewVirtualizationInterfacesListParamsWithHTTPClient(client *http.Client) *V */ type VirtualizationInterfacesListParams struct { + // BridgeID. + BridgeID *string + + // BridgeIDn. + BridgeIDn *string + // Cluster. Cluster *string @@ -96,6 +102,39 @@ type VirtualizationInterfacesListParams struct { // CreatedLte. CreatedLte *string + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + // Enabled. Enabled *string @@ -299,6 +338,28 @@ func (o *VirtualizationInterfacesListParams) SetHTTPClient(client *http.Client) o.HTTPClient = client } +// WithBridgeID adds the bridgeID to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithBridgeID(bridgeID *string) *VirtualizationInterfacesListParams { + o.SetBridgeID(bridgeID) + return o +} + +// SetBridgeID adds the bridgeId to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetBridgeID(bridgeID *string) { + o.BridgeID = bridgeID +} + +// WithBridgeIDn adds the bridgeIDn to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithBridgeIDn(bridgeIDn *string) *VirtualizationInterfacesListParams { + o.SetBridgeIDn(bridgeIDn) + return o +} + +// SetBridgeIDn adds the bridgeIdN to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetBridgeIDn(bridgeIDn *string) { + o.BridgeIDn = bridgeIDn +} + // WithCluster adds the cluster to the virtualization interfaces list params func (o *VirtualizationInterfacesListParams) WithCluster(cluster *string) *VirtualizationInterfacesListParams { o.SetCluster(cluster) @@ -376,6 +437,127 @@ func (o *VirtualizationInterfacesListParams) SetCreatedLte(createdLte *string) { o.CreatedLte = createdLte } +// WithDescription adds the description to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithDescription(description *string) *VirtualizationInterfacesListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithDescriptionEmpty(descriptionEmpty *string) *VirtualizationInterfacesListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithDescriptionIc(descriptionIc *string) *VirtualizationInterfacesListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithDescriptionIe(descriptionIe *string) *VirtualizationInterfacesListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithDescriptionIew(descriptionIew *string) *VirtualizationInterfacesListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithDescriptionIsw(descriptionIsw *string) *VirtualizationInterfacesListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithDescriptionn(descriptionn *string) *VirtualizationInterfacesListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithDescriptionNic(descriptionNic *string) *VirtualizationInterfacesListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithDescriptionNie(descriptionNie *string) *VirtualizationInterfacesListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithDescriptionNiew(descriptionNiew *string) *VirtualizationInterfacesListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) WithDescriptionNisw(descriptionNisw *string) *VirtualizationInterfacesListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the virtualization interfaces list params +func (o *VirtualizationInterfacesListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + // WithEnabled adds the enabled to the virtualization interfaces list params func (o *VirtualizationInterfacesListParams) WithEnabled(enabled *string) *VirtualizationInterfacesListParams { o.SetEnabled(enabled) @@ -912,6 +1094,40 @@ func (o *VirtualizationInterfacesListParams) WriteToRequest(r runtime.ClientRequ } var res []error + if o.BridgeID != nil { + + // query param bridge_id + var qrBridgeID string + + if o.BridgeID != nil { + qrBridgeID = *o.BridgeID + } + qBridgeID := qrBridgeID + if qBridgeID != "" { + + if err := r.SetQueryParam("bridge_id", qBridgeID); err != nil { + return err + } + } + } + + if o.BridgeIDn != nil { + + // query param bridge_id__n + var qrBridgeIDn string + + if o.BridgeIDn != nil { + qrBridgeIDn = *o.BridgeIDn + } + qBridgeIDn := qrBridgeIDn + if qBridgeIDn != "" { + + if err := r.SetQueryParam("bridge_id__n", qBridgeIDn); err != nil { + return err + } + } + } + if o.Cluster != nil { // query param cluster @@ -1031,6 +1247,193 @@ func (o *VirtualizationInterfacesListParams) WriteToRequest(r runtime.ClientRequ } } + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + if o.Enabled != nil { // query param enabled diff --git a/netbox/client/virtualization/virtualization_virtual_machines_list_parameters.go b/netbox/client/virtualization/virtualization_virtual_machines_list_parameters.go index c54f632f..4e800038 100644 --- a/netbox/client/virtualization/virtualization_virtual_machines_list_parameters.go +++ b/netbox/client/virtualization/virtualization_virtual_machines_list_parameters.go @@ -111,6 +111,18 @@ type VirtualizationVirtualMachinesListParams struct { // ClusterTypeIDn. ClusterTypeIDn *string + // Contact. + Contact *string + + // Contactn. + Contactn *string + + // ContactRole. + ContactRole *string + + // ContactRolen. + ContactRolen *string + // Created. Created *string @@ -566,6 +578,50 @@ func (o *VirtualizationVirtualMachinesListParams) SetClusterTypeIDn(clusterTypeI o.ClusterTypeIDn = clusterTypeIDn } +// WithContact adds the contact to the virtualization virtual machines list params +func (o *VirtualizationVirtualMachinesListParams) WithContact(contact *string) *VirtualizationVirtualMachinesListParams { + o.SetContact(contact) + return o +} + +// SetContact adds the contact to the virtualization virtual machines list params +func (o *VirtualizationVirtualMachinesListParams) SetContact(contact *string) { + o.Contact = contact +} + +// WithContactn adds the contactn to the virtualization virtual machines list params +func (o *VirtualizationVirtualMachinesListParams) WithContactn(contactn *string) *VirtualizationVirtualMachinesListParams { + o.SetContactn(contactn) + return o +} + +// SetContactn adds the contactN to the virtualization virtual machines list params +func (o *VirtualizationVirtualMachinesListParams) SetContactn(contactn *string) { + o.Contactn = contactn +} + +// WithContactRole adds the contactRole to the virtualization virtual machines list params +func (o *VirtualizationVirtualMachinesListParams) WithContactRole(contactRole *string) *VirtualizationVirtualMachinesListParams { + o.SetContactRole(contactRole) + return o +} + +// SetContactRole adds the contactRole to the virtualization virtual machines list params +func (o *VirtualizationVirtualMachinesListParams) SetContactRole(contactRole *string) { + o.ContactRole = contactRole +} + +// WithContactRolen adds the contactRolen to the virtualization virtual machines list params +func (o *VirtualizationVirtualMachinesListParams) WithContactRolen(contactRolen *string) *VirtualizationVirtualMachinesListParams { + o.SetContactRolen(contactRolen) + return o +} + +// SetContactRolen adds the contactRoleN to the virtualization virtual machines list params +func (o *VirtualizationVirtualMachinesListParams) SetContactRolen(contactRolen *string) { + o.ContactRolen = contactRolen +} + // WithCreated adds the created to the virtualization virtual machines list params func (o *VirtualizationVirtualMachinesListParams) WithCreated(created *string) *VirtualizationVirtualMachinesListParams { o.SetCreated(created) @@ -1746,6 +1802,74 @@ func (o *VirtualizationVirtualMachinesListParams) WriteToRequest(r runtime.Clien } } + if o.Contact != nil { + + // query param contact + var qrContact string + + if o.Contact != nil { + qrContact = *o.Contact + } + qContact := qrContact + if qContact != "" { + + if err := r.SetQueryParam("contact", qContact); err != nil { + return err + } + } + } + + if o.Contactn != nil { + + // query param contact__n + var qrContactn string + + if o.Contactn != nil { + qrContactn = *o.Contactn + } + qContactn := qrContactn + if qContactn != "" { + + if err := r.SetQueryParam("contact__n", qContactn); err != nil { + return err + } + } + } + + if o.ContactRole != nil { + + // query param contact_role + var qrContactRole string + + if o.ContactRole != nil { + qrContactRole = *o.ContactRole + } + qContactRole := qrContactRole + if qContactRole != "" { + + if err := r.SetQueryParam("contact_role", qContactRole); err != nil { + return err + } + } + } + + if o.ContactRolen != nil { + + // query param contact_role__n + var qrContactRolen string + + if o.ContactRolen != nil { + qrContactRolen = *o.ContactRolen + } + qContactRolen := qrContactRolen + if qContactRolen != "" { + + if err := r.SetQueryParam("contact_role__n", qContactRolen); err != nil { + return err + } + } + } + if o.Created != nil { // query param created diff --git a/netbox/client/wireless/wireless_client.go b/netbox/client/wireless/wireless_client.go new file mode 100644 index 00000000..7c7352f5 --- /dev/null +++ b/netbox/client/wireless/wireless_client.go @@ -0,0 +1,1161 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// New creates a new wireless API client. +func New(transport runtime.ClientTransport, formats strfmt.Registry) ClientService { + return &Client{transport: transport, formats: formats} +} + +/* +Client for wireless API +*/ +type Client struct { + transport runtime.ClientTransport + formats strfmt.Registry +} + +// ClientOption is the option for Client methods +type ClientOption func(*runtime.ClientOperation) + +// ClientService is the interface for Client methods +type ClientService interface { + WirelessWirelessLanGroupsBulkDelete(params *WirelessWirelessLanGroupsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsBulkDeleteNoContent, error) + + WirelessWirelessLanGroupsBulkPartialUpdate(params *WirelessWirelessLanGroupsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsBulkPartialUpdateOK, error) + + WirelessWirelessLanGroupsBulkUpdate(params *WirelessWirelessLanGroupsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsBulkUpdateOK, error) + + WirelessWirelessLanGroupsCreate(params *WirelessWirelessLanGroupsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsCreateCreated, error) + + WirelessWirelessLanGroupsDelete(params *WirelessWirelessLanGroupsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsDeleteNoContent, error) + + WirelessWirelessLanGroupsList(params *WirelessWirelessLanGroupsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsListOK, error) + + WirelessWirelessLanGroupsPartialUpdate(params *WirelessWirelessLanGroupsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsPartialUpdateOK, error) + + WirelessWirelessLanGroupsRead(params *WirelessWirelessLanGroupsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsReadOK, error) + + WirelessWirelessLanGroupsUpdate(params *WirelessWirelessLanGroupsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsUpdateOK, error) + + WirelessWirelessLansBulkDelete(params *WirelessWirelessLansBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansBulkDeleteNoContent, error) + + WirelessWirelessLansBulkPartialUpdate(params *WirelessWirelessLansBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansBulkPartialUpdateOK, error) + + WirelessWirelessLansBulkUpdate(params *WirelessWirelessLansBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansBulkUpdateOK, error) + + WirelessWirelessLansCreate(params *WirelessWirelessLansCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansCreateCreated, error) + + WirelessWirelessLansDelete(params *WirelessWirelessLansDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansDeleteNoContent, error) + + WirelessWirelessLansList(params *WirelessWirelessLansListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansListOK, error) + + WirelessWirelessLansPartialUpdate(params *WirelessWirelessLansPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansPartialUpdateOK, error) + + WirelessWirelessLansRead(params *WirelessWirelessLansReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansReadOK, error) + + WirelessWirelessLansUpdate(params *WirelessWirelessLansUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansUpdateOK, error) + + WirelessWirelessLinksBulkDelete(params *WirelessWirelessLinksBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksBulkDeleteNoContent, error) + + WirelessWirelessLinksBulkPartialUpdate(params *WirelessWirelessLinksBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksBulkPartialUpdateOK, error) + + WirelessWirelessLinksBulkUpdate(params *WirelessWirelessLinksBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksBulkUpdateOK, error) + + WirelessWirelessLinksCreate(params *WirelessWirelessLinksCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksCreateCreated, error) + + WirelessWirelessLinksDelete(params *WirelessWirelessLinksDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksDeleteNoContent, error) + + WirelessWirelessLinksList(params *WirelessWirelessLinksListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksListOK, error) + + WirelessWirelessLinksPartialUpdate(params *WirelessWirelessLinksPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksPartialUpdateOK, error) + + WirelessWirelessLinksRead(params *WirelessWirelessLinksReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksReadOK, error) + + WirelessWirelessLinksUpdate(params *WirelessWirelessLinksUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksUpdateOK, error) + + SetTransport(transport runtime.ClientTransport) +} + +/* + WirelessWirelessLanGroupsBulkDelete wireless wireless lan groups bulk delete API +*/ +func (a *Client) WirelessWirelessLanGroupsBulkDelete(params *WirelessWirelessLanGroupsBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsBulkDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLanGroupsBulkDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lan-groups_bulk_delete", + Method: "DELETE", + PathPattern: "/wireless/wireless-lan-groups/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLanGroupsBulkDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLanGroupsBulkDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lan-groups_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLanGroupsBulkPartialUpdate wireless wireless lan groups bulk partial update API +*/ +func (a *Client) WirelessWirelessLanGroupsBulkPartialUpdate(params *WirelessWirelessLanGroupsBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsBulkPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLanGroupsBulkPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lan-groups_bulk_partial_update", + Method: "PATCH", + PathPattern: "/wireless/wireless-lan-groups/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLanGroupsBulkPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLanGroupsBulkPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lan-groups_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLanGroupsBulkUpdate wireless wireless lan groups bulk update API +*/ +func (a *Client) WirelessWirelessLanGroupsBulkUpdate(params *WirelessWirelessLanGroupsBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsBulkUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLanGroupsBulkUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lan-groups_bulk_update", + Method: "PUT", + PathPattern: "/wireless/wireless-lan-groups/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLanGroupsBulkUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLanGroupsBulkUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lan-groups_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLanGroupsCreate wireless wireless lan groups create API +*/ +func (a *Client) WirelessWirelessLanGroupsCreate(params *WirelessWirelessLanGroupsCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLanGroupsCreateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lan-groups_create", + Method: "POST", + PathPattern: "/wireless/wireless-lan-groups/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLanGroupsCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLanGroupsCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lan-groups_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLanGroupsDelete wireless wireless lan groups delete API +*/ +func (a *Client) WirelessWirelessLanGroupsDelete(params *WirelessWirelessLanGroupsDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLanGroupsDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lan-groups_delete", + Method: "DELETE", + PathPattern: "/wireless/wireless-lan-groups/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLanGroupsDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLanGroupsDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lan-groups_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLanGroupsList Overrides ListModelMixin to allow processing ExportTemplates. +*/ +func (a *Client) WirelessWirelessLanGroupsList(params *WirelessWirelessLanGroupsListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsListOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLanGroupsListParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lan-groups_list", + Method: "GET", + PathPattern: "/wireless/wireless-lan-groups/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLanGroupsListReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLanGroupsListOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lan-groups_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLanGroupsPartialUpdate wireless wireless lan groups partial update API +*/ +func (a *Client) WirelessWirelessLanGroupsPartialUpdate(params *WirelessWirelessLanGroupsPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLanGroupsPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lan-groups_partial_update", + Method: "PATCH", + PathPattern: "/wireless/wireless-lan-groups/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLanGroupsPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLanGroupsPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lan-groups_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLanGroupsRead wireless wireless lan groups read API +*/ +func (a *Client) WirelessWirelessLanGroupsRead(params *WirelessWirelessLanGroupsReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsReadOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLanGroupsReadParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lan-groups_read", + Method: "GET", + PathPattern: "/wireless/wireless-lan-groups/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLanGroupsReadReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLanGroupsReadOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lan-groups_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLanGroupsUpdate wireless wireless lan groups update API +*/ +func (a *Client) WirelessWirelessLanGroupsUpdate(params *WirelessWirelessLanGroupsUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLanGroupsUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLanGroupsUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lan-groups_update", + Method: "PUT", + PathPattern: "/wireless/wireless-lan-groups/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLanGroupsUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLanGroupsUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lan-groups_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLansBulkDelete wireless wireless lans bulk delete API +*/ +func (a *Client) WirelessWirelessLansBulkDelete(params *WirelessWirelessLansBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansBulkDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLansBulkDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lans_bulk_delete", + Method: "DELETE", + PathPattern: "/wireless/wireless-lans/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLansBulkDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLansBulkDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lans_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLansBulkPartialUpdate wireless wireless lans bulk partial update API +*/ +func (a *Client) WirelessWirelessLansBulkPartialUpdate(params *WirelessWirelessLansBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansBulkPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLansBulkPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lans_bulk_partial_update", + Method: "PATCH", + PathPattern: "/wireless/wireless-lans/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLansBulkPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLansBulkPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lans_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLansBulkUpdate wireless wireless lans bulk update API +*/ +func (a *Client) WirelessWirelessLansBulkUpdate(params *WirelessWirelessLansBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansBulkUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLansBulkUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lans_bulk_update", + Method: "PUT", + PathPattern: "/wireless/wireless-lans/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLansBulkUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLansBulkUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lans_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLansCreate wireless wireless lans create API +*/ +func (a *Client) WirelessWirelessLansCreate(params *WirelessWirelessLansCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLansCreateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lans_create", + Method: "POST", + PathPattern: "/wireless/wireless-lans/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLansCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLansCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lans_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLansDelete wireless wireless lans delete API +*/ +func (a *Client) WirelessWirelessLansDelete(params *WirelessWirelessLansDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLansDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lans_delete", + Method: "DELETE", + PathPattern: "/wireless/wireless-lans/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLansDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLansDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lans_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLansList Overrides ListModelMixin to allow processing ExportTemplates. +*/ +func (a *Client) WirelessWirelessLansList(params *WirelessWirelessLansListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansListOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLansListParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lans_list", + Method: "GET", + PathPattern: "/wireless/wireless-lans/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLansListReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLansListOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lans_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLansPartialUpdate wireless wireless lans partial update API +*/ +func (a *Client) WirelessWirelessLansPartialUpdate(params *WirelessWirelessLansPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLansPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lans_partial_update", + Method: "PATCH", + PathPattern: "/wireless/wireless-lans/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLansPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLansPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lans_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLansRead wireless wireless lans read API +*/ +func (a *Client) WirelessWirelessLansRead(params *WirelessWirelessLansReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansReadOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLansReadParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lans_read", + Method: "GET", + PathPattern: "/wireless/wireless-lans/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLansReadReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLansReadOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lans_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLansUpdate wireless wireless lans update API +*/ +func (a *Client) WirelessWirelessLansUpdate(params *WirelessWirelessLansUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLansUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLansUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-lans_update", + Method: "PUT", + PathPattern: "/wireless/wireless-lans/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLansUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLansUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-lans_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLinksBulkDelete wireless wireless links bulk delete API +*/ +func (a *Client) WirelessWirelessLinksBulkDelete(params *WirelessWirelessLinksBulkDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksBulkDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLinksBulkDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-links_bulk_delete", + Method: "DELETE", + PathPattern: "/wireless/wireless-links/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLinksBulkDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLinksBulkDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-links_bulk_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLinksBulkPartialUpdate wireless wireless links bulk partial update API +*/ +func (a *Client) WirelessWirelessLinksBulkPartialUpdate(params *WirelessWirelessLinksBulkPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksBulkPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLinksBulkPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-links_bulk_partial_update", + Method: "PATCH", + PathPattern: "/wireless/wireless-links/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLinksBulkPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLinksBulkPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-links_bulk_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLinksBulkUpdate wireless wireless links bulk update API +*/ +func (a *Client) WirelessWirelessLinksBulkUpdate(params *WirelessWirelessLinksBulkUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksBulkUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLinksBulkUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-links_bulk_update", + Method: "PUT", + PathPattern: "/wireless/wireless-links/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLinksBulkUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLinksBulkUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-links_bulk_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLinksCreate wireless wireless links create API +*/ +func (a *Client) WirelessWirelessLinksCreate(params *WirelessWirelessLinksCreateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksCreateCreated, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLinksCreateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-links_create", + Method: "POST", + PathPattern: "/wireless/wireless-links/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLinksCreateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLinksCreateCreated) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-links_create: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLinksDelete wireless wireless links delete API +*/ +func (a *Client) WirelessWirelessLinksDelete(params *WirelessWirelessLinksDeleteParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksDeleteNoContent, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLinksDeleteParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-links_delete", + Method: "DELETE", + PathPattern: "/wireless/wireless-links/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLinksDeleteReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLinksDeleteNoContent) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-links_delete: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLinksList Overrides ListModelMixin to allow processing ExportTemplates. +*/ +func (a *Client) WirelessWirelessLinksList(params *WirelessWirelessLinksListParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksListOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLinksListParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-links_list", + Method: "GET", + PathPattern: "/wireless/wireless-links/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLinksListReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLinksListOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-links_list: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLinksPartialUpdate wireless wireless links partial update API +*/ +func (a *Client) WirelessWirelessLinksPartialUpdate(params *WirelessWirelessLinksPartialUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksPartialUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLinksPartialUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-links_partial_update", + Method: "PATCH", + PathPattern: "/wireless/wireless-links/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLinksPartialUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLinksPartialUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-links_partial_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLinksRead wireless wireless links read API +*/ +func (a *Client) WirelessWirelessLinksRead(params *WirelessWirelessLinksReadParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksReadOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLinksReadParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-links_read", + Method: "GET", + PathPattern: "/wireless/wireless-links/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLinksReadReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLinksReadOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-links_read: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +/* + WirelessWirelessLinksUpdate wireless wireless links update API +*/ +func (a *Client) WirelessWirelessLinksUpdate(params *WirelessWirelessLinksUpdateParams, authInfo runtime.ClientAuthInfoWriter, opts ...ClientOption) (*WirelessWirelessLinksUpdateOK, error) { + // TODO: Validate the params before sending + if params == nil { + params = NewWirelessWirelessLinksUpdateParams() + } + op := &runtime.ClientOperation{ + ID: "wireless_wireless-links_update", + Method: "PUT", + PathPattern: "/wireless/wireless-links/{id}/", + ProducesMediaTypes: []string{"application/json"}, + ConsumesMediaTypes: []string{"application/json"}, + Schemes: []string{"http"}, + Params: params, + Reader: &WirelessWirelessLinksUpdateReader{formats: a.formats}, + AuthInfo: authInfo, + Context: params.Context, + Client: params.HTTPClient, + } + for _, opt := range opts { + opt(op) + } + + result, err := a.transport.Submit(op) + if err != nil { + return nil, err + } + success, ok := result.(*WirelessWirelessLinksUpdateOK) + if ok { + return success, nil + } + // unexpected success response + // safeguard: normally, absent a default response, unknown success responses return an error above: so this is a codegen issue + msg := fmt.Sprintf("unexpected success response for wireless_wireless-links_update: API contract not enforced by server. Client expected to get an error, but got: %T", result) + panic(msg) +} + +// SetTransport changes the transport on the client +func (a *Client) SetTransport(transport runtime.ClientTransport) { + a.transport = transport +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_bulk_delete_parameters.go b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_delete_parameters.go new file mode 100644 index 00000000..6ea2b01e --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_delete_parameters.go @@ -0,0 +1,141 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewWirelessWirelessLanGroupsBulkDeleteParams creates a new WirelessWirelessLanGroupsBulkDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLanGroupsBulkDeleteParams() *WirelessWirelessLanGroupsBulkDeleteParams { + return &WirelessWirelessLanGroupsBulkDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLanGroupsBulkDeleteParamsWithTimeout creates a new WirelessWirelessLanGroupsBulkDeleteParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLanGroupsBulkDeleteParamsWithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsBulkDeleteParams { + return &WirelessWirelessLanGroupsBulkDeleteParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLanGroupsBulkDeleteParamsWithContext creates a new WirelessWirelessLanGroupsBulkDeleteParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLanGroupsBulkDeleteParamsWithContext(ctx context.Context) *WirelessWirelessLanGroupsBulkDeleteParams { + return &WirelessWirelessLanGroupsBulkDeleteParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLanGroupsBulkDeleteParamsWithHTTPClient creates a new WirelessWirelessLanGroupsBulkDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLanGroupsBulkDeleteParamsWithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsBulkDeleteParams { + return &WirelessWirelessLanGroupsBulkDeleteParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLanGroupsBulkDeleteParams contains all the parameters to send to the API endpoint + for the wireless wireless lan groups bulk delete operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLanGroupsBulkDeleteParams struct { + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lan groups bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsBulkDeleteParams) WithDefaults() *WirelessWirelessLanGroupsBulkDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lan groups bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsBulkDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lan groups bulk delete params +func (o *WirelessWirelessLanGroupsBulkDeleteParams) WithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsBulkDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lan groups bulk delete params +func (o *WirelessWirelessLanGroupsBulkDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lan groups bulk delete params +func (o *WirelessWirelessLanGroupsBulkDeleteParams) WithContext(ctx context.Context) *WirelessWirelessLanGroupsBulkDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lan groups bulk delete params +func (o *WirelessWirelessLanGroupsBulkDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lan groups bulk delete params +func (o *WirelessWirelessLanGroupsBulkDeleteParams) WithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsBulkDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lan groups bulk delete params +func (o *WirelessWirelessLanGroupsBulkDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLanGroupsBulkDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_bulk_delete_responses.go b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_delete_responses.go new file mode 100644 index 00000000..e66da5eb --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// WirelessWirelessLanGroupsBulkDeleteReader is a Reader for the WirelessWirelessLanGroupsBulkDelete structure. +type WirelessWirelessLanGroupsBulkDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLanGroupsBulkDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewWirelessWirelessLanGroupsBulkDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLanGroupsBulkDeleteNoContent creates a WirelessWirelessLanGroupsBulkDeleteNoContent with default headers values +func NewWirelessWirelessLanGroupsBulkDeleteNoContent() *WirelessWirelessLanGroupsBulkDeleteNoContent { + return &WirelessWirelessLanGroupsBulkDeleteNoContent{} +} + +/* WirelessWirelessLanGroupsBulkDeleteNoContent describes a response with status code 204, with default header values. + +WirelessWirelessLanGroupsBulkDeleteNoContent wireless wireless lan groups bulk delete no content +*/ +type WirelessWirelessLanGroupsBulkDeleteNoContent struct { +} + +func (o *WirelessWirelessLanGroupsBulkDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /wireless/wireless-lan-groups/][%d] wirelessWirelessLanGroupsBulkDeleteNoContent ", 204) +} + +func (o *WirelessWirelessLanGroupsBulkDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_bulk_partial_update_parameters.go b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_partial_update_parameters.go new file mode 100644 index 00000000..f28da450 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_partial_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLanGroupsBulkPartialUpdateParams creates a new WirelessWirelessLanGroupsBulkPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLanGroupsBulkPartialUpdateParams() *WirelessWirelessLanGroupsBulkPartialUpdateParams { + return &WirelessWirelessLanGroupsBulkPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLanGroupsBulkPartialUpdateParamsWithTimeout creates a new WirelessWirelessLanGroupsBulkPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLanGroupsBulkPartialUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsBulkPartialUpdateParams { + return &WirelessWirelessLanGroupsBulkPartialUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLanGroupsBulkPartialUpdateParamsWithContext creates a new WirelessWirelessLanGroupsBulkPartialUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLanGroupsBulkPartialUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLanGroupsBulkPartialUpdateParams { + return &WirelessWirelessLanGroupsBulkPartialUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLanGroupsBulkPartialUpdateParamsWithHTTPClient creates a new WirelessWirelessLanGroupsBulkPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLanGroupsBulkPartialUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsBulkPartialUpdateParams { + return &WirelessWirelessLanGroupsBulkPartialUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLanGroupsBulkPartialUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless lan groups bulk partial update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLanGroupsBulkPartialUpdateParams struct { + + // Data. + Data *models.WritableWirelessLANGroup + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lan groups bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsBulkPartialUpdateParams) WithDefaults() *WirelessWirelessLanGroupsBulkPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lan groups bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsBulkPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lan groups bulk partial update params +func (o *WirelessWirelessLanGroupsBulkPartialUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsBulkPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lan groups bulk partial update params +func (o *WirelessWirelessLanGroupsBulkPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lan groups bulk partial update params +func (o *WirelessWirelessLanGroupsBulkPartialUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLanGroupsBulkPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lan groups bulk partial update params +func (o *WirelessWirelessLanGroupsBulkPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lan groups bulk partial update params +func (o *WirelessWirelessLanGroupsBulkPartialUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsBulkPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lan groups bulk partial update params +func (o *WirelessWirelessLanGroupsBulkPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless lan groups bulk partial update params +func (o *WirelessWirelessLanGroupsBulkPartialUpdateParams) WithData(data *models.WritableWirelessLANGroup) *WirelessWirelessLanGroupsBulkPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless lan groups bulk partial update params +func (o *WirelessWirelessLanGroupsBulkPartialUpdateParams) SetData(data *models.WritableWirelessLANGroup) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLanGroupsBulkPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_bulk_partial_update_responses.go b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_partial_update_responses.go new file mode 100644 index 00000000..316d8843 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLanGroupsBulkPartialUpdateReader is a Reader for the WirelessWirelessLanGroupsBulkPartialUpdate structure. +type WirelessWirelessLanGroupsBulkPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLanGroupsBulkPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLanGroupsBulkPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLanGroupsBulkPartialUpdateOK creates a WirelessWirelessLanGroupsBulkPartialUpdateOK with default headers values +func NewWirelessWirelessLanGroupsBulkPartialUpdateOK() *WirelessWirelessLanGroupsBulkPartialUpdateOK { + return &WirelessWirelessLanGroupsBulkPartialUpdateOK{} +} + +/* WirelessWirelessLanGroupsBulkPartialUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLanGroupsBulkPartialUpdateOK wireless wireless lan groups bulk partial update o k +*/ +type WirelessWirelessLanGroupsBulkPartialUpdateOK struct { + Payload *models.WirelessLANGroup +} + +func (o *WirelessWirelessLanGroupsBulkPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /wireless/wireless-lan-groups/][%d] wirelessWirelessLanGroupsBulkPartialUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLanGroupsBulkPartialUpdateOK) GetPayload() *models.WirelessLANGroup { + return o.Payload +} + +func (o *WirelessWirelessLanGroupsBulkPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLANGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_bulk_update_parameters.go b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_update_parameters.go new file mode 100644 index 00000000..0c3edbbb --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLanGroupsBulkUpdateParams creates a new WirelessWirelessLanGroupsBulkUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLanGroupsBulkUpdateParams() *WirelessWirelessLanGroupsBulkUpdateParams { + return &WirelessWirelessLanGroupsBulkUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLanGroupsBulkUpdateParamsWithTimeout creates a new WirelessWirelessLanGroupsBulkUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLanGroupsBulkUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsBulkUpdateParams { + return &WirelessWirelessLanGroupsBulkUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLanGroupsBulkUpdateParamsWithContext creates a new WirelessWirelessLanGroupsBulkUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLanGroupsBulkUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLanGroupsBulkUpdateParams { + return &WirelessWirelessLanGroupsBulkUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLanGroupsBulkUpdateParamsWithHTTPClient creates a new WirelessWirelessLanGroupsBulkUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLanGroupsBulkUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsBulkUpdateParams { + return &WirelessWirelessLanGroupsBulkUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLanGroupsBulkUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless lan groups bulk update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLanGroupsBulkUpdateParams struct { + + // Data. + Data *models.WritableWirelessLANGroup + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lan groups bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsBulkUpdateParams) WithDefaults() *WirelessWirelessLanGroupsBulkUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lan groups bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsBulkUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lan groups bulk update params +func (o *WirelessWirelessLanGroupsBulkUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsBulkUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lan groups bulk update params +func (o *WirelessWirelessLanGroupsBulkUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lan groups bulk update params +func (o *WirelessWirelessLanGroupsBulkUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLanGroupsBulkUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lan groups bulk update params +func (o *WirelessWirelessLanGroupsBulkUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lan groups bulk update params +func (o *WirelessWirelessLanGroupsBulkUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsBulkUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lan groups bulk update params +func (o *WirelessWirelessLanGroupsBulkUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless lan groups bulk update params +func (o *WirelessWirelessLanGroupsBulkUpdateParams) WithData(data *models.WritableWirelessLANGroup) *WirelessWirelessLanGroupsBulkUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless lan groups bulk update params +func (o *WirelessWirelessLanGroupsBulkUpdateParams) SetData(data *models.WritableWirelessLANGroup) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLanGroupsBulkUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_bulk_update_responses.go b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_update_responses.go new file mode 100644 index 00000000..8ae06d57 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_bulk_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLanGroupsBulkUpdateReader is a Reader for the WirelessWirelessLanGroupsBulkUpdate structure. +type WirelessWirelessLanGroupsBulkUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLanGroupsBulkUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLanGroupsBulkUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLanGroupsBulkUpdateOK creates a WirelessWirelessLanGroupsBulkUpdateOK with default headers values +func NewWirelessWirelessLanGroupsBulkUpdateOK() *WirelessWirelessLanGroupsBulkUpdateOK { + return &WirelessWirelessLanGroupsBulkUpdateOK{} +} + +/* WirelessWirelessLanGroupsBulkUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLanGroupsBulkUpdateOK wireless wireless lan groups bulk update o k +*/ +type WirelessWirelessLanGroupsBulkUpdateOK struct { + Payload *models.WirelessLANGroup +} + +func (o *WirelessWirelessLanGroupsBulkUpdateOK) Error() string { + return fmt.Sprintf("[PUT /wireless/wireless-lan-groups/][%d] wirelessWirelessLanGroupsBulkUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLanGroupsBulkUpdateOK) GetPayload() *models.WirelessLANGroup { + return o.Payload +} + +func (o *WirelessWirelessLanGroupsBulkUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLANGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_create_parameters.go b/netbox/client/wireless/wireless_wireless_lan_groups_create_parameters.go new file mode 100644 index 00000000..eb4c9830 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_create_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLanGroupsCreateParams creates a new WirelessWirelessLanGroupsCreateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLanGroupsCreateParams() *WirelessWirelessLanGroupsCreateParams { + return &WirelessWirelessLanGroupsCreateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLanGroupsCreateParamsWithTimeout creates a new WirelessWirelessLanGroupsCreateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLanGroupsCreateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsCreateParams { + return &WirelessWirelessLanGroupsCreateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLanGroupsCreateParamsWithContext creates a new WirelessWirelessLanGroupsCreateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLanGroupsCreateParamsWithContext(ctx context.Context) *WirelessWirelessLanGroupsCreateParams { + return &WirelessWirelessLanGroupsCreateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLanGroupsCreateParamsWithHTTPClient creates a new WirelessWirelessLanGroupsCreateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLanGroupsCreateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsCreateParams { + return &WirelessWirelessLanGroupsCreateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLanGroupsCreateParams contains all the parameters to send to the API endpoint + for the wireless wireless lan groups create operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLanGroupsCreateParams struct { + + // Data. + Data *models.WritableWirelessLANGroup + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lan groups create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsCreateParams) WithDefaults() *WirelessWirelessLanGroupsCreateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lan groups create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsCreateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lan groups create params +func (o *WirelessWirelessLanGroupsCreateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsCreateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lan groups create params +func (o *WirelessWirelessLanGroupsCreateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lan groups create params +func (o *WirelessWirelessLanGroupsCreateParams) WithContext(ctx context.Context) *WirelessWirelessLanGroupsCreateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lan groups create params +func (o *WirelessWirelessLanGroupsCreateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lan groups create params +func (o *WirelessWirelessLanGroupsCreateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsCreateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lan groups create params +func (o *WirelessWirelessLanGroupsCreateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless lan groups create params +func (o *WirelessWirelessLanGroupsCreateParams) WithData(data *models.WritableWirelessLANGroup) *WirelessWirelessLanGroupsCreateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless lan groups create params +func (o *WirelessWirelessLanGroupsCreateParams) SetData(data *models.WritableWirelessLANGroup) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLanGroupsCreateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_create_responses.go b/netbox/client/wireless/wireless_wireless_lan_groups_create_responses.go new file mode 100644 index 00000000..1c2cf9eb --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_create_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLanGroupsCreateReader is a Reader for the WirelessWirelessLanGroupsCreate structure. +type WirelessWirelessLanGroupsCreateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLanGroupsCreateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 201: + result := NewWirelessWirelessLanGroupsCreateCreated() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLanGroupsCreateCreated creates a WirelessWirelessLanGroupsCreateCreated with default headers values +func NewWirelessWirelessLanGroupsCreateCreated() *WirelessWirelessLanGroupsCreateCreated { + return &WirelessWirelessLanGroupsCreateCreated{} +} + +/* WirelessWirelessLanGroupsCreateCreated describes a response with status code 201, with default header values. + +WirelessWirelessLanGroupsCreateCreated wireless wireless lan groups create created +*/ +type WirelessWirelessLanGroupsCreateCreated struct { + Payload *models.WirelessLANGroup +} + +func (o *WirelessWirelessLanGroupsCreateCreated) Error() string { + return fmt.Sprintf("[POST /wireless/wireless-lan-groups/][%d] wirelessWirelessLanGroupsCreateCreated %+v", 201, o.Payload) +} +func (o *WirelessWirelessLanGroupsCreateCreated) GetPayload() *models.WirelessLANGroup { + return o.Payload +} + +func (o *WirelessWirelessLanGroupsCreateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLANGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_delete_parameters.go b/netbox/client/wireless/wireless_wireless_lan_groups_delete_parameters.go new file mode 100644 index 00000000..e5f8bb6c --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_delete_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewWirelessWirelessLanGroupsDeleteParams creates a new WirelessWirelessLanGroupsDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLanGroupsDeleteParams() *WirelessWirelessLanGroupsDeleteParams { + return &WirelessWirelessLanGroupsDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLanGroupsDeleteParamsWithTimeout creates a new WirelessWirelessLanGroupsDeleteParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLanGroupsDeleteParamsWithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsDeleteParams { + return &WirelessWirelessLanGroupsDeleteParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLanGroupsDeleteParamsWithContext creates a new WirelessWirelessLanGroupsDeleteParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLanGroupsDeleteParamsWithContext(ctx context.Context) *WirelessWirelessLanGroupsDeleteParams { + return &WirelessWirelessLanGroupsDeleteParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLanGroupsDeleteParamsWithHTTPClient creates a new WirelessWirelessLanGroupsDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLanGroupsDeleteParamsWithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsDeleteParams { + return &WirelessWirelessLanGroupsDeleteParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLanGroupsDeleteParams contains all the parameters to send to the API endpoint + for the wireless wireless lan groups delete operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLanGroupsDeleteParams struct { + + /* ID. + + A unique integer value identifying this Wireless LAN Group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lan groups delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsDeleteParams) WithDefaults() *WirelessWirelessLanGroupsDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lan groups delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lan groups delete params +func (o *WirelessWirelessLanGroupsDeleteParams) WithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lan groups delete params +func (o *WirelessWirelessLanGroupsDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lan groups delete params +func (o *WirelessWirelessLanGroupsDeleteParams) WithContext(ctx context.Context) *WirelessWirelessLanGroupsDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lan groups delete params +func (o *WirelessWirelessLanGroupsDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lan groups delete params +func (o *WirelessWirelessLanGroupsDeleteParams) WithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lan groups delete params +func (o *WirelessWirelessLanGroupsDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the wireless wireless lan groups delete params +func (o *WirelessWirelessLanGroupsDeleteParams) WithID(id int64) *WirelessWirelessLanGroupsDeleteParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless lan groups delete params +func (o *WirelessWirelessLanGroupsDeleteParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLanGroupsDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_delete_responses.go b/netbox/client/wireless/wireless_wireless_lan_groups_delete_responses.go new file mode 100644 index 00000000..c90a4273 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// WirelessWirelessLanGroupsDeleteReader is a Reader for the WirelessWirelessLanGroupsDelete structure. +type WirelessWirelessLanGroupsDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLanGroupsDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewWirelessWirelessLanGroupsDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLanGroupsDeleteNoContent creates a WirelessWirelessLanGroupsDeleteNoContent with default headers values +func NewWirelessWirelessLanGroupsDeleteNoContent() *WirelessWirelessLanGroupsDeleteNoContent { + return &WirelessWirelessLanGroupsDeleteNoContent{} +} + +/* WirelessWirelessLanGroupsDeleteNoContent describes a response with status code 204, with default header values. + +WirelessWirelessLanGroupsDeleteNoContent wireless wireless lan groups delete no content +*/ +type WirelessWirelessLanGroupsDeleteNoContent struct { +} + +func (o *WirelessWirelessLanGroupsDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /wireless/wireless-lan-groups/{id}/][%d] wirelessWirelessLanGroupsDeleteNoContent ", 204) +} + +func (o *WirelessWirelessLanGroupsDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_list_parameters.go b/netbox/client/wireless/wireless_wireless_lan_groups_list_parameters.go new file mode 100644 index 00000000..5e653ad2 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_list_parameters.go @@ -0,0 +1,1823 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewWirelessWirelessLanGroupsListParams creates a new WirelessWirelessLanGroupsListParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLanGroupsListParams() *WirelessWirelessLanGroupsListParams { + return &WirelessWirelessLanGroupsListParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLanGroupsListParamsWithTimeout creates a new WirelessWirelessLanGroupsListParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLanGroupsListParamsWithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsListParams { + return &WirelessWirelessLanGroupsListParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLanGroupsListParamsWithContext creates a new WirelessWirelessLanGroupsListParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLanGroupsListParamsWithContext(ctx context.Context) *WirelessWirelessLanGroupsListParams { + return &WirelessWirelessLanGroupsListParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLanGroupsListParamsWithHTTPClient creates a new WirelessWirelessLanGroupsListParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLanGroupsListParamsWithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsListParams { + return &WirelessWirelessLanGroupsListParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLanGroupsListParams contains all the parameters to send to the API endpoint + for the wireless wireless lan groups list operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLanGroupsListParams struct { + + // Created. + Created *string + + // CreatedGte. + CreatedGte *string + + // CreatedLte. + CreatedLte *string + + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + + // ID. + ID *string + + // IDGt. + IDGt *string + + // IDGte. + IDGte *string + + // IDLt. + IDLt *string + + // IDLte. + IDLte *string + + // IDn. + IDn *string + + // LastUpdated. + LastUpdated *string + + // LastUpdatedGte. + LastUpdatedGte *string + + // LastUpdatedLte. + LastUpdatedLte *string + + /* Limit. + + Number of results to return per page. + */ + Limit *int64 + + // Name. + Name *string + + // NameEmpty. + NameEmpty *string + + // NameIc. + NameIc *string + + // NameIe. + NameIe *string + + // NameIew. + NameIew *string + + // NameIsw. + NameIsw *string + + // Namen. + Namen *string + + // NameNic. + NameNic *string + + // NameNie. + NameNie *string + + // NameNiew. + NameNiew *string + + // NameNisw. + NameNisw *string + + /* Offset. + + The initial index from which to return the results. + */ + Offset *int64 + + // Parent. + Parent *string + + // Parentn. + Parentn *string + + // ParentID. + ParentID *string + + // ParentIDn. + ParentIDn *string + + // Q. + Q *string + + // Slug. + Slug *string + + // SlugEmpty. + SlugEmpty *string + + // SlugIc. + SlugIc *string + + // SlugIe. + SlugIe *string + + // SlugIew. + SlugIew *string + + // SlugIsw. + SlugIsw *string + + // Slugn. + Slugn *string + + // SlugNic. + SlugNic *string + + // SlugNie. + SlugNie *string + + // SlugNiew. + SlugNiew *string + + // SlugNisw. + SlugNisw *string + + // Tag. + Tag *string + + // Tagn. + Tagn *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lan groups list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsListParams) WithDefaults() *WirelessWirelessLanGroupsListParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lan groups list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsListParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsListParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithContext(ctx context.Context) *WirelessWirelessLanGroupsListParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsListParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithCreated adds the created to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithCreated(created *string) *WirelessWirelessLanGroupsListParams { + o.SetCreated(created) + return o +} + +// SetCreated adds the created to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetCreated(created *string) { + o.Created = created +} + +// WithCreatedGte adds the createdGte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithCreatedGte(createdGte *string) *WirelessWirelessLanGroupsListParams { + o.SetCreatedGte(createdGte) + return o +} + +// SetCreatedGte adds the createdGte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetCreatedGte(createdGte *string) { + o.CreatedGte = createdGte +} + +// WithCreatedLte adds the createdLte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithCreatedLte(createdLte *string) *WirelessWirelessLanGroupsListParams { + o.SetCreatedLte(createdLte) + return o +} + +// SetCreatedLte adds the createdLte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetCreatedLte(createdLte *string) { + o.CreatedLte = createdLte +} + +// WithDescription adds the description to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithDescription(description *string) *WirelessWirelessLanGroupsListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithDescriptionEmpty(descriptionEmpty *string) *WirelessWirelessLanGroupsListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithDescriptionIc(descriptionIc *string) *WirelessWirelessLanGroupsListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithDescriptionIe(descriptionIe *string) *WirelessWirelessLanGroupsListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithDescriptionIew(descriptionIew *string) *WirelessWirelessLanGroupsListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithDescriptionIsw(descriptionIsw *string) *WirelessWirelessLanGroupsListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithDescriptionn(descriptionn *string) *WirelessWirelessLanGroupsListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithDescriptionNic(descriptionNic *string) *WirelessWirelessLanGroupsListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithDescriptionNie(descriptionNie *string) *WirelessWirelessLanGroupsListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithDescriptionNiew(descriptionNiew *string) *WirelessWirelessLanGroupsListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithDescriptionNisw(descriptionNisw *string) *WirelessWirelessLanGroupsListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + +// WithID adds the id to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithID(id *string) *WirelessWirelessLanGroupsListParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetID(id *string) { + o.ID = id +} + +// WithIDGt adds the iDGt to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithIDGt(iDGt *string) *WirelessWirelessLanGroupsListParams { + o.SetIDGt(iDGt) + return o +} + +// SetIDGt adds the idGt to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetIDGt(iDGt *string) { + o.IDGt = iDGt +} + +// WithIDGte adds the iDGte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithIDGte(iDGte *string) *WirelessWirelessLanGroupsListParams { + o.SetIDGte(iDGte) + return o +} + +// SetIDGte adds the idGte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetIDGte(iDGte *string) { + o.IDGte = iDGte +} + +// WithIDLt adds the iDLt to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithIDLt(iDLt *string) *WirelessWirelessLanGroupsListParams { + o.SetIDLt(iDLt) + return o +} + +// SetIDLt adds the idLt to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetIDLt(iDLt *string) { + o.IDLt = iDLt +} + +// WithIDLte adds the iDLte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithIDLte(iDLte *string) *WirelessWirelessLanGroupsListParams { + o.SetIDLte(iDLte) + return o +} + +// SetIDLte adds the idLte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetIDLte(iDLte *string) { + o.IDLte = iDLte +} + +// WithIDn adds the iDn to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithIDn(iDn *string) *WirelessWirelessLanGroupsListParams { + o.SetIDn(iDn) + return o +} + +// SetIDn adds the idN to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetIDn(iDn *string) { + o.IDn = iDn +} + +// WithLastUpdated adds the lastUpdated to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithLastUpdated(lastUpdated *string) *WirelessWirelessLanGroupsListParams { + o.SetLastUpdated(lastUpdated) + return o +} + +// SetLastUpdated adds the lastUpdated to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetLastUpdated(lastUpdated *string) { + o.LastUpdated = lastUpdated +} + +// WithLastUpdatedGte adds the lastUpdatedGte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithLastUpdatedGte(lastUpdatedGte *string) *WirelessWirelessLanGroupsListParams { + o.SetLastUpdatedGte(lastUpdatedGte) + return o +} + +// SetLastUpdatedGte adds the lastUpdatedGte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetLastUpdatedGte(lastUpdatedGte *string) { + o.LastUpdatedGte = lastUpdatedGte +} + +// WithLastUpdatedLte adds the lastUpdatedLte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithLastUpdatedLte(lastUpdatedLte *string) *WirelessWirelessLanGroupsListParams { + o.SetLastUpdatedLte(lastUpdatedLte) + return o +} + +// SetLastUpdatedLte adds the lastUpdatedLte to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetLastUpdatedLte(lastUpdatedLte *string) { + o.LastUpdatedLte = lastUpdatedLte +} + +// WithLimit adds the limit to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithLimit(limit *int64) *WirelessWirelessLanGroupsListParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithName adds the name to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithName(name *string) *WirelessWirelessLanGroupsListParams { + o.SetName(name) + return o +} + +// SetName adds the name to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetName(name *string) { + o.Name = name +} + +// WithNameEmpty adds the nameEmpty to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithNameEmpty(nameEmpty *string) *WirelessWirelessLanGroupsListParams { + o.SetNameEmpty(nameEmpty) + return o +} + +// SetNameEmpty adds the nameEmpty to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetNameEmpty(nameEmpty *string) { + o.NameEmpty = nameEmpty +} + +// WithNameIc adds the nameIc to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithNameIc(nameIc *string) *WirelessWirelessLanGroupsListParams { + o.SetNameIc(nameIc) + return o +} + +// SetNameIc adds the nameIc to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetNameIc(nameIc *string) { + o.NameIc = nameIc +} + +// WithNameIe adds the nameIe to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithNameIe(nameIe *string) *WirelessWirelessLanGroupsListParams { + o.SetNameIe(nameIe) + return o +} + +// SetNameIe adds the nameIe to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetNameIe(nameIe *string) { + o.NameIe = nameIe +} + +// WithNameIew adds the nameIew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithNameIew(nameIew *string) *WirelessWirelessLanGroupsListParams { + o.SetNameIew(nameIew) + return o +} + +// SetNameIew adds the nameIew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetNameIew(nameIew *string) { + o.NameIew = nameIew +} + +// WithNameIsw adds the nameIsw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithNameIsw(nameIsw *string) *WirelessWirelessLanGroupsListParams { + o.SetNameIsw(nameIsw) + return o +} + +// SetNameIsw adds the nameIsw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetNameIsw(nameIsw *string) { + o.NameIsw = nameIsw +} + +// WithNamen adds the namen to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithNamen(namen *string) *WirelessWirelessLanGroupsListParams { + o.SetNamen(namen) + return o +} + +// SetNamen adds the nameN to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetNamen(namen *string) { + o.Namen = namen +} + +// WithNameNic adds the nameNic to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithNameNic(nameNic *string) *WirelessWirelessLanGroupsListParams { + o.SetNameNic(nameNic) + return o +} + +// SetNameNic adds the nameNic to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetNameNic(nameNic *string) { + o.NameNic = nameNic +} + +// WithNameNie adds the nameNie to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithNameNie(nameNie *string) *WirelessWirelessLanGroupsListParams { + o.SetNameNie(nameNie) + return o +} + +// SetNameNie adds the nameNie to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetNameNie(nameNie *string) { + o.NameNie = nameNie +} + +// WithNameNiew adds the nameNiew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithNameNiew(nameNiew *string) *WirelessWirelessLanGroupsListParams { + o.SetNameNiew(nameNiew) + return o +} + +// SetNameNiew adds the nameNiew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetNameNiew(nameNiew *string) { + o.NameNiew = nameNiew +} + +// WithNameNisw adds the nameNisw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithNameNisw(nameNisw *string) *WirelessWirelessLanGroupsListParams { + o.SetNameNisw(nameNisw) + return o +} + +// SetNameNisw adds the nameNisw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetNameNisw(nameNisw *string) { + o.NameNisw = nameNisw +} + +// WithOffset adds the offset to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithOffset(offset *int64) *WirelessWirelessLanGroupsListParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithParent adds the parent to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithParent(parent *string) *WirelessWirelessLanGroupsListParams { + o.SetParent(parent) + return o +} + +// SetParent adds the parent to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetParent(parent *string) { + o.Parent = parent +} + +// WithParentn adds the parentn to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithParentn(parentn *string) *WirelessWirelessLanGroupsListParams { + o.SetParentn(parentn) + return o +} + +// SetParentn adds the parentN to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetParentn(parentn *string) { + o.Parentn = parentn +} + +// WithParentID adds the parentID to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithParentID(parentID *string) *WirelessWirelessLanGroupsListParams { + o.SetParentID(parentID) + return o +} + +// SetParentID adds the parentId to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetParentID(parentID *string) { + o.ParentID = parentID +} + +// WithParentIDn adds the parentIDn to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithParentIDn(parentIDn *string) *WirelessWirelessLanGroupsListParams { + o.SetParentIDn(parentIDn) + return o +} + +// SetParentIDn adds the parentIdN to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetParentIDn(parentIDn *string) { + o.ParentIDn = parentIDn +} + +// WithQ adds the q to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithQ(q *string) *WirelessWirelessLanGroupsListParams { + o.SetQ(q) + return o +} + +// SetQ adds the q to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetQ(q *string) { + o.Q = q +} + +// WithSlug adds the slug to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithSlug(slug *string) *WirelessWirelessLanGroupsListParams { + o.SetSlug(slug) + return o +} + +// SetSlug adds the slug to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetSlug(slug *string) { + o.Slug = slug +} + +// WithSlugEmpty adds the slugEmpty to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithSlugEmpty(slugEmpty *string) *WirelessWirelessLanGroupsListParams { + o.SetSlugEmpty(slugEmpty) + return o +} + +// SetSlugEmpty adds the slugEmpty to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetSlugEmpty(slugEmpty *string) { + o.SlugEmpty = slugEmpty +} + +// WithSlugIc adds the slugIc to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithSlugIc(slugIc *string) *WirelessWirelessLanGroupsListParams { + o.SetSlugIc(slugIc) + return o +} + +// SetSlugIc adds the slugIc to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetSlugIc(slugIc *string) { + o.SlugIc = slugIc +} + +// WithSlugIe adds the slugIe to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithSlugIe(slugIe *string) *WirelessWirelessLanGroupsListParams { + o.SetSlugIe(slugIe) + return o +} + +// SetSlugIe adds the slugIe to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetSlugIe(slugIe *string) { + o.SlugIe = slugIe +} + +// WithSlugIew adds the slugIew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithSlugIew(slugIew *string) *WirelessWirelessLanGroupsListParams { + o.SetSlugIew(slugIew) + return o +} + +// SetSlugIew adds the slugIew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetSlugIew(slugIew *string) { + o.SlugIew = slugIew +} + +// WithSlugIsw adds the slugIsw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithSlugIsw(slugIsw *string) *WirelessWirelessLanGroupsListParams { + o.SetSlugIsw(slugIsw) + return o +} + +// SetSlugIsw adds the slugIsw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetSlugIsw(slugIsw *string) { + o.SlugIsw = slugIsw +} + +// WithSlugn adds the slugn to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithSlugn(slugn *string) *WirelessWirelessLanGroupsListParams { + o.SetSlugn(slugn) + return o +} + +// SetSlugn adds the slugN to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetSlugn(slugn *string) { + o.Slugn = slugn +} + +// WithSlugNic adds the slugNic to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithSlugNic(slugNic *string) *WirelessWirelessLanGroupsListParams { + o.SetSlugNic(slugNic) + return o +} + +// SetSlugNic adds the slugNic to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetSlugNic(slugNic *string) { + o.SlugNic = slugNic +} + +// WithSlugNie adds the slugNie to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithSlugNie(slugNie *string) *WirelessWirelessLanGroupsListParams { + o.SetSlugNie(slugNie) + return o +} + +// SetSlugNie adds the slugNie to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetSlugNie(slugNie *string) { + o.SlugNie = slugNie +} + +// WithSlugNiew adds the slugNiew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithSlugNiew(slugNiew *string) *WirelessWirelessLanGroupsListParams { + o.SetSlugNiew(slugNiew) + return o +} + +// SetSlugNiew adds the slugNiew to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetSlugNiew(slugNiew *string) { + o.SlugNiew = slugNiew +} + +// WithSlugNisw adds the slugNisw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithSlugNisw(slugNisw *string) *WirelessWirelessLanGroupsListParams { + o.SetSlugNisw(slugNisw) + return o +} + +// SetSlugNisw adds the slugNisw to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetSlugNisw(slugNisw *string) { + o.SlugNisw = slugNisw +} + +// WithTag adds the tag to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithTag(tag *string) *WirelessWirelessLanGroupsListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) WithTagn(tagn *string) *WirelessWirelessLanGroupsListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the wireless wireless lan groups list params +func (o *WirelessWirelessLanGroupsListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLanGroupsListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.Created != nil { + + // query param created + var qrCreated string + + if o.Created != nil { + qrCreated = *o.Created + } + qCreated := qrCreated + if qCreated != "" { + + if err := r.SetQueryParam("created", qCreated); err != nil { + return err + } + } + } + + if o.CreatedGte != nil { + + // query param created__gte + var qrCreatedGte string + + if o.CreatedGte != nil { + qrCreatedGte = *o.CreatedGte + } + qCreatedGte := qrCreatedGte + if qCreatedGte != "" { + + if err := r.SetQueryParam("created__gte", qCreatedGte); err != nil { + return err + } + } + } + + if o.CreatedLte != nil { + + // query param created__lte + var qrCreatedLte string + + if o.CreatedLte != nil { + qrCreatedLte = *o.CreatedLte + } + qCreatedLte := qrCreatedLte + if qCreatedLte != "" { + + if err := r.SetQueryParam("created__lte", qCreatedLte); err != nil { + return err + } + } + } + + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + + if o.ID != nil { + + // query param id + var qrID string + + if o.ID != nil { + qrID = *o.ID + } + qID := qrID + if qID != "" { + + if err := r.SetQueryParam("id", qID); err != nil { + return err + } + } + } + + if o.IDGt != nil { + + // query param id__gt + var qrIDGt string + + if o.IDGt != nil { + qrIDGt = *o.IDGt + } + qIDGt := qrIDGt + if qIDGt != "" { + + if err := r.SetQueryParam("id__gt", qIDGt); err != nil { + return err + } + } + } + + if o.IDGte != nil { + + // query param id__gte + var qrIDGte string + + if o.IDGte != nil { + qrIDGte = *o.IDGte + } + qIDGte := qrIDGte + if qIDGte != "" { + + if err := r.SetQueryParam("id__gte", qIDGte); err != nil { + return err + } + } + } + + if o.IDLt != nil { + + // query param id__lt + var qrIDLt string + + if o.IDLt != nil { + qrIDLt = *o.IDLt + } + qIDLt := qrIDLt + if qIDLt != "" { + + if err := r.SetQueryParam("id__lt", qIDLt); err != nil { + return err + } + } + } + + if o.IDLte != nil { + + // query param id__lte + var qrIDLte string + + if o.IDLte != nil { + qrIDLte = *o.IDLte + } + qIDLte := qrIDLte + if qIDLte != "" { + + if err := r.SetQueryParam("id__lte", qIDLte); err != nil { + return err + } + } + } + + if o.IDn != nil { + + // query param id__n + var qrIDn string + + if o.IDn != nil { + qrIDn = *o.IDn + } + qIDn := qrIDn + if qIDn != "" { + + if err := r.SetQueryParam("id__n", qIDn); err != nil { + return err + } + } + } + + if o.LastUpdated != nil { + + // query param last_updated + var qrLastUpdated string + + if o.LastUpdated != nil { + qrLastUpdated = *o.LastUpdated + } + qLastUpdated := qrLastUpdated + if qLastUpdated != "" { + + if err := r.SetQueryParam("last_updated", qLastUpdated); err != nil { + return err + } + } + } + + if o.LastUpdatedGte != nil { + + // query param last_updated__gte + var qrLastUpdatedGte string + + if o.LastUpdatedGte != nil { + qrLastUpdatedGte = *o.LastUpdatedGte + } + qLastUpdatedGte := qrLastUpdatedGte + if qLastUpdatedGte != "" { + + if err := r.SetQueryParam("last_updated__gte", qLastUpdatedGte); err != nil { + return err + } + } + } + + if o.LastUpdatedLte != nil { + + // query param last_updated__lte + var qrLastUpdatedLte string + + if o.LastUpdatedLte != nil { + qrLastUpdatedLte = *o.LastUpdatedLte + } + qLastUpdatedLte := qrLastUpdatedLte + if qLastUpdatedLte != "" { + + if err := r.SetQueryParam("last_updated__lte", qLastUpdatedLte); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Name != nil { + + // query param name + var qrName string + + if o.Name != nil { + qrName = *o.Name + } + qName := qrName + if qName != "" { + + if err := r.SetQueryParam("name", qName); err != nil { + return err + } + } + } + + if o.NameEmpty != nil { + + // query param name__empty + var qrNameEmpty string + + if o.NameEmpty != nil { + qrNameEmpty = *o.NameEmpty + } + qNameEmpty := qrNameEmpty + if qNameEmpty != "" { + + if err := r.SetQueryParam("name__empty", qNameEmpty); err != nil { + return err + } + } + } + + if o.NameIc != nil { + + // query param name__ic + var qrNameIc string + + if o.NameIc != nil { + qrNameIc = *o.NameIc + } + qNameIc := qrNameIc + if qNameIc != "" { + + if err := r.SetQueryParam("name__ic", qNameIc); err != nil { + return err + } + } + } + + if o.NameIe != nil { + + // query param name__ie + var qrNameIe string + + if o.NameIe != nil { + qrNameIe = *o.NameIe + } + qNameIe := qrNameIe + if qNameIe != "" { + + if err := r.SetQueryParam("name__ie", qNameIe); err != nil { + return err + } + } + } + + if o.NameIew != nil { + + // query param name__iew + var qrNameIew string + + if o.NameIew != nil { + qrNameIew = *o.NameIew + } + qNameIew := qrNameIew + if qNameIew != "" { + + if err := r.SetQueryParam("name__iew", qNameIew); err != nil { + return err + } + } + } + + if o.NameIsw != nil { + + // query param name__isw + var qrNameIsw string + + if o.NameIsw != nil { + qrNameIsw = *o.NameIsw + } + qNameIsw := qrNameIsw + if qNameIsw != "" { + + if err := r.SetQueryParam("name__isw", qNameIsw); err != nil { + return err + } + } + } + + if o.Namen != nil { + + // query param name__n + var qrNamen string + + if o.Namen != nil { + qrNamen = *o.Namen + } + qNamen := qrNamen + if qNamen != "" { + + if err := r.SetQueryParam("name__n", qNamen); err != nil { + return err + } + } + } + + if o.NameNic != nil { + + // query param name__nic + var qrNameNic string + + if o.NameNic != nil { + qrNameNic = *o.NameNic + } + qNameNic := qrNameNic + if qNameNic != "" { + + if err := r.SetQueryParam("name__nic", qNameNic); err != nil { + return err + } + } + } + + if o.NameNie != nil { + + // query param name__nie + var qrNameNie string + + if o.NameNie != nil { + qrNameNie = *o.NameNie + } + qNameNie := qrNameNie + if qNameNie != "" { + + if err := r.SetQueryParam("name__nie", qNameNie); err != nil { + return err + } + } + } + + if o.NameNiew != nil { + + // query param name__niew + var qrNameNiew string + + if o.NameNiew != nil { + qrNameNiew = *o.NameNiew + } + qNameNiew := qrNameNiew + if qNameNiew != "" { + + if err := r.SetQueryParam("name__niew", qNameNiew); err != nil { + return err + } + } + } + + if o.NameNisw != nil { + + // query param name__nisw + var qrNameNisw string + + if o.NameNisw != nil { + qrNameNisw = *o.NameNisw + } + qNameNisw := qrNameNisw + if qNameNisw != "" { + + if err := r.SetQueryParam("name__nisw", qNameNisw); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.Parent != nil { + + // query param parent + var qrParent string + + if o.Parent != nil { + qrParent = *o.Parent + } + qParent := qrParent + if qParent != "" { + + if err := r.SetQueryParam("parent", qParent); err != nil { + return err + } + } + } + + if o.Parentn != nil { + + // query param parent__n + var qrParentn string + + if o.Parentn != nil { + qrParentn = *o.Parentn + } + qParentn := qrParentn + if qParentn != "" { + + if err := r.SetQueryParam("parent__n", qParentn); err != nil { + return err + } + } + } + + if o.ParentID != nil { + + // query param parent_id + var qrParentID string + + if o.ParentID != nil { + qrParentID = *o.ParentID + } + qParentID := qrParentID + if qParentID != "" { + + if err := r.SetQueryParam("parent_id", qParentID); err != nil { + return err + } + } + } + + if o.ParentIDn != nil { + + // query param parent_id__n + var qrParentIDn string + + if o.ParentIDn != nil { + qrParentIDn = *o.ParentIDn + } + qParentIDn := qrParentIDn + if qParentIDn != "" { + + if err := r.SetQueryParam("parent_id__n", qParentIDn); err != nil { + return err + } + } + } + + if o.Q != nil { + + // query param q + var qrQ string + + if o.Q != nil { + qrQ = *o.Q + } + qQ := qrQ + if qQ != "" { + + if err := r.SetQueryParam("q", qQ); err != nil { + return err + } + } + } + + if o.Slug != nil { + + // query param slug + var qrSlug string + + if o.Slug != nil { + qrSlug = *o.Slug + } + qSlug := qrSlug + if qSlug != "" { + + if err := r.SetQueryParam("slug", qSlug); err != nil { + return err + } + } + } + + if o.SlugEmpty != nil { + + // query param slug__empty + var qrSlugEmpty string + + if o.SlugEmpty != nil { + qrSlugEmpty = *o.SlugEmpty + } + qSlugEmpty := qrSlugEmpty + if qSlugEmpty != "" { + + if err := r.SetQueryParam("slug__empty", qSlugEmpty); err != nil { + return err + } + } + } + + if o.SlugIc != nil { + + // query param slug__ic + var qrSlugIc string + + if o.SlugIc != nil { + qrSlugIc = *o.SlugIc + } + qSlugIc := qrSlugIc + if qSlugIc != "" { + + if err := r.SetQueryParam("slug__ic", qSlugIc); err != nil { + return err + } + } + } + + if o.SlugIe != nil { + + // query param slug__ie + var qrSlugIe string + + if o.SlugIe != nil { + qrSlugIe = *o.SlugIe + } + qSlugIe := qrSlugIe + if qSlugIe != "" { + + if err := r.SetQueryParam("slug__ie", qSlugIe); err != nil { + return err + } + } + } + + if o.SlugIew != nil { + + // query param slug__iew + var qrSlugIew string + + if o.SlugIew != nil { + qrSlugIew = *o.SlugIew + } + qSlugIew := qrSlugIew + if qSlugIew != "" { + + if err := r.SetQueryParam("slug__iew", qSlugIew); err != nil { + return err + } + } + } + + if o.SlugIsw != nil { + + // query param slug__isw + var qrSlugIsw string + + if o.SlugIsw != nil { + qrSlugIsw = *o.SlugIsw + } + qSlugIsw := qrSlugIsw + if qSlugIsw != "" { + + if err := r.SetQueryParam("slug__isw", qSlugIsw); err != nil { + return err + } + } + } + + if o.Slugn != nil { + + // query param slug__n + var qrSlugn string + + if o.Slugn != nil { + qrSlugn = *o.Slugn + } + qSlugn := qrSlugn + if qSlugn != "" { + + if err := r.SetQueryParam("slug__n", qSlugn); err != nil { + return err + } + } + } + + if o.SlugNic != nil { + + // query param slug__nic + var qrSlugNic string + + if o.SlugNic != nil { + qrSlugNic = *o.SlugNic + } + qSlugNic := qrSlugNic + if qSlugNic != "" { + + if err := r.SetQueryParam("slug__nic", qSlugNic); err != nil { + return err + } + } + } + + if o.SlugNie != nil { + + // query param slug__nie + var qrSlugNie string + + if o.SlugNie != nil { + qrSlugNie = *o.SlugNie + } + qSlugNie := qrSlugNie + if qSlugNie != "" { + + if err := r.SetQueryParam("slug__nie", qSlugNie); err != nil { + return err + } + } + } + + if o.SlugNiew != nil { + + // query param slug__niew + var qrSlugNiew string + + if o.SlugNiew != nil { + qrSlugNiew = *o.SlugNiew + } + qSlugNiew := qrSlugNiew + if qSlugNiew != "" { + + if err := r.SetQueryParam("slug__niew", qSlugNiew); err != nil { + return err + } + } + } + + if o.SlugNisw != nil { + + // query param slug__nisw + var qrSlugNisw string + + if o.SlugNisw != nil { + qrSlugNisw = *o.SlugNisw + } + qSlugNisw := qrSlugNisw + if qSlugNisw != "" { + + if err := r.SetQueryParam("slug__nisw", qSlugNisw); err != nil { + return err + } + } + } + + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_list_responses.go b/netbox/client/wireless/wireless_wireless_lan_groups_list_responses.go new file mode 100644 index 00000000..ef3a705b --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_list_responses.go @@ -0,0 +1,247 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLanGroupsListReader is a Reader for the WirelessWirelessLanGroupsList structure. +type WirelessWirelessLanGroupsListReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLanGroupsListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLanGroupsListOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLanGroupsListOK creates a WirelessWirelessLanGroupsListOK with default headers values +func NewWirelessWirelessLanGroupsListOK() *WirelessWirelessLanGroupsListOK { + return &WirelessWirelessLanGroupsListOK{} +} + +/* WirelessWirelessLanGroupsListOK describes a response with status code 200, with default header values. + +WirelessWirelessLanGroupsListOK wireless wireless lan groups list o k +*/ +type WirelessWirelessLanGroupsListOK struct { + Payload *WirelessWirelessLanGroupsListOKBody +} + +func (o *WirelessWirelessLanGroupsListOK) Error() string { + return fmt.Sprintf("[GET /wireless/wireless-lan-groups/][%d] wirelessWirelessLanGroupsListOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLanGroupsListOK) GetPayload() *WirelessWirelessLanGroupsListOKBody { + return o.Payload +} + +func (o *WirelessWirelessLanGroupsListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(WirelessWirelessLanGroupsListOKBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*WirelessWirelessLanGroupsListOKBody wireless wireless lan groups list o k body +swagger:model WirelessWirelessLanGroupsListOKBody +*/ +type WirelessWirelessLanGroupsListOKBody struct { + + // count + // Required: true + Count *int64 `json:"count"` + + // next + // Format: uri + Next *strfmt.URI `json:"next,omitempty"` + + // previous + // Format: uri + Previous *strfmt.URI `json:"previous,omitempty"` + + // results + // Required: true + Results []*models.WirelessLANGroup `json:"results"` +} + +// Validate validates this wireless wireless lan groups list o k body +func (o *WirelessWirelessLanGroupsListOKBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateCount(formats); err != nil { + res = append(res, err) + } + + if err := o.validateNext(formats); err != nil { + res = append(res, err) + } + + if err := o.validatePrevious(formats); err != nil { + res = append(res, err) + } + + if err := o.validateResults(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *WirelessWirelessLanGroupsListOKBody) validateCount(formats strfmt.Registry) error { + + if err := validate.Required("wirelessWirelessLanGroupsListOK"+"."+"count", "body", o.Count); err != nil { + return err + } + + return nil +} + +func (o *WirelessWirelessLanGroupsListOKBody) validateNext(formats strfmt.Registry) error { + if swag.IsZero(o.Next) { // not required + return nil + } + + if err := validate.FormatOf("wirelessWirelessLanGroupsListOK"+"."+"next", "body", "uri", o.Next.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *WirelessWirelessLanGroupsListOKBody) validatePrevious(formats strfmt.Registry) error { + if swag.IsZero(o.Previous) { // not required + return nil + } + + if err := validate.FormatOf("wirelessWirelessLanGroupsListOK"+"."+"previous", "body", "uri", o.Previous.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *WirelessWirelessLanGroupsListOKBody) validateResults(formats strfmt.Registry) error { + + if err := validate.Required("wirelessWirelessLanGroupsListOK"+"."+"results", "body", o.Results); err != nil { + return err + } + + for i := 0; i < len(o.Results); i++ { + if swag.IsZero(o.Results[i]) { // not required + continue + } + + if o.Results[i] != nil { + if err := o.Results[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("wirelessWirelessLanGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("wirelessWirelessLanGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this wireless wireless lan groups list o k body based on the context it is used +func (o *WirelessWirelessLanGroupsListOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := o.contextValidateResults(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *WirelessWirelessLanGroupsListOKBody) contextValidateResults(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(o.Results); i++ { + + if o.Results[i] != nil { + if err := o.Results[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("wirelessWirelessLanGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("wirelessWirelessLanGroupsListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (o *WirelessWirelessLanGroupsListOKBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *WirelessWirelessLanGroupsListOKBody) UnmarshalBinary(b []byte) error { + var res WirelessWirelessLanGroupsListOKBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_partial_update_parameters.go b/netbox/client/wireless/wireless_wireless_lan_groups_partial_update_parameters.go new file mode 100644 index 00000000..391ac62c --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_partial_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLanGroupsPartialUpdateParams creates a new WirelessWirelessLanGroupsPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLanGroupsPartialUpdateParams() *WirelessWirelessLanGroupsPartialUpdateParams { + return &WirelessWirelessLanGroupsPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLanGroupsPartialUpdateParamsWithTimeout creates a new WirelessWirelessLanGroupsPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLanGroupsPartialUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsPartialUpdateParams { + return &WirelessWirelessLanGroupsPartialUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLanGroupsPartialUpdateParamsWithContext creates a new WirelessWirelessLanGroupsPartialUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLanGroupsPartialUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLanGroupsPartialUpdateParams { + return &WirelessWirelessLanGroupsPartialUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLanGroupsPartialUpdateParamsWithHTTPClient creates a new WirelessWirelessLanGroupsPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLanGroupsPartialUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsPartialUpdateParams { + return &WirelessWirelessLanGroupsPartialUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLanGroupsPartialUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless lan groups partial update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLanGroupsPartialUpdateParams struct { + + // Data. + Data *models.WritableWirelessLANGroup + + /* ID. + + A unique integer value identifying this Wireless LAN Group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lan groups partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsPartialUpdateParams) WithDefaults() *WirelessWirelessLanGroupsPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lan groups partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lan groups partial update params +func (o *WirelessWirelessLanGroupsPartialUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lan groups partial update params +func (o *WirelessWirelessLanGroupsPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lan groups partial update params +func (o *WirelessWirelessLanGroupsPartialUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLanGroupsPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lan groups partial update params +func (o *WirelessWirelessLanGroupsPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lan groups partial update params +func (o *WirelessWirelessLanGroupsPartialUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lan groups partial update params +func (o *WirelessWirelessLanGroupsPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless lan groups partial update params +func (o *WirelessWirelessLanGroupsPartialUpdateParams) WithData(data *models.WritableWirelessLANGroup) *WirelessWirelessLanGroupsPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless lan groups partial update params +func (o *WirelessWirelessLanGroupsPartialUpdateParams) SetData(data *models.WritableWirelessLANGroup) { + o.Data = data +} + +// WithID adds the id to the wireless wireless lan groups partial update params +func (o *WirelessWirelessLanGroupsPartialUpdateParams) WithID(id int64) *WirelessWirelessLanGroupsPartialUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless lan groups partial update params +func (o *WirelessWirelessLanGroupsPartialUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLanGroupsPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_partial_update_responses.go b/netbox/client/wireless/wireless_wireless_lan_groups_partial_update_responses.go new file mode 100644 index 00000000..863bdfd5 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLanGroupsPartialUpdateReader is a Reader for the WirelessWirelessLanGroupsPartialUpdate structure. +type WirelessWirelessLanGroupsPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLanGroupsPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLanGroupsPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLanGroupsPartialUpdateOK creates a WirelessWirelessLanGroupsPartialUpdateOK with default headers values +func NewWirelessWirelessLanGroupsPartialUpdateOK() *WirelessWirelessLanGroupsPartialUpdateOK { + return &WirelessWirelessLanGroupsPartialUpdateOK{} +} + +/* WirelessWirelessLanGroupsPartialUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLanGroupsPartialUpdateOK wireless wireless lan groups partial update o k +*/ +type WirelessWirelessLanGroupsPartialUpdateOK struct { + Payload *models.WirelessLANGroup +} + +func (o *WirelessWirelessLanGroupsPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /wireless/wireless-lan-groups/{id}/][%d] wirelessWirelessLanGroupsPartialUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLanGroupsPartialUpdateOK) GetPayload() *models.WirelessLANGroup { + return o.Payload +} + +func (o *WirelessWirelessLanGroupsPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLANGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_read_parameters.go b/netbox/client/wireless/wireless_wireless_lan_groups_read_parameters.go new file mode 100644 index 00000000..97ae5d59 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_read_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewWirelessWirelessLanGroupsReadParams creates a new WirelessWirelessLanGroupsReadParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLanGroupsReadParams() *WirelessWirelessLanGroupsReadParams { + return &WirelessWirelessLanGroupsReadParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLanGroupsReadParamsWithTimeout creates a new WirelessWirelessLanGroupsReadParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLanGroupsReadParamsWithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsReadParams { + return &WirelessWirelessLanGroupsReadParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLanGroupsReadParamsWithContext creates a new WirelessWirelessLanGroupsReadParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLanGroupsReadParamsWithContext(ctx context.Context) *WirelessWirelessLanGroupsReadParams { + return &WirelessWirelessLanGroupsReadParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLanGroupsReadParamsWithHTTPClient creates a new WirelessWirelessLanGroupsReadParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLanGroupsReadParamsWithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsReadParams { + return &WirelessWirelessLanGroupsReadParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLanGroupsReadParams contains all the parameters to send to the API endpoint + for the wireless wireless lan groups read operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLanGroupsReadParams struct { + + /* ID. + + A unique integer value identifying this Wireless LAN Group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lan groups read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsReadParams) WithDefaults() *WirelessWirelessLanGroupsReadParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lan groups read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsReadParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lan groups read params +func (o *WirelessWirelessLanGroupsReadParams) WithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsReadParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lan groups read params +func (o *WirelessWirelessLanGroupsReadParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lan groups read params +func (o *WirelessWirelessLanGroupsReadParams) WithContext(ctx context.Context) *WirelessWirelessLanGroupsReadParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lan groups read params +func (o *WirelessWirelessLanGroupsReadParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lan groups read params +func (o *WirelessWirelessLanGroupsReadParams) WithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsReadParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lan groups read params +func (o *WirelessWirelessLanGroupsReadParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the wireless wireless lan groups read params +func (o *WirelessWirelessLanGroupsReadParams) WithID(id int64) *WirelessWirelessLanGroupsReadParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless lan groups read params +func (o *WirelessWirelessLanGroupsReadParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLanGroupsReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_read_responses.go b/netbox/client/wireless/wireless_wireless_lan_groups_read_responses.go new file mode 100644 index 00000000..676f3ff0 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_read_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLanGroupsReadReader is a Reader for the WirelessWirelessLanGroupsRead structure. +type WirelessWirelessLanGroupsReadReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLanGroupsReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLanGroupsReadOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLanGroupsReadOK creates a WirelessWirelessLanGroupsReadOK with default headers values +func NewWirelessWirelessLanGroupsReadOK() *WirelessWirelessLanGroupsReadOK { + return &WirelessWirelessLanGroupsReadOK{} +} + +/* WirelessWirelessLanGroupsReadOK describes a response with status code 200, with default header values. + +WirelessWirelessLanGroupsReadOK wireless wireless lan groups read o k +*/ +type WirelessWirelessLanGroupsReadOK struct { + Payload *models.WirelessLANGroup +} + +func (o *WirelessWirelessLanGroupsReadOK) Error() string { + return fmt.Sprintf("[GET /wireless/wireless-lan-groups/{id}/][%d] wirelessWirelessLanGroupsReadOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLanGroupsReadOK) GetPayload() *models.WirelessLANGroup { + return o.Payload +} + +func (o *WirelessWirelessLanGroupsReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLANGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_update_parameters.go b/netbox/client/wireless/wireless_wireless_lan_groups_update_parameters.go new file mode 100644 index 00000000..198c413b --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLanGroupsUpdateParams creates a new WirelessWirelessLanGroupsUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLanGroupsUpdateParams() *WirelessWirelessLanGroupsUpdateParams { + return &WirelessWirelessLanGroupsUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLanGroupsUpdateParamsWithTimeout creates a new WirelessWirelessLanGroupsUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLanGroupsUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsUpdateParams { + return &WirelessWirelessLanGroupsUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLanGroupsUpdateParamsWithContext creates a new WirelessWirelessLanGroupsUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLanGroupsUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLanGroupsUpdateParams { + return &WirelessWirelessLanGroupsUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLanGroupsUpdateParamsWithHTTPClient creates a new WirelessWirelessLanGroupsUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLanGroupsUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsUpdateParams { + return &WirelessWirelessLanGroupsUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLanGroupsUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless lan groups update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLanGroupsUpdateParams struct { + + // Data. + Data *models.WritableWirelessLANGroup + + /* ID. + + A unique integer value identifying this Wireless LAN Group. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lan groups update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsUpdateParams) WithDefaults() *WirelessWirelessLanGroupsUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lan groups update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLanGroupsUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lan groups update params +func (o *WirelessWirelessLanGroupsUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLanGroupsUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lan groups update params +func (o *WirelessWirelessLanGroupsUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lan groups update params +func (o *WirelessWirelessLanGroupsUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLanGroupsUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lan groups update params +func (o *WirelessWirelessLanGroupsUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lan groups update params +func (o *WirelessWirelessLanGroupsUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLanGroupsUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lan groups update params +func (o *WirelessWirelessLanGroupsUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless lan groups update params +func (o *WirelessWirelessLanGroupsUpdateParams) WithData(data *models.WritableWirelessLANGroup) *WirelessWirelessLanGroupsUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless lan groups update params +func (o *WirelessWirelessLanGroupsUpdateParams) SetData(data *models.WritableWirelessLANGroup) { + o.Data = data +} + +// WithID adds the id to the wireless wireless lan groups update params +func (o *WirelessWirelessLanGroupsUpdateParams) WithID(id int64) *WirelessWirelessLanGroupsUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless lan groups update params +func (o *WirelessWirelessLanGroupsUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLanGroupsUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lan_groups_update_responses.go b/netbox/client/wireless/wireless_wireless_lan_groups_update_responses.go new file mode 100644 index 00000000..09ed0c06 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lan_groups_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLanGroupsUpdateReader is a Reader for the WirelessWirelessLanGroupsUpdate structure. +type WirelessWirelessLanGroupsUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLanGroupsUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLanGroupsUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLanGroupsUpdateOK creates a WirelessWirelessLanGroupsUpdateOK with default headers values +func NewWirelessWirelessLanGroupsUpdateOK() *WirelessWirelessLanGroupsUpdateOK { + return &WirelessWirelessLanGroupsUpdateOK{} +} + +/* WirelessWirelessLanGroupsUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLanGroupsUpdateOK wireless wireless lan groups update o k +*/ +type WirelessWirelessLanGroupsUpdateOK struct { + Payload *models.WirelessLANGroup +} + +func (o *WirelessWirelessLanGroupsUpdateOK) Error() string { + return fmt.Sprintf("[PUT /wireless/wireless-lan-groups/{id}/][%d] wirelessWirelessLanGroupsUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLanGroupsUpdateOK) GetPayload() *models.WirelessLANGroup { + return o.Payload +} + +func (o *WirelessWirelessLanGroupsUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLANGroup) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_bulk_delete_parameters.go b/netbox/client/wireless/wireless_wireless_lans_bulk_delete_parameters.go new file mode 100644 index 00000000..9c1248d6 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_bulk_delete_parameters.go @@ -0,0 +1,141 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewWirelessWirelessLansBulkDeleteParams creates a new WirelessWirelessLansBulkDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLansBulkDeleteParams() *WirelessWirelessLansBulkDeleteParams { + return &WirelessWirelessLansBulkDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLansBulkDeleteParamsWithTimeout creates a new WirelessWirelessLansBulkDeleteParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLansBulkDeleteParamsWithTimeout(timeout time.Duration) *WirelessWirelessLansBulkDeleteParams { + return &WirelessWirelessLansBulkDeleteParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLansBulkDeleteParamsWithContext creates a new WirelessWirelessLansBulkDeleteParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLansBulkDeleteParamsWithContext(ctx context.Context) *WirelessWirelessLansBulkDeleteParams { + return &WirelessWirelessLansBulkDeleteParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLansBulkDeleteParamsWithHTTPClient creates a new WirelessWirelessLansBulkDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLansBulkDeleteParamsWithHTTPClient(client *http.Client) *WirelessWirelessLansBulkDeleteParams { + return &WirelessWirelessLansBulkDeleteParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLansBulkDeleteParams contains all the parameters to send to the API endpoint + for the wireless wireless lans bulk delete operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLansBulkDeleteParams struct { + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lans bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansBulkDeleteParams) WithDefaults() *WirelessWirelessLansBulkDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lans bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansBulkDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lans bulk delete params +func (o *WirelessWirelessLansBulkDeleteParams) WithTimeout(timeout time.Duration) *WirelessWirelessLansBulkDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lans bulk delete params +func (o *WirelessWirelessLansBulkDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lans bulk delete params +func (o *WirelessWirelessLansBulkDeleteParams) WithContext(ctx context.Context) *WirelessWirelessLansBulkDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lans bulk delete params +func (o *WirelessWirelessLansBulkDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lans bulk delete params +func (o *WirelessWirelessLansBulkDeleteParams) WithHTTPClient(client *http.Client) *WirelessWirelessLansBulkDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lans bulk delete params +func (o *WirelessWirelessLansBulkDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLansBulkDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_bulk_delete_responses.go b/netbox/client/wireless/wireless_wireless_lans_bulk_delete_responses.go new file mode 100644 index 00000000..36d25d7c --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_bulk_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// WirelessWirelessLansBulkDeleteReader is a Reader for the WirelessWirelessLansBulkDelete structure. +type WirelessWirelessLansBulkDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLansBulkDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewWirelessWirelessLansBulkDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLansBulkDeleteNoContent creates a WirelessWirelessLansBulkDeleteNoContent with default headers values +func NewWirelessWirelessLansBulkDeleteNoContent() *WirelessWirelessLansBulkDeleteNoContent { + return &WirelessWirelessLansBulkDeleteNoContent{} +} + +/* WirelessWirelessLansBulkDeleteNoContent describes a response with status code 204, with default header values. + +WirelessWirelessLansBulkDeleteNoContent wireless wireless lans bulk delete no content +*/ +type WirelessWirelessLansBulkDeleteNoContent struct { +} + +func (o *WirelessWirelessLansBulkDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /wireless/wireless-lans/][%d] wirelessWirelessLansBulkDeleteNoContent ", 204) +} + +func (o *WirelessWirelessLansBulkDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_bulk_partial_update_parameters.go b/netbox/client/wireless/wireless_wireless_lans_bulk_partial_update_parameters.go new file mode 100644 index 00000000..4aaa37c5 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_bulk_partial_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLansBulkPartialUpdateParams creates a new WirelessWirelessLansBulkPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLansBulkPartialUpdateParams() *WirelessWirelessLansBulkPartialUpdateParams { + return &WirelessWirelessLansBulkPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLansBulkPartialUpdateParamsWithTimeout creates a new WirelessWirelessLansBulkPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLansBulkPartialUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLansBulkPartialUpdateParams { + return &WirelessWirelessLansBulkPartialUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLansBulkPartialUpdateParamsWithContext creates a new WirelessWirelessLansBulkPartialUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLansBulkPartialUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLansBulkPartialUpdateParams { + return &WirelessWirelessLansBulkPartialUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLansBulkPartialUpdateParamsWithHTTPClient creates a new WirelessWirelessLansBulkPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLansBulkPartialUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLansBulkPartialUpdateParams { + return &WirelessWirelessLansBulkPartialUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLansBulkPartialUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless lans bulk partial update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLansBulkPartialUpdateParams struct { + + // Data. + Data *models.WritableWirelessLAN + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lans bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansBulkPartialUpdateParams) WithDefaults() *WirelessWirelessLansBulkPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lans bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansBulkPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lans bulk partial update params +func (o *WirelessWirelessLansBulkPartialUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLansBulkPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lans bulk partial update params +func (o *WirelessWirelessLansBulkPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lans bulk partial update params +func (o *WirelessWirelessLansBulkPartialUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLansBulkPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lans bulk partial update params +func (o *WirelessWirelessLansBulkPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lans bulk partial update params +func (o *WirelessWirelessLansBulkPartialUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLansBulkPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lans bulk partial update params +func (o *WirelessWirelessLansBulkPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless lans bulk partial update params +func (o *WirelessWirelessLansBulkPartialUpdateParams) WithData(data *models.WritableWirelessLAN) *WirelessWirelessLansBulkPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless lans bulk partial update params +func (o *WirelessWirelessLansBulkPartialUpdateParams) SetData(data *models.WritableWirelessLAN) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLansBulkPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_bulk_partial_update_responses.go b/netbox/client/wireless/wireless_wireless_lans_bulk_partial_update_responses.go new file mode 100644 index 00000000..1829db3c --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_bulk_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLansBulkPartialUpdateReader is a Reader for the WirelessWirelessLansBulkPartialUpdate structure. +type WirelessWirelessLansBulkPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLansBulkPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLansBulkPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLansBulkPartialUpdateOK creates a WirelessWirelessLansBulkPartialUpdateOK with default headers values +func NewWirelessWirelessLansBulkPartialUpdateOK() *WirelessWirelessLansBulkPartialUpdateOK { + return &WirelessWirelessLansBulkPartialUpdateOK{} +} + +/* WirelessWirelessLansBulkPartialUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLansBulkPartialUpdateOK wireless wireless lans bulk partial update o k +*/ +type WirelessWirelessLansBulkPartialUpdateOK struct { + Payload *models.WirelessLAN +} + +func (o *WirelessWirelessLansBulkPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /wireless/wireless-lans/][%d] wirelessWirelessLansBulkPartialUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLansBulkPartialUpdateOK) GetPayload() *models.WirelessLAN { + return o.Payload +} + +func (o *WirelessWirelessLansBulkPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLAN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_bulk_update_parameters.go b/netbox/client/wireless/wireless_wireless_lans_bulk_update_parameters.go new file mode 100644 index 00000000..c80b27b2 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_bulk_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLansBulkUpdateParams creates a new WirelessWirelessLansBulkUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLansBulkUpdateParams() *WirelessWirelessLansBulkUpdateParams { + return &WirelessWirelessLansBulkUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLansBulkUpdateParamsWithTimeout creates a new WirelessWirelessLansBulkUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLansBulkUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLansBulkUpdateParams { + return &WirelessWirelessLansBulkUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLansBulkUpdateParamsWithContext creates a new WirelessWirelessLansBulkUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLansBulkUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLansBulkUpdateParams { + return &WirelessWirelessLansBulkUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLansBulkUpdateParamsWithHTTPClient creates a new WirelessWirelessLansBulkUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLansBulkUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLansBulkUpdateParams { + return &WirelessWirelessLansBulkUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLansBulkUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless lans bulk update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLansBulkUpdateParams struct { + + // Data. + Data *models.WritableWirelessLAN + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lans bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansBulkUpdateParams) WithDefaults() *WirelessWirelessLansBulkUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lans bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansBulkUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lans bulk update params +func (o *WirelessWirelessLansBulkUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLansBulkUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lans bulk update params +func (o *WirelessWirelessLansBulkUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lans bulk update params +func (o *WirelessWirelessLansBulkUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLansBulkUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lans bulk update params +func (o *WirelessWirelessLansBulkUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lans bulk update params +func (o *WirelessWirelessLansBulkUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLansBulkUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lans bulk update params +func (o *WirelessWirelessLansBulkUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless lans bulk update params +func (o *WirelessWirelessLansBulkUpdateParams) WithData(data *models.WritableWirelessLAN) *WirelessWirelessLansBulkUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless lans bulk update params +func (o *WirelessWirelessLansBulkUpdateParams) SetData(data *models.WritableWirelessLAN) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLansBulkUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_bulk_update_responses.go b/netbox/client/wireless/wireless_wireless_lans_bulk_update_responses.go new file mode 100644 index 00000000..5dbffdb8 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_bulk_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLansBulkUpdateReader is a Reader for the WirelessWirelessLansBulkUpdate structure. +type WirelessWirelessLansBulkUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLansBulkUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLansBulkUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLansBulkUpdateOK creates a WirelessWirelessLansBulkUpdateOK with default headers values +func NewWirelessWirelessLansBulkUpdateOK() *WirelessWirelessLansBulkUpdateOK { + return &WirelessWirelessLansBulkUpdateOK{} +} + +/* WirelessWirelessLansBulkUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLansBulkUpdateOK wireless wireless lans bulk update o k +*/ +type WirelessWirelessLansBulkUpdateOK struct { + Payload *models.WirelessLAN +} + +func (o *WirelessWirelessLansBulkUpdateOK) Error() string { + return fmt.Sprintf("[PUT /wireless/wireless-lans/][%d] wirelessWirelessLansBulkUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLansBulkUpdateOK) GetPayload() *models.WirelessLAN { + return o.Payload +} + +func (o *WirelessWirelessLansBulkUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLAN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_create_parameters.go b/netbox/client/wireless/wireless_wireless_lans_create_parameters.go new file mode 100644 index 00000000..c60786cf --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_create_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLansCreateParams creates a new WirelessWirelessLansCreateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLansCreateParams() *WirelessWirelessLansCreateParams { + return &WirelessWirelessLansCreateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLansCreateParamsWithTimeout creates a new WirelessWirelessLansCreateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLansCreateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLansCreateParams { + return &WirelessWirelessLansCreateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLansCreateParamsWithContext creates a new WirelessWirelessLansCreateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLansCreateParamsWithContext(ctx context.Context) *WirelessWirelessLansCreateParams { + return &WirelessWirelessLansCreateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLansCreateParamsWithHTTPClient creates a new WirelessWirelessLansCreateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLansCreateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLansCreateParams { + return &WirelessWirelessLansCreateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLansCreateParams contains all the parameters to send to the API endpoint + for the wireless wireless lans create operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLansCreateParams struct { + + // Data. + Data *models.WritableWirelessLAN + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lans create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansCreateParams) WithDefaults() *WirelessWirelessLansCreateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lans create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansCreateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lans create params +func (o *WirelessWirelessLansCreateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLansCreateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lans create params +func (o *WirelessWirelessLansCreateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lans create params +func (o *WirelessWirelessLansCreateParams) WithContext(ctx context.Context) *WirelessWirelessLansCreateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lans create params +func (o *WirelessWirelessLansCreateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lans create params +func (o *WirelessWirelessLansCreateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLansCreateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lans create params +func (o *WirelessWirelessLansCreateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless lans create params +func (o *WirelessWirelessLansCreateParams) WithData(data *models.WritableWirelessLAN) *WirelessWirelessLansCreateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless lans create params +func (o *WirelessWirelessLansCreateParams) SetData(data *models.WritableWirelessLAN) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLansCreateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_create_responses.go b/netbox/client/wireless/wireless_wireless_lans_create_responses.go new file mode 100644 index 00000000..93e5c564 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_create_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLansCreateReader is a Reader for the WirelessWirelessLansCreate structure. +type WirelessWirelessLansCreateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLansCreateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 201: + result := NewWirelessWirelessLansCreateCreated() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLansCreateCreated creates a WirelessWirelessLansCreateCreated with default headers values +func NewWirelessWirelessLansCreateCreated() *WirelessWirelessLansCreateCreated { + return &WirelessWirelessLansCreateCreated{} +} + +/* WirelessWirelessLansCreateCreated describes a response with status code 201, with default header values. + +WirelessWirelessLansCreateCreated wireless wireless lans create created +*/ +type WirelessWirelessLansCreateCreated struct { + Payload *models.WirelessLAN +} + +func (o *WirelessWirelessLansCreateCreated) Error() string { + return fmt.Sprintf("[POST /wireless/wireless-lans/][%d] wirelessWirelessLansCreateCreated %+v", 201, o.Payload) +} +func (o *WirelessWirelessLansCreateCreated) GetPayload() *models.WirelessLAN { + return o.Payload +} + +func (o *WirelessWirelessLansCreateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLAN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_delete_parameters.go b/netbox/client/wireless/wireless_wireless_lans_delete_parameters.go new file mode 100644 index 00000000..772cabbe --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_delete_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewWirelessWirelessLansDeleteParams creates a new WirelessWirelessLansDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLansDeleteParams() *WirelessWirelessLansDeleteParams { + return &WirelessWirelessLansDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLansDeleteParamsWithTimeout creates a new WirelessWirelessLansDeleteParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLansDeleteParamsWithTimeout(timeout time.Duration) *WirelessWirelessLansDeleteParams { + return &WirelessWirelessLansDeleteParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLansDeleteParamsWithContext creates a new WirelessWirelessLansDeleteParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLansDeleteParamsWithContext(ctx context.Context) *WirelessWirelessLansDeleteParams { + return &WirelessWirelessLansDeleteParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLansDeleteParamsWithHTTPClient creates a new WirelessWirelessLansDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLansDeleteParamsWithHTTPClient(client *http.Client) *WirelessWirelessLansDeleteParams { + return &WirelessWirelessLansDeleteParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLansDeleteParams contains all the parameters to send to the API endpoint + for the wireless wireless lans delete operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLansDeleteParams struct { + + /* ID. + + A unique integer value identifying this Wireless LAN. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lans delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansDeleteParams) WithDefaults() *WirelessWirelessLansDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lans delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lans delete params +func (o *WirelessWirelessLansDeleteParams) WithTimeout(timeout time.Duration) *WirelessWirelessLansDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lans delete params +func (o *WirelessWirelessLansDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lans delete params +func (o *WirelessWirelessLansDeleteParams) WithContext(ctx context.Context) *WirelessWirelessLansDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lans delete params +func (o *WirelessWirelessLansDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lans delete params +func (o *WirelessWirelessLansDeleteParams) WithHTTPClient(client *http.Client) *WirelessWirelessLansDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lans delete params +func (o *WirelessWirelessLansDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the wireless wireless lans delete params +func (o *WirelessWirelessLansDeleteParams) WithID(id int64) *WirelessWirelessLansDeleteParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless lans delete params +func (o *WirelessWirelessLansDeleteParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLansDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_delete_responses.go b/netbox/client/wireless/wireless_wireless_lans_delete_responses.go new file mode 100644 index 00000000..2735e2c4 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// WirelessWirelessLansDeleteReader is a Reader for the WirelessWirelessLansDelete structure. +type WirelessWirelessLansDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLansDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewWirelessWirelessLansDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLansDeleteNoContent creates a WirelessWirelessLansDeleteNoContent with default headers values +func NewWirelessWirelessLansDeleteNoContent() *WirelessWirelessLansDeleteNoContent { + return &WirelessWirelessLansDeleteNoContent{} +} + +/* WirelessWirelessLansDeleteNoContent describes a response with status code 204, with default header values. + +WirelessWirelessLansDeleteNoContent wireless wireless lans delete no content +*/ +type WirelessWirelessLansDeleteNoContent struct { +} + +func (o *WirelessWirelessLansDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /wireless/wireless-lans/{id}/][%d] wirelessWirelessLansDeleteNoContent ", 204) +} + +func (o *WirelessWirelessLansDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_list_parameters.go b/netbox/client/wireless/wireless_wireless_lans_list_parameters.go new file mode 100644 index 00000000..6a3f2cd9 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_list_parameters.go @@ -0,0 +1,2009 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewWirelessWirelessLansListParams creates a new WirelessWirelessLansListParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLansListParams() *WirelessWirelessLansListParams { + return &WirelessWirelessLansListParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLansListParamsWithTimeout creates a new WirelessWirelessLansListParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLansListParamsWithTimeout(timeout time.Duration) *WirelessWirelessLansListParams { + return &WirelessWirelessLansListParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLansListParamsWithContext creates a new WirelessWirelessLansListParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLansListParamsWithContext(ctx context.Context) *WirelessWirelessLansListParams { + return &WirelessWirelessLansListParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLansListParamsWithHTTPClient creates a new WirelessWirelessLansListParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLansListParamsWithHTTPClient(client *http.Client) *WirelessWirelessLansListParams { + return &WirelessWirelessLansListParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLansListParams contains all the parameters to send to the API endpoint + for the wireless wireless lans list operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLansListParams struct { + + // AuthCipher. + AuthCipher *string + + // AuthCiphern. + AuthCiphern *string + + // AuthPsk. + AuthPsk *string + + // AuthPskEmpty. + AuthPskEmpty *string + + // AuthPskIc. + AuthPskIc *string + + // AuthPskIe. + AuthPskIe *string + + // AuthPskIew. + AuthPskIew *string + + // AuthPskIsw. + AuthPskIsw *string + + // AuthPskn. + AuthPskn *string + + // AuthPskNic. + AuthPskNic *string + + // AuthPskNie. + AuthPskNie *string + + // AuthPskNiew. + AuthPskNiew *string + + // AuthPskNisw. + AuthPskNisw *string + + // AuthType. + AuthType *string + + // AuthTypen. + AuthTypen *string + + // Created. + Created *string + + // CreatedGte. + CreatedGte *string + + // CreatedLte. + CreatedLte *string + + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + + // Group. + Group *string + + // Groupn. + Groupn *string + + // GroupID. + GroupID *string + + // GroupIDn. + GroupIDn *string + + // ID. + ID *string + + // IDGt. + IDGt *string + + // IDGte. + IDGte *string + + // IDLt. + IDLt *string + + // IDLte. + IDLte *string + + // IDn. + IDn *string + + // LastUpdated. + LastUpdated *string + + // LastUpdatedGte. + LastUpdatedGte *string + + // LastUpdatedLte. + LastUpdatedLte *string + + /* Limit. + + Number of results to return per page. + */ + Limit *int64 + + /* Offset. + + The initial index from which to return the results. + */ + Offset *int64 + + // Q. + Q *string + + // Ssid. + Ssid *string + + // SsidEmpty. + SsidEmpty *string + + // SsidIc. + SsidIc *string + + // SsidIe. + SsidIe *string + + // SsidIew. + SsidIew *string + + // SsidIsw. + SsidIsw *string + + // Ssidn. + Ssidn *string + + // SsidNic. + SsidNic *string + + // SsidNie. + SsidNie *string + + // SsidNiew. + SsidNiew *string + + // SsidNisw. + SsidNisw *string + + // Tag. + Tag *string + + // Tagn. + Tagn *string + + // VlanID. + VlanID *string + + // VlanIDn. + VlanIDn *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lans list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansListParams) WithDefaults() *WirelessWirelessLansListParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lans list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansListParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithTimeout(timeout time.Duration) *WirelessWirelessLansListParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithContext(ctx context.Context) *WirelessWirelessLansListParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithHTTPClient(client *http.Client) *WirelessWirelessLansListParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAuthCipher adds the authCipher to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthCipher(authCipher *string) *WirelessWirelessLansListParams { + o.SetAuthCipher(authCipher) + return o +} + +// SetAuthCipher adds the authCipher to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthCipher(authCipher *string) { + o.AuthCipher = authCipher +} + +// WithAuthCiphern adds the authCiphern to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthCiphern(authCiphern *string) *WirelessWirelessLansListParams { + o.SetAuthCiphern(authCiphern) + return o +} + +// SetAuthCiphern adds the authCipherN to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthCiphern(authCiphern *string) { + o.AuthCiphern = authCiphern +} + +// WithAuthPsk adds the authPsk to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthPsk(authPsk *string) *WirelessWirelessLansListParams { + o.SetAuthPsk(authPsk) + return o +} + +// SetAuthPsk adds the authPsk to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthPsk(authPsk *string) { + o.AuthPsk = authPsk +} + +// WithAuthPskEmpty adds the authPskEmpty to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthPskEmpty(authPskEmpty *string) *WirelessWirelessLansListParams { + o.SetAuthPskEmpty(authPskEmpty) + return o +} + +// SetAuthPskEmpty adds the authPskEmpty to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthPskEmpty(authPskEmpty *string) { + o.AuthPskEmpty = authPskEmpty +} + +// WithAuthPskIc adds the authPskIc to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthPskIc(authPskIc *string) *WirelessWirelessLansListParams { + o.SetAuthPskIc(authPskIc) + return o +} + +// SetAuthPskIc adds the authPskIc to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthPskIc(authPskIc *string) { + o.AuthPskIc = authPskIc +} + +// WithAuthPskIe adds the authPskIe to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthPskIe(authPskIe *string) *WirelessWirelessLansListParams { + o.SetAuthPskIe(authPskIe) + return o +} + +// SetAuthPskIe adds the authPskIe to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthPskIe(authPskIe *string) { + o.AuthPskIe = authPskIe +} + +// WithAuthPskIew adds the authPskIew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthPskIew(authPskIew *string) *WirelessWirelessLansListParams { + o.SetAuthPskIew(authPskIew) + return o +} + +// SetAuthPskIew adds the authPskIew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthPskIew(authPskIew *string) { + o.AuthPskIew = authPskIew +} + +// WithAuthPskIsw adds the authPskIsw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthPskIsw(authPskIsw *string) *WirelessWirelessLansListParams { + o.SetAuthPskIsw(authPskIsw) + return o +} + +// SetAuthPskIsw adds the authPskIsw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthPskIsw(authPskIsw *string) { + o.AuthPskIsw = authPskIsw +} + +// WithAuthPskn adds the authPskn to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthPskn(authPskn *string) *WirelessWirelessLansListParams { + o.SetAuthPskn(authPskn) + return o +} + +// SetAuthPskn adds the authPskN to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthPskn(authPskn *string) { + o.AuthPskn = authPskn +} + +// WithAuthPskNic adds the authPskNic to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthPskNic(authPskNic *string) *WirelessWirelessLansListParams { + o.SetAuthPskNic(authPskNic) + return o +} + +// SetAuthPskNic adds the authPskNic to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthPskNic(authPskNic *string) { + o.AuthPskNic = authPskNic +} + +// WithAuthPskNie adds the authPskNie to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthPskNie(authPskNie *string) *WirelessWirelessLansListParams { + o.SetAuthPskNie(authPskNie) + return o +} + +// SetAuthPskNie adds the authPskNie to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthPskNie(authPskNie *string) { + o.AuthPskNie = authPskNie +} + +// WithAuthPskNiew adds the authPskNiew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthPskNiew(authPskNiew *string) *WirelessWirelessLansListParams { + o.SetAuthPskNiew(authPskNiew) + return o +} + +// SetAuthPskNiew adds the authPskNiew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthPskNiew(authPskNiew *string) { + o.AuthPskNiew = authPskNiew +} + +// WithAuthPskNisw adds the authPskNisw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthPskNisw(authPskNisw *string) *WirelessWirelessLansListParams { + o.SetAuthPskNisw(authPskNisw) + return o +} + +// SetAuthPskNisw adds the authPskNisw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthPskNisw(authPskNisw *string) { + o.AuthPskNisw = authPskNisw +} + +// WithAuthType adds the authType to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthType(authType *string) *WirelessWirelessLansListParams { + o.SetAuthType(authType) + return o +} + +// SetAuthType adds the authType to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthType(authType *string) { + o.AuthType = authType +} + +// WithAuthTypen adds the authTypen to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithAuthTypen(authTypen *string) *WirelessWirelessLansListParams { + o.SetAuthTypen(authTypen) + return o +} + +// SetAuthTypen adds the authTypeN to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetAuthTypen(authTypen *string) { + o.AuthTypen = authTypen +} + +// WithCreated adds the created to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithCreated(created *string) *WirelessWirelessLansListParams { + o.SetCreated(created) + return o +} + +// SetCreated adds the created to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetCreated(created *string) { + o.Created = created +} + +// WithCreatedGte adds the createdGte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithCreatedGte(createdGte *string) *WirelessWirelessLansListParams { + o.SetCreatedGte(createdGte) + return o +} + +// SetCreatedGte adds the createdGte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetCreatedGte(createdGte *string) { + o.CreatedGte = createdGte +} + +// WithCreatedLte adds the createdLte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithCreatedLte(createdLte *string) *WirelessWirelessLansListParams { + o.SetCreatedLte(createdLte) + return o +} + +// SetCreatedLte adds the createdLte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetCreatedLte(createdLte *string) { + o.CreatedLte = createdLte +} + +// WithDescription adds the description to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithDescription(description *string) *WirelessWirelessLansListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithDescriptionEmpty(descriptionEmpty *string) *WirelessWirelessLansListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithDescriptionIc(descriptionIc *string) *WirelessWirelessLansListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithDescriptionIe(descriptionIe *string) *WirelessWirelessLansListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithDescriptionIew(descriptionIew *string) *WirelessWirelessLansListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithDescriptionIsw(descriptionIsw *string) *WirelessWirelessLansListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithDescriptionn(descriptionn *string) *WirelessWirelessLansListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithDescriptionNic(descriptionNic *string) *WirelessWirelessLansListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithDescriptionNie(descriptionNie *string) *WirelessWirelessLansListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithDescriptionNiew(descriptionNiew *string) *WirelessWirelessLansListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithDescriptionNisw(descriptionNisw *string) *WirelessWirelessLansListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + +// WithGroup adds the group to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithGroup(group *string) *WirelessWirelessLansListParams { + o.SetGroup(group) + return o +} + +// SetGroup adds the group to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetGroup(group *string) { + o.Group = group +} + +// WithGroupn adds the groupn to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithGroupn(groupn *string) *WirelessWirelessLansListParams { + o.SetGroupn(groupn) + return o +} + +// SetGroupn adds the groupN to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetGroupn(groupn *string) { + o.Groupn = groupn +} + +// WithGroupID adds the groupID to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithGroupID(groupID *string) *WirelessWirelessLansListParams { + o.SetGroupID(groupID) + return o +} + +// SetGroupID adds the groupId to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetGroupID(groupID *string) { + o.GroupID = groupID +} + +// WithGroupIDn adds the groupIDn to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithGroupIDn(groupIDn *string) *WirelessWirelessLansListParams { + o.SetGroupIDn(groupIDn) + return o +} + +// SetGroupIDn adds the groupIdN to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetGroupIDn(groupIDn *string) { + o.GroupIDn = groupIDn +} + +// WithID adds the id to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithID(id *string) *WirelessWirelessLansListParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetID(id *string) { + o.ID = id +} + +// WithIDGt adds the iDGt to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithIDGt(iDGt *string) *WirelessWirelessLansListParams { + o.SetIDGt(iDGt) + return o +} + +// SetIDGt adds the idGt to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetIDGt(iDGt *string) { + o.IDGt = iDGt +} + +// WithIDGte adds the iDGte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithIDGte(iDGte *string) *WirelessWirelessLansListParams { + o.SetIDGte(iDGte) + return o +} + +// SetIDGte adds the idGte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetIDGte(iDGte *string) { + o.IDGte = iDGte +} + +// WithIDLt adds the iDLt to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithIDLt(iDLt *string) *WirelessWirelessLansListParams { + o.SetIDLt(iDLt) + return o +} + +// SetIDLt adds the idLt to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetIDLt(iDLt *string) { + o.IDLt = iDLt +} + +// WithIDLte adds the iDLte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithIDLte(iDLte *string) *WirelessWirelessLansListParams { + o.SetIDLte(iDLte) + return o +} + +// SetIDLte adds the idLte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetIDLte(iDLte *string) { + o.IDLte = iDLte +} + +// WithIDn adds the iDn to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithIDn(iDn *string) *WirelessWirelessLansListParams { + o.SetIDn(iDn) + return o +} + +// SetIDn adds the idN to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetIDn(iDn *string) { + o.IDn = iDn +} + +// WithLastUpdated adds the lastUpdated to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithLastUpdated(lastUpdated *string) *WirelessWirelessLansListParams { + o.SetLastUpdated(lastUpdated) + return o +} + +// SetLastUpdated adds the lastUpdated to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetLastUpdated(lastUpdated *string) { + o.LastUpdated = lastUpdated +} + +// WithLastUpdatedGte adds the lastUpdatedGte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithLastUpdatedGte(lastUpdatedGte *string) *WirelessWirelessLansListParams { + o.SetLastUpdatedGte(lastUpdatedGte) + return o +} + +// SetLastUpdatedGte adds the lastUpdatedGte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetLastUpdatedGte(lastUpdatedGte *string) { + o.LastUpdatedGte = lastUpdatedGte +} + +// WithLastUpdatedLte adds the lastUpdatedLte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithLastUpdatedLte(lastUpdatedLte *string) *WirelessWirelessLansListParams { + o.SetLastUpdatedLte(lastUpdatedLte) + return o +} + +// SetLastUpdatedLte adds the lastUpdatedLte to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetLastUpdatedLte(lastUpdatedLte *string) { + o.LastUpdatedLte = lastUpdatedLte +} + +// WithLimit adds the limit to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithLimit(limit *int64) *WirelessWirelessLansListParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithOffset(offset *int64) *WirelessWirelessLansListParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithQ adds the q to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithQ(q *string) *WirelessWirelessLansListParams { + o.SetQ(q) + return o +} + +// SetQ adds the q to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetQ(q *string) { + o.Q = q +} + +// WithSsid adds the ssid to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithSsid(ssid *string) *WirelessWirelessLansListParams { + o.SetSsid(ssid) + return o +} + +// SetSsid adds the ssid to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetSsid(ssid *string) { + o.Ssid = ssid +} + +// WithSsidEmpty adds the ssidEmpty to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithSsidEmpty(ssidEmpty *string) *WirelessWirelessLansListParams { + o.SetSsidEmpty(ssidEmpty) + return o +} + +// SetSsidEmpty adds the ssidEmpty to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetSsidEmpty(ssidEmpty *string) { + o.SsidEmpty = ssidEmpty +} + +// WithSsidIc adds the ssidIc to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithSsidIc(ssidIc *string) *WirelessWirelessLansListParams { + o.SetSsidIc(ssidIc) + return o +} + +// SetSsidIc adds the ssidIc to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetSsidIc(ssidIc *string) { + o.SsidIc = ssidIc +} + +// WithSsidIe adds the ssidIe to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithSsidIe(ssidIe *string) *WirelessWirelessLansListParams { + o.SetSsidIe(ssidIe) + return o +} + +// SetSsidIe adds the ssidIe to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetSsidIe(ssidIe *string) { + o.SsidIe = ssidIe +} + +// WithSsidIew adds the ssidIew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithSsidIew(ssidIew *string) *WirelessWirelessLansListParams { + o.SetSsidIew(ssidIew) + return o +} + +// SetSsidIew adds the ssidIew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetSsidIew(ssidIew *string) { + o.SsidIew = ssidIew +} + +// WithSsidIsw adds the ssidIsw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithSsidIsw(ssidIsw *string) *WirelessWirelessLansListParams { + o.SetSsidIsw(ssidIsw) + return o +} + +// SetSsidIsw adds the ssidIsw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetSsidIsw(ssidIsw *string) { + o.SsidIsw = ssidIsw +} + +// WithSsidn adds the ssidn to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithSsidn(ssidn *string) *WirelessWirelessLansListParams { + o.SetSsidn(ssidn) + return o +} + +// SetSsidn adds the ssidN to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetSsidn(ssidn *string) { + o.Ssidn = ssidn +} + +// WithSsidNic adds the ssidNic to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithSsidNic(ssidNic *string) *WirelessWirelessLansListParams { + o.SetSsidNic(ssidNic) + return o +} + +// SetSsidNic adds the ssidNic to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetSsidNic(ssidNic *string) { + o.SsidNic = ssidNic +} + +// WithSsidNie adds the ssidNie to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithSsidNie(ssidNie *string) *WirelessWirelessLansListParams { + o.SetSsidNie(ssidNie) + return o +} + +// SetSsidNie adds the ssidNie to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetSsidNie(ssidNie *string) { + o.SsidNie = ssidNie +} + +// WithSsidNiew adds the ssidNiew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithSsidNiew(ssidNiew *string) *WirelessWirelessLansListParams { + o.SetSsidNiew(ssidNiew) + return o +} + +// SetSsidNiew adds the ssidNiew to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetSsidNiew(ssidNiew *string) { + o.SsidNiew = ssidNiew +} + +// WithSsidNisw adds the ssidNisw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithSsidNisw(ssidNisw *string) *WirelessWirelessLansListParams { + o.SetSsidNisw(ssidNisw) + return o +} + +// SetSsidNisw adds the ssidNisw to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetSsidNisw(ssidNisw *string) { + o.SsidNisw = ssidNisw +} + +// WithTag adds the tag to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithTag(tag *string) *WirelessWirelessLansListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithTagn(tagn *string) *WirelessWirelessLansListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + +// WithVlanID adds the vlanID to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithVlanID(vlanID *string) *WirelessWirelessLansListParams { + o.SetVlanID(vlanID) + return o +} + +// SetVlanID adds the vlanId to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetVlanID(vlanID *string) { + o.VlanID = vlanID +} + +// WithVlanIDn adds the vlanIDn to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) WithVlanIDn(vlanIDn *string) *WirelessWirelessLansListParams { + o.SetVlanIDn(vlanIDn) + return o +} + +// SetVlanIDn adds the vlanIdN to the wireless wireless lans list params +func (o *WirelessWirelessLansListParams) SetVlanIDn(vlanIDn *string) { + o.VlanIDn = vlanIDn +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLansListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.AuthCipher != nil { + + // query param auth_cipher + var qrAuthCipher string + + if o.AuthCipher != nil { + qrAuthCipher = *o.AuthCipher + } + qAuthCipher := qrAuthCipher + if qAuthCipher != "" { + + if err := r.SetQueryParam("auth_cipher", qAuthCipher); err != nil { + return err + } + } + } + + if o.AuthCiphern != nil { + + // query param auth_cipher__n + var qrAuthCiphern string + + if o.AuthCiphern != nil { + qrAuthCiphern = *o.AuthCiphern + } + qAuthCiphern := qrAuthCiphern + if qAuthCiphern != "" { + + if err := r.SetQueryParam("auth_cipher__n", qAuthCiphern); err != nil { + return err + } + } + } + + if o.AuthPsk != nil { + + // query param auth_psk + var qrAuthPsk string + + if o.AuthPsk != nil { + qrAuthPsk = *o.AuthPsk + } + qAuthPsk := qrAuthPsk + if qAuthPsk != "" { + + if err := r.SetQueryParam("auth_psk", qAuthPsk); err != nil { + return err + } + } + } + + if o.AuthPskEmpty != nil { + + // query param auth_psk__empty + var qrAuthPskEmpty string + + if o.AuthPskEmpty != nil { + qrAuthPskEmpty = *o.AuthPskEmpty + } + qAuthPskEmpty := qrAuthPskEmpty + if qAuthPskEmpty != "" { + + if err := r.SetQueryParam("auth_psk__empty", qAuthPskEmpty); err != nil { + return err + } + } + } + + if o.AuthPskIc != nil { + + // query param auth_psk__ic + var qrAuthPskIc string + + if o.AuthPskIc != nil { + qrAuthPskIc = *o.AuthPskIc + } + qAuthPskIc := qrAuthPskIc + if qAuthPskIc != "" { + + if err := r.SetQueryParam("auth_psk__ic", qAuthPskIc); err != nil { + return err + } + } + } + + if o.AuthPskIe != nil { + + // query param auth_psk__ie + var qrAuthPskIe string + + if o.AuthPskIe != nil { + qrAuthPskIe = *o.AuthPskIe + } + qAuthPskIe := qrAuthPskIe + if qAuthPskIe != "" { + + if err := r.SetQueryParam("auth_psk__ie", qAuthPskIe); err != nil { + return err + } + } + } + + if o.AuthPskIew != nil { + + // query param auth_psk__iew + var qrAuthPskIew string + + if o.AuthPskIew != nil { + qrAuthPskIew = *o.AuthPskIew + } + qAuthPskIew := qrAuthPskIew + if qAuthPskIew != "" { + + if err := r.SetQueryParam("auth_psk__iew", qAuthPskIew); err != nil { + return err + } + } + } + + if o.AuthPskIsw != nil { + + // query param auth_psk__isw + var qrAuthPskIsw string + + if o.AuthPskIsw != nil { + qrAuthPskIsw = *o.AuthPskIsw + } + qAuthPskIsw := qrAuthPskIsw + if qAuthPskIsw != "" { + + if err := r.SetQueryParam("auth_psk__isw", qAuthPskIsw); err != nil { + return err + } + } + } + + if o.AuthPskn != nil { + + // query param auth_psk__n + var qrAuthPskn string + + if o.AuthPskn != nil { + qrAuthPskn = *o.AuthPskn + } + qAuthPskn := qrAuthPskn + if qAuthPskn != "" { + + if err := r.SetQueryParam("auth_psk__n", qAuthPskn); err != nil { + return err + } + } + } + + if o.AuthPskNic != nil { + + // query param auth_psk__nic + var qrAuthPskNic string + + if o.AuthPskNic != nil { + qrAuthPskNic = *o.AuthPskNic + } + qAuthPskNic := qrAuthPskNic + if qAuthPskNic != "" { + + if err := r.SetQueryParam("auth_psk__nic", qAuthPskNic); err != nil { + return err + } + } + } + + if o.AuthPskNie != nil { + + // query param auth_psk__nie + var qrAuthPskNie string + + if o.AuthPskNie != nil { + qrAuthPskNie = *o.AuthPskNie + } + qAuthPskNie := qrAuthPskNie + if qAuthPskNie != "" { + + if err := r.SetQueryParam("auth_psk__nie", qAuthPskNie); err != nil { + return err + } + } + } + + if o.AuthPskNiew != nil { + + // query param auth_psk__niew + var qrAuthPskNiew string + + if o.AuthPskNiew != nil { + qrAuthPskNiew = *o.AuthPskNiew + } + qAuthPskNiew := qrAuthPskNiew + if qAuthPskNiew != "" { + + if err := r.SetQueryParam("auth_psk__niew", qAuthPskNiew); err != nil { + return err + } + } + } + + if o.AuthPskNisw != nil { + + // query param auth_psk__nisw + var qrAuthPskNisw string + + if o.AuthPskNisw != nil { + qrAuthPskNisw = *o.AuthPskNisw + } + qAuthPskNisw := qrAuthPskNisw + if qAuthPskNisw != "" { + + if err := r.SetQueryParam("auth_psk__nisw", qAuthPskNisw); err != nil { + return err + } + } + } + + if o.AuthType != nil { + + // query param auth_type + var qrAuthType string + + if o.AuthType != nil { + qrAuthType = *o.AuthType + } + qAuthType := qrAuthType + if qAuthType != "" { + + if err := r.SetQueryParam("auth_type", qAuthType); err != nil { + return err + } + } + } + + if o.AuthTypen != nil { + + // query param auth_type__n + var qrAuthTypen string + + if o.AuthTypen != nil { + qrAuthTypen = *o.AuthTypen + } + qAuthTypen := qrAuthTypen + if qAuthTypen != "" { + + if err := r.SetQueryParam("auth_type__n", qAuthTypen); err != nil { + return err + } + } + } + + if o.Created != nil { + + // query param created + var qrCreated string + + if o.Created != nil { + qrCreated = *o.Created + } + qCreated := qrCreated + if qCreated != "" { + + if err := r.SetQueryParam("created", qCreated); err != nil { + return err + } + } + } + + if o.CreatedGte != nil { + + // query param created__gte + var qrCreatedGte string + + if o.CreatedGte != nil { + qrCreatedGte = *o.CreatedGte + } + qCreatedGte := qrCreatedGte + if qCreatedGte != "" { + + if err := r.SetQueryParam("created__gte", qCreatedGte); err != nil { + return err + } + } + } + + if o.CreatedLte != nil { + + // query param created__lte + var qrCreatedLte string + + if o.CreatedLte != nil { + qrCreatedLte = *o.CreatedLte + } + qCreatedLte := qrCreatedLte + if qCreatedLte != "" { + + if err := r.SetQueryParam("created__lte", qCreatedLte); err != nil { + return err + } + } + } + + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + + if o.Group != nil { + + // query param group + var qrGroup string + + if o.Group != nil { + qrGroup = *o.Group + } + qGroup := qrGroup + if qGroup != "" { + + if err := r.SetQueryParam("group", qGroup); err != nil { + return err + } + } + } + + if o.Groupn != nil { + + // query param group__n + var qrGroupn string + + if o.Groupn != nil { + qrGroupn = *o.Groupn + } + qGroupn := qrGroupn + if qGroupn != "" { + + if err := r.SetQueryParam("group__n", qGroupn); err != nil { + return err + } + } + } + + if o.GroupID != nil { + + // query param group_id + var qrGroupID string + + if o.GroupID != nil { + qrGroupID = *o.GroupID + } + qGroupID := qrGroupID + if qGroupID != "" { + + if err := r.SetQueryParam("group_id", qGroupID); err != nil { + return err + } + } + } + + if o.GroupIDn != nil { + + // query param group_id__n + var qrGroupIDn string + + if o.GroupIDn != nil { + qrGroupIDn = *o.GroupIDn + } + qGroupIDn := qrGroupIDn + if qGroupIDn != "" { + + if err := r.SetQueryParam("group_id__n", qGroupIDn); err != nil { + return err + } + } + } + + if o.ID != nil { + + // query param id + var qrID string + + if o.ID != nil { + qrID = *o.ID + } + qID := qrID + if qID != "" { + + if err := r.SetQueryParam("id", qID); err != nil { + return err + } + } + } + + if o.IDGt != nil { + + // query param id__gt + var qrIDGt string + + if o.IDGt != nil { + qrIDGt = *o.IDGt + } + qIDGt := qrIDGt + if qIDGt != "" { + + if err := r.SetQueryParam("id__gt", qIDGt); err != nil { + return err + } + } + } + + if o.IDGte != nil { + + // query param id__gte + var qrIDGte string + + if o.IDGte != nil { + qrIDGte = *o.IDGte + } + qIDGte := qrIDGte + if qIDGte != "" { + + if err := r.SetQueryParam("id__gte", qIDGte); err != nil { + return err + } + } + } + + if o.IDLt != nil { + + // query param id__lt + var qrIDLt string + + if o.IDLt != nil { + qrIDLt = *o.IDLt + } + qIDLt := qrIDLt + if qIDLt != "" { + + if err := r.SetQueryParam("id__lt", qIDLt); err != nil { + return err + } + } + } + + if o.IDLte != nil { + + // query param id__lte + var qrIDLte string + + if o.IDLte != nil { + qrIDLte = *o.IDLte + } + qIDLte := qrIDLte + if qIDLte != "" { + + if err := r.SetQueryParam("id__lte", qIDLte); err != nil { + return err + } + } + } + + if o.IDn != nil { + + // query param id__n + var qrIDn string + + if o.IDn != nil { + qrIDn = *o.IDn + } + qIDn := qrIDn + if qIDn != "" { + + if err := r.SetQueryParam("id__n", qIDn); err != nil { + return err + } + } + } + + if o.LastUpdated != nil { + + // query param last_updated + var qrLastUpdated string + + if o.LastUpdated != nil { + qrLastUpdated = *o.LastUpdated + } + qLastUpdated := qrLastUpdated + if qLastUpdated != "" { + + if err := r.SetQueryParam("last_updated", qLastUpdated); err != nil { + return err + } + } + } + + if o.LastUpdatedGte != nil { + + // query param last_updated__gte + var qrLastUpdatedGte string + + if o.LastUpdatedGte != nil { + qrLastUpdatedGte = *o.LastUpdatedGte + } + qLastUpdatedGte := qrLastUpdatedGte + if qLastUpdatedGte != "" { + + if err := r.SetQueryParam("last_updated__gte", qLastUpdatedGte); err != nil { + return err + } + } + } + + if o.LastUpdatedLte != nil { + + // query param last_updated__lte + var qrLastUpdatedLte string + + if o.LastUpdatedLte != nil { + qrLastUpdatedLte = *o.LastUpdatedLte + } + qLastUpdatedLte := qrLastUpdatedLte + if qLastUpdatedLte != "" { + + if err := r.SetQueryParam("last_updated__lte", qLastUpdatedLte); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.Q != nil { + + // query param q + var qrQ string + + if o.Q != nil { + qrQ = *o.Q + } + qQ := qrQ + if qQ != "" { + + if err := r.SetQueryParam("q", qQ); err != nil { + return err + } + } + } + + if o.Ssid != nil { + + // query param ssid + var qrSsid string + + if o.Ssid != nil { + qrSsid = *o.Ssid + } + qSsid := qrSsid + if qSsid != "" { + + if err := r.SetQueryParam("ssid", qSsid); err != nil { + return err + } + } + } + + if o.SsidEmpty != nil { + + // query param ssid__empty + var qrSsidEmpty string + + if o.SsidEmpty != nil { + qrSsidEmpty = *o.SsidEmpty + } + qSsidEmpty := qrSsidEmpty + if qSsidEmpty != "" { + + if err := r.SetQueryParam("ssid__empty", qSsidEmpty); err != nil { + return err + } + } + } + + if o.SsidIc != nil { + + // query param ssid__ic + var qrSsidIc string + + if o.SsidIc != nil { + qrSsidIc = *o.SsidIc + } + qSsidIc := qrSsidIc + if qSsidIc != "" { + + if err := r.SetQueryParam("ssid__ic", qSsidIc); err != nil { + return err + } + } + } + + if o.SsidIe != nil { + + // query param ssid__ie + var qrSsidIe string + + if o.SsidIe != nil { + qrSsidIe = *o.SsidIe + } + qSsidIe := qrSsidIe + if qSsidIe != "" { + + if err := r.SetQueryParam("ssid__ie", qSsidIe); err != nil { + return err + } + } + } + + if o.SsidIew != nil { + + // query param ssid__iew + var qrSsidIew string + + if o.SsidIew != nil { + qrSsidIew = *o.SsidIew + } + qSsidIew := qrSsidIew + if qSsidIew != "" { + + if err := r.SetQueryParam("ssid__iew", qSsidIew); err != nil { + return err + } + } + } + + if o.SsidIsw != nil { + + // query param ssid__isw + var qrSsidIsw string + + if o.SsidIsw != nil { + qrSsidIsw = *o.SsidIsw + } + qSsidIsw := qrSsidIsw + if qSsidIsw != "" { + + if err := r.SetQueryParam("ssid__isw", qSsidIsw); err != nil { + return err + } + } + } + + if o.Ssidn != nil { + + // query param ssid__n + var qrSsidn string + + if o.Ssidn != nil { + qrSsidn = *o.Ssidn + } + qSsidn := qrSsidn + if qSsidn != "" { + + if err := r.SetQueryParam("ssid__n", qSsidn); err != nil { + return err + } + } + } + + if o.SsidNic != nil { + + // query param ssid__nic + var qrSsidNic string + + if o.SsidNic != nil { + qrSsidNic = *o.SsidNic + } + qSsidNic := qrSsidNic + if qSsidNic != "" { + + if err := r.SetQueryParam("ssid__nic", qSsidNic); err != nil { + return err + } + } + } + + if o.SsidNie != nil { + + // query param ssid__nie + var qrSsidNie string + + if o.SsidNie != nil { + qrSsidNie = *o.SsidNie + } + qSsidNie := qrSsidNie + if qSsidNie != "" { + + if err := r.SetQueryParam("ssid__nie", qSsidNie); err != nil { + return err + } + } + } + + if o.SsidNiew != nil { + + // query param ssid__niew + var qrSsidNiew string + + if o.SsidNiew != nil { + qrSsidNiew = *o.SsidNiew + } + qSsidNiew := qrSsidNiew + if qSsidNiew != "" { + + if err := r.SetQueryParam("ssid__niew", qSsidNiew); err != nil { + return err + } + } + } + + if o.SsidNisw != nil { + + // query param ssid__nisw + var qrSsidNisw string + + if o.SsidNisw != nil { + qrSsidNisw = *o.SsidNisw + } + qSsidNisw := qrSsidNisw + if qSsidNisw != "" { + + if err := r.SetQueryParam("ssid__nisw", qSsidNisw); err != nil { + return err + } + } + } + + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + + if o.VlanID != nil { + + // query param vlan_id + var qrVlanID string + + if o.VlanID != nil { + qrVlanID = *o.VlanID + } + qVlanID := qrVlanID + if qVlanID != "" { + + if err := r.SetQueryParam("vlan_id", qVlanID); err != nil { + return err + } + } + } + + if o.VlanIDn != nil { + + // query param vlan_id__n + var qrVlanIDn string + + if o.VlanIDn != nil { + qrVlanIDn = *o.VlanIDn + } + qVlanIDn := qrVlanIDn + if qVlanIDn != "" { + + if err := r.SetQueryParam("vlan_id__n", qVlanIDn); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_list_responses.go b/netbox/client/wireless/wireless_wireless_lans_list_responses.go new file mode 100644 index 00000000..39f51be6 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_list_responses.go @@ -0,0 +1,247 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLansListReader is a Reader for the WirelessWirelessLansList structure. +type WirelessWirelessLansListReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLansListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLansListOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLansListOK creates a WirelessWirelessLansListOK with default headers values +func NewWirelessWirelessLansListOK() *WirelessWirelessLansListOK { + return &WirelessWirelessLansListOK{} +} + +/* WirelessWirelessLansListOK describes a response with status code 200, with default header values. + +WirelessWirelessLansListOK wireless wireless lans list o k +*/ +type WirelessWirelessLansListOK struct { + Payload *WirelessWirelessLansListOKBody +} + +func (o *WirelessWirelessLansListOK) Error() string { + return fmt.Sprintf("[GET /wireless/wireless-lans/][%d] wirelessWirelessLansListOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLansListOK) GetPayload() *WirelessWirelessLansListOKBody { + return o.Payload +} + +func (o *WirelessWirelessLansListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(WirelessWirelessLansListOKBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*WirelessWirelessLansListOKBody wireless wireless lans list o k body +swagger:model WirelessWirelessLansListOKBody +*/ +type WirelessWirelessLansListOKBody struct { + + // count + // Required: true + Count *int64 `json:"count"` + + // next + // Format: uri + Next *strfmt.URI `json:"next,omitempty"` + + // previous + // Format: uri + Previous *strfmt.URI `json:"previous,omitempty"` + + // results + // Required: true + Results []*models.WirelessLAN `json:"results"` +} + +// Validate validates this wireless wireless lans list o k body +func (o *WirelessWirelessLansListOKBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateCount(formats); err != nil { + res = append(res, err) + } + + if err := o.validateNext(formats); err != nil { + res = append(res, err) + } + + if err := o.validatePrevious(formats); err != nil { + res = append(res, err) + } + + if err := o.validateResults(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *WirelessWirelessLansListOKBody) validateCount(formats strfmt.Registry) error { + + if err := validate.Required("wirelessWirelessLansListOK"+"."+"count", "body", o.Count); err != nil { + return err + } + + return nil +} + +func (o *WirelessWirelessLansListOKBody) validateNext(formats strfmt.Registry) error { + if swag.IsZero(o.Next) { // not required + return nil + } + + if err := validate.FormatOf("wirelessWirelessLansListOK"+"."+"next", "body", "uri", o.Next.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *WirelessWirelessLansListOKBody) validatePrevious(formats strfmt.Registry) error { + if swag.IsZero(o.Previous) { // not required + return nil + } + + if err := validate.FormatOf("wirelessWirelessLansListOK"+"."+"previous", "body", "uri", o.Previous.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *WirelessWirelessLansListOKBody) validateResults(formats strfmt.Registry) error { + + if err := validate.Required("wirelessWirelessLansListOK"+"."+"results", "body", o.Results); err != nil { + return err + } + + for i := 0; i < len(o.Results); i++ { + if swag.IsZero(o.Results[i]) { // not required + continue + } + + if o.Results[i] != nil { + if err := o.Results[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("wirelessWirelessLansListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("wirelessWirelessLansListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this wireless wireless lans list o k body based on the context it is used +func (o *WirelessWirelessLansListOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := o.contextValidateResults(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *WirelessWirelessLansListOKBody) contextValidateResults(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(o.Results); i++ { + + if o.Results[i] != nil { + if err := o.Results[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("wirelessWirelessLansListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("wirelessWirelessLansListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (o *WirelessWirelessLansListOKBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *WirelessWirelessLansListOKBody) UnmarshalBinary(b []byte) error { + var res WirelessWirelessLansListOKBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_partial_update_parameters.go b/netbox/client/wireless/wireless_wireless_lans_partial_update_parameters.go new file mode 100644 index 00000000..cdb555ee --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_partial_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLansPartialUpdateParams creates a new WirelessWirelessLansPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLansPartialUpdateParams() *WirelessWirelessLansPartialUpdateParams { + return &WirelessWirelessLansPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLansPartialUpdateParamsWithTimeout creates a new WirelessWirelessLansPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLansPartialUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLansPartialUpdateParams { + return &WirelessWirelessLansPartialUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLansPartialUpdateParamsWithContext creates a new WirelessWirelessLansPartialUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLansPartialUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLansPartialUpdateParams { + return &WirelessWirelessLansPartialUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLansPartialUpdateParamsWithHTTPClient creates a new WirelessWirelessLansPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLansPartialUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLansPartialUpdateParams { + return &WirelessWirelessLansPartialUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLansPartialUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless lans partial update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLansPartialUpdateParams struct { + + // Data. + Data *models.WritableWirelessLAN + + /* ID. + + A unique integer value identifying this Wireless LAN. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lans partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansPartialUpdateParams) WithDefaults() *WirelessWirelessLansPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lans partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lans partial update params +func (o *WirelessWirelessLansPartialUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLansPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lans partial update params +func (o *WirelessWirelessLansPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lans partial update params +func (o *WirelessWirelessLansPartialUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLansPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lans partial update params +func (o *WirelessWirelessLansPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lans partial update params +func (o *WirelessWirelessLansPartialUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLansPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lans partial update params +func (o *WirelessWirelessLansPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless lans partial update params +func (o *WirelessWirelessLansPartialUpdateParams) WithData(data *models.WritableWirelessLAN) *WirelessWirelessLansPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless lans partial update params +func (o *WirelessWirelessLansPartialUpdateParams) SetData(data *models.WritableWirelessLAN) { + o.Data = data +} + +// WithID adds the id to the wireless wireless lans partial update params +func (o *WirelessWirelessLansPartialUpdateParams) WithID(id int64) *WirelessWirelessLansPartialUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless lans partial update params +func (o *WirelessWirelessLansPartialUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLansPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_partial_update_responses.go b/netbox/client/wireless/wireless_wireless_lans_partial_update_responses.go new file mode 100644 index 00000000..5d9d82d8 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLansPartialUpdateReader is a Reader for the WirelessWirelessLansPartialUpdate structure. +type WirelessWirelessLansPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLansPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLansPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLansPartialUpdateOK creates a WirelessWirelessLansPartialUpdateOK with default headers values +func NewWirelessWirelessLansPartialUpdateOK() *WirelessWirelessLansPartialUpdateOK { + return &WirelessWirelessLansPartialUpdateOK{} +} + +/* WirelessWirelessLansPartialUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLansPartialUpdateOK wireless wireless lans partial update o k +*/ +type WirelessWirelessLansPartialUpdateOK struct { + Payload *models.WirelessLAN +} + +func (o *WirelessWirelessLansPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /wireless/wireless-lans/{id}/][%d] wirelessWirelessLansPartialUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLansPartialUpdateOK) GetPayload() *models.WirelessLAN { + return o.Payload +} + +func (o *WirelessWirelessLansPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLAN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_read_parameters.go b/netbox/client/wireless/wireless_wireless_lans_read_parameters.go new file mode 100644 index 00000000..56391879 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_read_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewWirelessWirelessLansReadParams creates a new WirelessWirelessLansReadParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLansReadParams() *WirelessWirelessLansReadParams { + return &WirelessWirelessLansReadParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLansReadParamsWithTimeout creates a new WirelessWirelessLansReadParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLansReadParamsWithTimeout(timeout time.Duration) *WirelessWirelessLansReadParams { + return &WirelessWirelessLansReadParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLansReadParamsWithContext creates a new WirelessWirelessLansReadParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLansReadParamsWithContext(ctx context.Context) *WirelessWirelessLansReadParams { + return &WirelessWirelessLansReadParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLansReadParamsWithHTTPClient creates a new WirelessWirelessLansReadParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLansReadParamsWithHTTPClient(client *http.Client) *WirelessWirelessLansReadParams { + return &WirelessWirelessLansReadParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLansReadParams contains all the parameters to send to the API endpoint + for the wireless wireless lans read operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLansReadParams struct { + + /* ID. + + A unique integer value identifying this Wireless LAN. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lans read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansReadParams) WithDefaults() *WirelessWirelessLansReadParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lans read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansReadParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lans read params +func (o *WirelessWirelessLansReadParams) WithTimeout(timeout time.Duration) *WirelessWirelessLansReadParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lans read params +func (o *WirelessWirelessLansReadParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lans read params +func (o *WirelessWirelessLansReadParams) WithContext(ctx context.Context) *WirelessWirelessLansReadParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lans read params +func (o *WirelessWirelessLansReadParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lans read params +func (o *WirelessWirelessLansReadParams) WithHTTPClient(client *http.Client) *WirelessWirelessLansReadParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lans read params +func (o *WirelessWirelessLansReadParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the wireless wireless lans read params +func (o *WirelessWirelessLansReadParams) WithID(id int64) *WirelessWirelessLansReadParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless lans read params +func (o *WirelessWirelessLansReadParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLansReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_read_responses.go b/netbox/client/wireless/wireless_wireless_lans_read_responses.go new file mode 100644 index 00000000..f6ab189a --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_read_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLansReadReader is a Reader for the WirelessWirelessLansRead structure. +type WirelessWirelessLansReadReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLansReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLansReadOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLansReadOK creates a WirelessWirelessLansReadOK with default headers values +func NewWirelessWirelessLansReadOK() *WirelessWirelessLansReadOK { + return &WirelessWirelessLansReadOK{} +} + +/* WirelessWirelessLansReadOK describes a response with status code 200, with default header values. + +WirelessWirelessLansReadOK wireless wireless lans read o k +*/ +type WirelessWirelessLansReadOK struct { + Payload *models.WirelessLAN +} + +func (o *WirelessWirelessLansReadOK) Error() string { + return fmt.Sprintf("[GET /wireless/wireless-lans/{id}/][%d] wirelessWirelessLansReadOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLansReadOK) GetPayload() *models.WirelessLAN { + return o.Payload +} + +func (o *WirelessWirelessLansReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLAN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_update_parameters.go b/netbox/client/wireless/wireless_wireless_lans_update_parameters.go new file mode 100644 index 00000000..fa014cf9 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLansUpdateParams creates a new WirelessWirelessLansUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLansUpdateParams() *WirelessWirelessLansUpdateParams { + return &WirelessWirelessLansUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLansUpdateParamsWithTimeout creates a new WirelessWirelessLansUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLansUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLansUpdateParams { + return &WirelessWirelessLansUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLansUpdateParamsWithContext creates a new WirelessWirelessLansUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLansUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLansUpdateParams { + return &WirelessWirelessLansUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLansUpdateParamsWithHTTPClient creates a new WirelessWirelessLansUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLansUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLansUpdateParams { + return &WirelessWirelessLansUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLansUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless lans update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLansUpdateParams struct { + + // Data. + Data *models.WritableWirelessLAN + + /* ID. + + A unique integer value identifying this Wireless LAN. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless lans update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansUpdateParams) WithDefaults() *WirelessWirelessLansUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless lans update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLansUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless lans update params +func (o *WirelessWirelessLansUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLansUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless lans update params +func (o *WirelessWirelessLansUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless lans update params +func (o *WirelessWirelessLansUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLansUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless lans update params +func (o *WirelessWirelessLansUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless lans update params +func (o *WirelessWirelessLansUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLansUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless lans update params +func (o *WirelessWirelessLansUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless lans update params +func (o *WirelessWirelessLansUpdateParams) WithData(data *models.WritableWirelessLAN) *WirelessWirelessLansUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless lans update params +func (o *WirelessWirelessLansUpdateParams) SetData(data *models.WritableWirelessLAN) { + o.Data = data +} + +// WithID adds the id to the wireless wireless lans update params +func (o *WirelessWirelessLansUpdateParams) WithID(id int64) *WirelessWirelessLansUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless lans update params +func (o *WirelessWirelessLansUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLansUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_lans_update_responses.go b/netbox/client/wireless/wireless_wireless_lans_update_responses.go new file mode 100644 index 00000000..a5af0e10 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_lans_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLansUpdateReader is a Reader for the WirelessWirelessLansUpdate structure. +type WirelessWirelessLansUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLansUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLansUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLansUpdateOK creates a WirelessWirelessLansUpdateOK with default headers values +func NewWirelessWirelessLansUpdateOK() *WirelessWirelessLansUpdateOK { + return &WirelessWirelessLansUpdateOK{} +} + +/* WirelessWirelessLansUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLansUpdateOK wireless wireless lans update o k +*/ +type WirelessWirelessLansUpdateOK struct { + Payload *models.WirelessLAN +} + +func (o *WirelessWirelessLansUpdateOK) Error() string { + return fmt.Sprintf("[PUT /wireless/wireless-lans/{id}/][%d] wirelessWirelessLansUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLansUpdateOK) GetPayload() *models.WirelessLAN { + return o.Payload +} + +func (o *WirelessWirelessLansUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLAN) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_bulk_delete_parameters.go b/netbox/client/wireless/wireless_wireless_links_bulk_delete_parameters.go new file mode 100644 index 00000000..b3c11225 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_bulk_delete_parameters.go @@ -0,0 +1,141 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" +) + +// NewWirelessWirelessLinksBulkDeleteParams creates a new WirelessWirelessLinksBulkDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLinksBulkDeleteParams() *WirelessWirelessLinksBulkDeleteParams { + return &WirelessWirelessLinksBulkDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLinksBulkDeleteParamsWithTimeout creates a new WirelessWirelessLinksBulkDeleteParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLinksBulkDeleteParamsWithTimeout(timeout time.Duration) *WirelessWirelessLinksBulkDeleteParams { + return &WirelessWirelessLinksBulkDeleteParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLinksBulkDeleteParamsWithContext creates a new WirelessWirelessLinksBulkDeleteParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLinksBulkDeleteParamsWithContext(ctx context.Context) *WirelessWirelessLinksBulkDeleteParams { + return &WirelessWirelessLinksBulkDeleteParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLinksBulkDeleteParamsWithHTTPClient creates a new WirelessWirelessLinksBulkDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLinksBulkDeleteParamsWithHTTPClient(client *http.Client) *WirelessWirelessLinksBulkDeleteParams { + return &WirelessWirelessLinksBulkDeleteParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLinksBulkDeleteParams contains all the parameters to send to the API endpoint + for the wireless wireless links bulk delete operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLinksBulkDeleteParams struct { + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless links bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksBulkDeleteParams) WithDefaults() *WirelessWirelessLinksBulkDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless links bulk delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksBulkDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless links bulk delete params +func (o *WirelessWirelessLinksBulkDeleteParams) WithTimeout(timeout time.Duration) *WirelessWirelessLinksBulkDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless links bulk delete params +func (o *WirelessWirelessLinksBulkDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless links bulk delete params +func (o *WirelessWirelessLinksBulkDeleteParams) WithContext(ctx context.Context) *WirelessWirelessLinksBulkDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless links bulk delete params +func (o *WirelessWirelessLinksBulkDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless links bulk delete params +func (o *WirelessWirelessLinksBulkDeleteParams) WithHTTPClient(client *http.Client) *WirelessWirelessLinksBulkDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless links bulk delete params +func (o *WirelessWirelessLinksBulkDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLinksBulkDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_bulk_delete_responses.go b/netbox/client/wireless/wireless_wireless_links_bulk_delete_responses.go new file mode 100644 index 00000000..b94cb603 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_bulk_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// WirelessWirelessLinksBulkDeleteReader is a Reader for the WirelessWirelessLinksBulkDelete structure. +type WirelessWirelessLinksBulkDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLinksBulkDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewWirelessWirelessLinksBulkDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLinksBulkDeleteNoContent creates a WirelessWirelessLinksBulkDeleteNoContent with default headers values +func NewWirelessWirelessLinksBulkDeleteNoContent() *WirelessWirelessLinksBulkDeleteNoContent { + return &WirelessWirelessLinksBulkDeleteNoContent{} +} + +/* WirelessWirelessLinksBulkDeleteNoContent describes a response with status code 204, with default header values. + +WirelessWirelessLinksBulkDeleteNoContent wireless wireless links bulk delete no content +*/ +type WirelessWirelessLinksBulkDeleteNoContent struct { +} + +func (o *WirelessWirelessLinksBulkDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /wireless/wireless-links/][%d] wirelessWirelessLinksBulkDeleteNoContent ", 204) +} + +func (o *WirelessWirelessLinksBulkDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_bulk_partial_update_parameters.go b/netbox/client/wireless/wireless_wireless_links_bulk_partial_update_parameters.go new file mode 100644 index 00000000..4999ec29 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_bulk_partial_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLinksBulkPartialUpdateParams creates a new WirelessWirelessLinksBulkPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLinksBulkPartialUpdateParams() *WirelessWirelessLinksBulkPartialUpdateParams { + return &WirelessWirelessLinksBulkPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLinksBulkPartialUpdateParamsWithTimeout creates a new WirelessWirelessLinksBulkPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLinksBulkPartialUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLinksBulkPartialUpdateParams { + return &WirelessWirelessLinksBulkPartialUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLinksBulkPartialUpdateParamsWithContext creates a new WirelessWirelessLinksBulkPartialUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLinksBulkPartialUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLinksBulkPartialUpdateParams { + return &WirelessWirelessLinksBulkPartialUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLinksBulkPartialUpdateParamsWithHTTPClient creates a new WirelessWirelessLinksBulkPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLinksBulkPartialUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLinksBulkPartialUpdateParams { + return &WirelessWirelessLinksBulkPartialUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLinksBulkPartialUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless links bulk partial update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLinksBulkPartialUpdateParams struct { + + // Data. + Data *models.WritableWirelessLink + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless links bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksBulkPartialUpdateParams) WithDefaults() *WirelessWirelessLinksBulkPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless links bulk partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksBulkPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless links bulk partial update params +func (o *WirelessWirelessLinksBulkPartialUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLinksBulkPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless links bulk partial update params +func (o *WirelessWirelessLinksBulkPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless links bulk partial update params +func (o *WirelessWirelessLinksBulkPartialUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLinksBulkPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless links bulk partial update params +func (o *WirelessWirelessLinksBulkPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless links bulk partial update params +func (o *WirelessWirelessLinksBulkPartialUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLinksBulkPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless links bulk partial update params +func (o *WirelessWirelessLinksBulkPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless links bulk partial update params +func (o *WirelessWirelessLinksBulkPartialUpdateParams) WithData(data *models.WritableWirelessLink) *WirelessWirelessLinksBulkPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless links bulk partial update params +func (o *WirelessWirelessLinksBulkPartialUpdateParams) SetData(data *models.WritableWirelessLink) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLinksBulkPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_bulk_partial_update_responses.go b/netbox/client/wireless/wireless_wireless_links_bulk_partial_update_responses.go new file mode 100644 index 00000000..83a8056a --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_bulk_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLinksBulkPartialUpdateReader is a Reader for the WirelessWirelessLinksBulkPartialUpdate structure. +type WirelessWirelessLinksBulkPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLinksBulkPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLinksBulkPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLinksBulkPartialUpdateOK creates a WirelessWirelessLinksBulkPartialUpdateOK with default headers values +func NewWirelessWirelessLinksBulkPartialUpdateOK() *WirelessWirelessLinksBulkPartialUpdateOK { + return &WirelessWirelessLinksBulkPartialUpdateOK{} +} + +/* WirelessWirelessLinksBulkPartialUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLinksBulkPartialUpdateOK wireless wireless links bulk partial update o k +*/ +type WirelessWirelessLinksBulkPartialUpdateOK struct { + Payload *models.WirelessLink +} + +func (o *WirelessWirelessLinksBulkPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /wireless/wireless-links/][%d] wirelessWirelessLinksBulkPartialUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLinksBulkPartialUpdateOK) GetPayload() *models.WirelessLink { + return o.Payload +} + +func (o *WirelessWirelessLinksBulkPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLink) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_bulk_update_parameters.go b/netbox/client/wireless/wireless_wireless_links_bulk_update_parameters.go new file mode 100644 index 00000000..98d1bdc8 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_bulk_update_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLinksBulkUpdateParams creates a new WirelessWirelessLinksBulkUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLinksBulkUpdateParams() *WirelessWirelessLinksBulkUpdateParams { + return &WirelessWirelessLinksBulkUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLinksBulkUpdateParamsWithTimeout creates a new WirelessWirelessLinksBulkUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLinksBulkUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLinksBulkUpdateParams { + return &WirelessWirelessLinksBulkUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLinksBulkUpdateParamsWithContext creates a new WirelessWirelessLinksBulkUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLinksBulkUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLinksBulkUpdateParams { + return &WirelessWirelessLinksBulkUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLinksBulkUpdateParamsWithHTTPClient creates a new WirelessWirelessLinksBulkUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLinksBulkUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLinksBulkUpdateParams { + return &WirelessWirelessLinksBulkUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLinksBulkUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless links bulk update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLinksBulkUpdateParams struct { + + // Data. + Data *models.WritableWirelessLink + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless links bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksBulkUpdateParams) WithDefaults() *WirelessWirelessLinksBulkUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless links bulk update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksBulkUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless links bulk update params +func (o *WirelessWirelessLinksBulkUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLinksBulkUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless links bulk update params +func (o *WirelessWirelessLinksBulkUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless links bulk update params +func (o *WirelessWirelessLinksBulkUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLinksBulkUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless links bulk update params +func (o *WirelessWirelessLinksBulkUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless links bulk update params +func (o *WirelessWirelessLinksBulkUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLinksBulkUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless links bulk update params +func (o *WirelessWirelessLinksBulkUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless links bulk update params +func (o *WirelessWirelessLinksBulkUpdateParams) WithData(data *models.WritableWirelessLink) *WirelessWirelessLinksBulkUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless links bulk update params +func (o *WirelessWirelessLinksBulkUpdateParams) SetData(data *models.WritableWirelessLink) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLinksBulkUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_bulk_update_responses.go b/netbox/client/wireless/wireless_wireless_links_bulk_update_responses.go new file mode 100644 index 00000000..1fefe22c --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_bulk_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLinksBulkUpdateReader is a Reader for the WirelessWirelessLinksBulkUpdate structure. +type WirelessWirelessLinksBulkUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLinksBulkUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLinksBulkUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLinksBulkUpdateOK creates a WirelessWirelessLinksBulkUpdateOK with default headers values +func NewWirelessWirelessLinksBulkUpdateOK() *WirelessWirelessLinksBulkUpdateOK { + return &WirelessWirelessLinksBulkUpdateOK{} +} + +/* WirelessWirelessLinksBulkUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLinksBulkUpdateOK wireless wireless links bulk update o k +*/ +type WirelessWirelessLinksBulkUpdateOK struct { + Payload *models.WirelessLink +} + +func (o *WirelessWirelessLinksBulkUpdateOK) Error() string { + return fmt.Sprintf("[PUT /wireless/wireless-links/][%d] wirelessWirelessLinksBulkUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLinksBulkUpdateOK) GetPayload() *models.WirelessLink { + return o.Payload +} + +func (o *WirelessWirelessLinksBulkUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLink) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_create_parameters.go b/netbox/client/wireless/wireless_wireless_links_create_parameters.go new file mode 100644 index 00000000..9e1043d1 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_create_parameters.go @@ -0,0 +1,163 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLinksCreateParams creates a new WirelessWirelessLinksCreateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLinksCreateParams() *WirelessWirelessLinksCreateParams { + return &WirelessWirelessLinksCreateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLinksCreateParamsWithTimeout creates a new WirelessWirelessLinksCreateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLinksCreateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLinksCreateParams { + return &WirelessWirelessLinksCreateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLinksCreateParamsWithContext creates a new WirelessWirelessLinksCreateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLinksCreateParamsWithContext(ctx context.Context) *WirelessWirelessLinksCreateParams { + return &WirelessWirelessLinksCreateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLinksCreateParamsWithHTTPClient creates a new WirelessWirelessLinksCreateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLinksCreateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLinksCreateParams { + return &WirelessWirelessLinksCreateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLinksCreateParams contains all the parameters to send to the API endpoint + for the wireless wireless links create operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLinksCreateParams struct { + + // Data. + Data *models.WritableWirelessLink + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless links create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksCreateParams) WithDefaults() *WirelessWirelessLinksCreateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless links create params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksCreateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless links create params +func (o *WirelessWirelessLinksCreateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLinksCreateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless links create params +func (o *WirelessWirelessLinksCreateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless links create params +func (o *WirelessWirelessLinksCreateParams) WithContext(ctx context.Context) *WirelessWirelessLinksCreateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless links create params +func (o *WirelessWirelessLinksCreateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless links create params +func (o *WirelessWirelessLinksCreateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLinksCreateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless links create params +func (o *WirelessWirelessLinksCreateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless links create params +func (o *WirelessWirelessLinksCreateParams) WithData(data *models.WritableWirelessLink) *WirelessWirelessLinksCreateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless links create params +func (o *WirelessWirelessLinksCreateParams) SetData(data *models.WritableWirelessLink) { + o.Data = data +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLinksCreateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_create_responses.go b/netbox/client/wireless/wireless_wireless_links_create_responses.go new file mode 100644 index 00000000..acd68039 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_create_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLinksCreateReader is a Reader for the WirelessWirelessLinksCreate structure. +type WirelessWirelessLinksCreateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLinksCreateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 201: + result := NewWirelessWirelessLinksCreateCreated() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLinksCreateCreated creates a WirelessWirelessLinksCreateCreated with default headers values +func NewWirelessWirelessLinksCreateCreated() *WirelessWirelessLinksCreateCreated { + return &WirelessWirelessLinksCreateCreated{} +} + +/* WirelessWirelessLinksCreateCreated describes a response with status code 201, with default header values. + +WirelessWirelessLinksCreateCreated wireless wireless links create created +*/ +type WirelessWirelessLinksCreateCreated struct { + Payload *models.WirelessLink +} + +func (o *WirelessWirelessLinksCreateCreated) Error() string { + return fmt.Sprintf("[POST /wireless/wireless-links/][%d] wirelessWirelessLinksCreateCreated %+v", 201, o.Payload) +} +func (o *WirelessWirelessLinksCreateCreated) GetPayload() *models.WirelessLink { + return o.Payload +} + +func (o *WirelessWirelessLinksCreateCreated) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLink) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_delete_parameters.go b/netbox/client/wireless/wireless_wireless_links_delete_parameters.go new file mode 100644 index 00000000..1ed27520 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_delete_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewWirelessWirelessLinksDeleteParams creates a new WirelessWirelessLinksDeleteParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLinksDeleteParams() *WirelessWirelessLinksDeleteParams { + return &WirelessWirelessLinksDeleteParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLinksDeleteParamsWithTimeout creates a new WirelessWirelessLinksDeleteParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLinksDeleteParamsWithTimeout(timeout time.Duration) *WirelessWirelessLinksDeleteParams { + return &WirelessWirelessLinksDeleteParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLinksDeleteParamsWithContext creates a new WirelessWirelessLinksDeleteParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLinksDeleteParamsWithContext(ctx context.Context) *WirelessWirelessLinksDeleteParams { + return &WirelessWirelessLinksDeleteParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLinksDeleteParamsWithHTTPClient creates a new WirelessWirelessLinksDeleteParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLinksDeleteParamsWithHTTPClient(client *http.Client) *WirelessWirelessLinksDeleteParams { + return &WirelessWirelessLinksDeleteParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLinksDeleteParams contains all the parameters to send to the API endpoint + for the wireless wireless links delete operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLinksDeleteParams struct { + + /* ID. + + A unique integer value identifying this wireless link. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless links delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksDeleteParams) WithDefaults() *WirelessWirelessLinksDeleteParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless links delete params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksDeleteParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless links delete params +func (o *WirelessWirelessLinksDeleteParams) WithTimeout(timeout time.Duration) *WirelessWirelessLinksDeleteParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless links delete params +func (o *WirelessWirelessLinksDeleteParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless links delete params +func (o *WirelessWirelessLinksDeleteParams) WithContext(ctx context.Context) *WirelessWirelessLinksDeleteParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless links delete params +func (o *WirelessWirelessLinksDeleteParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless links delete params +func (o *WirelessWirelessLinksDeleteParams) WithHTTPClient(client *http.Client) *WirelessWirelessLinksDeleteParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless links delete params +func (o *WirelessWirelessLinksDeleteParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the wireless wireless links delete params +func (o *WirelessWirelessLinksDeleteParams) WithID(id int64) *WirelessWirelessLinksDeleteParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless links delete params +func (o *WirelessWirelessLinksDeleteParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLinksDeleteParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_delete_responses.go b/netbox/client/wireless/wireless_wireless_links_delete_responses.go new file mode 100644 index 00000000..647d6aba --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_delete_responses.go @@ -0,0 +1,68 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" +) + +// WirelessWirelessLinksDeleteReader is a Reader for the WirelessWirelessLinksDelete structure. +type WirelessWirelessLinksDeleteReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLinksDeleteReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 204: + result := NewWirelessWirelessLinksDeleteNoContent() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLinksDeleteNoContent creates a WirelessWirelessLinksDeleteNoContent with default headers values +func NewWirelessWirelessLinksDeleteNoContent() *WirelessWirelessLinksDeleteNoContent { + return &WirelessWirelessLinksDeleteNoContent{} +} + +/* WirelessWirelessLinksDeleteNoContent describes a response with status code 204, with default header values. + +WirelessWirelessLinksDeleteNoContent wireless wireless links delete no content +*/ +type WirelessWirelessLinksDeleteNoContent struct { +} + +func (o *WirelessWirelessLinksDeleteNoContent) Error() string { + return fmt.Sprintf("[DELETE /wireless/wireless-links/{id}/][%d] wirelessWirelessLinksDeleteNoContent ", 204) +} + +func (o *WirelessWirelessLinksDeleteNoContent) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_list_parameters.go b/netbox/client/wireless/wireless_wireless_links_list_parameters.go new file mode 100644 index 00000000..78fa73b2 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_list_parameters.go @@ -0,0 +1,2257 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewWirelessWirelessLinksListParams creates a new WirelessWirelessLinksListParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLinksListParams() *WirelessWirelessLinksListParams { + return &WirelessWirelessLinksListParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLinksListParamsWithTimeout creates a new WirelessWirelessLinksListParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLinksListParamsWithTimeout(timeout time.Duration) *WirelessWirelessLinksListParams { + return &WirelessWirelessLinksListParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLinksListParamsWithContext creates a new WirelessWirelessLinksListParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLinksListParamsWithContext(ctx context.Context) *WirelessWirelessLinksListParams { + return &WirelessWirelessLinksListParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLinksListParamsWithHTTPClient creates a new WirelessWirelessLinksListParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLinksListParamsWithHTTPClient(client *http.Client) *WirelessWirelessLinksListParams { + return &WirelessWirelessLinksListParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLinksListParams contains all the parameters to send to the API endpoint + for the wireless wireless links list operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLinksListParams struct { + + // AuthCipher. + AuthCipher *string + + // AuthCiphern. + AuthCiphern *string + + // AuthPsk. + AuthPsk *string + + // AuthPskEmpty. + AuthPskEmpty *string + + // AuthPskIc. + AuthPskIc *string + + // AuthPskIe. + AuthPskIe *string + + // AuthPskIew. + AuthPskIew *string + + // AuthPskIsw. + AuthPskIsw *string + + // AuthPskn. + AuthPskn *string + + // AuthPskNic. + AuthPskNic *string + + // AuthPskNie. + AuthPskNie *string + + // AuthPskNiew. + AuthPskNiew *string + + // AuthPskNisw. + AuthPskNisw *string + + // AuthType. + AuthType *string + + // AuthTypen. + AuthTypen *string + + // Created. + Created *string + + // CreatedGte. + CreatedGte *string + + // CreatedLte. + CreatedLte *string + + // Description. + Description *string + + // DescriptionEmpty. + DescriptionEmpty *string + + // DescriptionIc. + DescriptionIc *string + + // DescriptionIe. + DescriptionIe *string + + // DescriptionIew. + DescriptionIew *string + + // DescriptionIsw. + DescriptionIsw *string + + // Descriptionn. + Descriptionn *string + + // DescriptionNic. + DescriptionNic *string + + // DescriptionNie. + DescriptionNie *string + + // DescriptionNiew. + DescriptionNiew *string + + // DescriptionNisw. + DescriptionNisw *string + + // ID. + ID *string + + // IDGt. + IDGt *string + + // IDGte. + IDGte *string + + // IDLt. + IDLt *string + + // IDLte. + IDLte *string + + // IDn. + IDn *string + + // InterfaceaID. + InterfaceaID *string + + // InterfaceaIDGt. + InterfaceaIDGt *string + + // InterfaceaIDGte. + InterfaceaIDGte *string + + // InterfaceaIDLt. + InterfaceaIDLt *string + + // InterfaceaIDLte. + InterfaceaIDLte *string + + // InterfaceaIDn. + InterfaceaIDn *string + + // InterfacebID. + InterfacebID *string + + // InterfacebIDGt. + InterfacebIDGt *string + + // InterfacebIDGte. + InterfacebIDGte *string + + // InterfacebIDLt. + InterfacebIDLt *string + + // InterfacebIDLte. + InterfacebIDLte *string + + // InterfacebIDn. + InterfacebIDn *string + + // LastUpdated. + LastUpdated *string + + // LastUpdatedGte. + LastUpdatedGte *string + + // LastUpdatedLte. + LastUpdatedLte *string + + /* Limit. + + Number of results to return per page. + */ + Limit *int64 + + /* Offset. + + The initial index from which to return the results. + */ + Offset *int64 + + // Q. + Q *string + + // Ssid. + Ssid *string + + // SsidEmpty. + SsidEmpty *string + + // SsidIc. + SsidIc *string + + // SsidIe. + SsidIe *string + + // SsidIew. + SsidIew *string + + // SsidIsw. + SsidIsw *string + + // Ssidn. + Ssidn *string + + // SsidNic. + SsidNic *string + + // SsidNie. + SsidNie *string + + // SsidNiew. + SsidNiew *string + + // SsidNisw. + SsidNisw *string + + // Status. + Status *string + + // Statusn. + Statusn *string + + // Tag. + Tag *string + + // Tagn. + Tagn *string + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless links list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksListParams) WithDefaults() *WirelessWirelessLinksListParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless links list params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksListParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithTimeout(timeout time.Duration) *WirelessWirelessLinksListParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithContext(ctx context.Context) *WirelessWirelessLinksListParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithHTTPClient(client *http.Client) *WirelessWirelessLinksListParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithAuthCipher adds the authCipher to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthCipher(authCipher *string) *WirelessWirelessLinksListParams { + o.SetAuthCipher(authCipher) + return o +} + +// SetAuthCipher adds the authCipher to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthCipher(authCipher *string) { + o.AuthCipher = authCipher +} + +// WithAuthCiphern adds the authCiphern to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthCiphern(authCiphern *string) *WirelessWirelessLinksListParams { + o.SetAuthCiphern(authCiphern) + return o +} + +// SetAuthCiphern adds the authCipherN to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthCiphern(authCiphern *string) { + o.AuthCiphern = authCiphern +} + +// WithAuthPsk adds the authPsk to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthPsk(authPsk *string) *WirelessWirelessLinksListParams { + o.SetAuthPsk(authPsk) + return o +} + +// SetAuthPsk adds the authPsk to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthPsk(authPsk *string) { + o.AuthPsk = authPsk +} + +// WithAuthPskEmpty adds the authPskEmpty to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthPskEmpty(authPskEmpty *string) *WirelessWirelessLinksListParams { + o.SetAuthPskEmpty(authPskEmpty) + return o +} + +// SetAuthPskEmpty adds the authPskEmpty to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthPskEmpty(authPskEmpty *string) { + o.AuthPskEmpty = authPskEmpty +} + +// WithAuthPskIc adds the authPskIc to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthPskIc(authPskIc *string) *WirelessWirelessLinksListParams { + o.SetAuthPskIc(authPskIc) + return o +} + +// SetAuthPskIc adds the authPskIc to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthPskIc(authPskIc *string) { + o.AuthPskIc = authPskIc +} + +// WithAuthPskIe adds the authPskIe to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthPskIe(authPskIe *string) *WirelessWirelessLinksListParams { + o.SetAuthPskIe(authPskIe) + return o +} + +// SetAuthPskIe adds the authPskIe to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthPskIe(authPskIe *string) { + o.AuthPskIe = authPskIe +} + +// WithAuthPskIew adds the authPskIew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthPskIew(authPskIew *string) *WirelessWirelessLinksListParams { + o.SetAuthPskIew(authPskIew) + return o +} + +// SetAuthPskIew adds the authPskIew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthPskIew(authPskIew *string) { + o.AuthPskIew = authPskIew +} + +// WithAuthPskIsw adds the authPskIsw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthPskIsw(authPskIsw *string) *WirelessWirelessLinksListParams { + o.SetAuthPskIsw(authPskIsw) + return o +} + +// SetAuthPskIsw adds the authPskIsw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthPskIsw(authPskIsw *string) { + o.AuthPskIsw = authPskIsw +} + +// WithAuthPskn adds the authPskn to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthPskn(authPskn *string) *WirelessWirelessLinksListParams { + o.SetAuthPskn(authPskn) + return o +} + +// SetAuthPskn adds the authPskN to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthPskn(authPskn *string) { + o.AuthPskn = authPskn +} + +// WithAuthPskNic adds the authPskNic to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthPskNic(authPskNic *string) *WirelessWirelessLinksListParams { + o.SetAuthPskNic(authPskNic) + return o +} + +// SetAuthPskNic adds the authPskNic to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthPskNic(authPskNic *string) { + o.AuthPskNic = authPskNic +} + +// WithAuthPskNie adds the authPskNie to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthPskNie(authPskNie *string) *WirelessWirelessLinksListParams { + o.SetAuthPskNie(authPskNie) + return o +} + +// SetAuthPskNie adds the authPskNie to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthPskNie(authPskNie *string) { + o.AuthPskNie = authPskNie +} + +// WithAuthPskNiew adds the authPskNiew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthPskNiew(authPskNiew *string) *WirelessWirelessLinksListParams { + o.SetAuthPskNiew(authPskNiew) + return o +} + +// SetAuthPskNiew adds the authPskNiew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthPskNiew(authPskNiew *string) { + o.AuthPskNiew = authPskNiew +} + +// WithAuthPskNisw adds the authPskNisw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthPskNisw(authPskNisw *string) *WirelessWirelessLinksListParams { + o.SetAuthPskNisw(authPskNisw) + return o +} + +// SetAuthPskNisw adds the authPskNisw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthPskNisw(authPskNisw *string) { + o.AuthPskNisw = authPskNisw +} + +// WithAuthType adds the authType to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthType(authType *string) *WirelessWirelessLinksListParams { + o.SetAuthType(authType) + return o +} + +// SetAuthType adds the authType to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthType(authType *string) { + o.AuthType = authType +} + +// WithAuthTypen adds the authTypen to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithAuthTypen(authTypen *string) *WirelessWirelessLinksListParams { + o.SetAuthTypen(authTypen) + return o +} + +// SetAuthTypen adds the authTypeN to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetAuthTypen(authTypen *string) { + o.AuthTypen = authTypen +} + +// WithCreated adds the created to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithCreated(created *string) *WirelessWirelessLinksListParams { + o.SetCreated(created) + return o +} + +// SetCreated adds the created to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetCreated(created *string) { + o.Created = created +} + +// WithCreatedGte adds the createdGte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithCreatedGte(createdGte *string) *WirelessWirelessLinksListParams { + o.SetCreatedGte(createdGte) + return o +} + +// SetCreatedGte adds the createdGte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetCreatedGte(createdGte *string) { + o.CreatedGte = createdGte +} + +// WithCreatedLte adds the createdLte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithCreatedLte(createdLte *string) *WirelessWirelessLinksListParams { + o.SetCreatedLte(createdLte) + return o +} + +// SetCreatedLte adds the createdLte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetCreatedLte(createdLte *string) { + o.CreatedLte = createdLte +} + +// WithDescription adds the description to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithDescription(description *string) *WirelessWirelessLinksListParams { + o.SetDescription(description) + return o +} + +// SetDescription adds the description to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetDescription(description *string) { + o.Description = description +} + +// WithDescriptionEmpty adds the descriptionEmpty to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithDescriptionEmpty(descriptionEmpty *string) *WirelessWirelessLinksListParams { + o.SetDescriptionEmpty(descriptionEmpty) + return o +} + +// SetDescriptionEmpty adds the descriptionEmpty to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetDescriptionEmpty(descriptionEmpty *string) { + o.DescriptionEmpty = descriptionEmpty +} + +// WithDescriptionIc adds the descriptionIc to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithDescriptionIc(descriptionIc *string) *WirelessWirelessLinksListParams { + o.SetDescriptionIc(descriptionIc) + return o +} + +// SetDescriptionIc adds the descriptionIc to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetDescriptionIc(descriptionIc *string) { + o.DescriptionIc = descriptionIc +} + +// WithDescriptionIe adds the descriptionIe to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithDescriptionIe(descriptionIe *string) *WirelessWirelessLinksListParams { + o.SetDescriptionIe(descriptionIe) + return o +} + +// SetDescriptionIe adds the descriptionIe to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetDescriptionIe(descriptionIe *string) { + o.DescriptionIe = descriptionIe +} + +// WithDescriptionIew adds the descriptionIew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithDescriptionIew(descriptionIew *string) *WirelessWirelessLinksListParams { + o.SetDescriptionIew(descriptionIew) + return o +} + +// SetDescriptionIew adds the descriptionIew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetDescriptionIew(descriptionIew *string) { + o.DescriptionIew = descriptionIew +} + +// WithDescriptionIsw adds the descriptionIsw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithDescriptionIsw(descriptionIsw *string) *WirelessWirelessLinksListParams { + o.SetDescriptionIsw(descriptionIsw) + return o +} + +// SetDescriptionIsw adds the descriptionIsw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetDescriptionIsw(descriptionIsw *string) { + o.DescriptionIsw = descriptionIsw +} + +// WithDescriptionn adds the descriptionn to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithDescriptionn(descriptionn *string) *WirelessWirelessLinksListParams { + o.SetDescriptionn(descriptionn) + return o +} + +// SetDescriptionn adds the descriptionN to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetDescriptionn(descriptionn *string) { + o.Descriptionn = descriptionn +} + +// WithDescriptionNic adds the descriptionNic to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithDescriptionNic(descriptionNic *string) *WirelessWirelessLinksListParams { + o.SetDescriptionNic(descriptionNic) + return o +} + +// SetDescriptionNic adds the descriptionNic to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetDescriptionNic(descriptionNic *string) { + o.DescriptionNic = descriptionNic +} + +// WithDescriptionNie adds the descriptionNie to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithDescriptionNie(descriptionNie *string) *WirelessWirelessLinksListParams { + o.SetDescriptionNie(descriptionNie) + return o +} + +// SetDescriptionNie adds the descriptionNie to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetDescriptionNie(descriptionNie *string) { + o.DescriptionNie = descriptionNie +} + +// WithDescriptionNiew adds the descriptionNiew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithDescriptionNiew(descriptionNiew *string) *WirelessWirelessLinksListParams { + o.SetDescriptionNiew(descriptionNiew) + return o +} + +// SetDescriptionNiew adds the descriptionNiew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetDescriptionNiew(descriptionNiew *string) { + o.DescriptionNiew = descriptionNiew +} + +// WithDescriptionNisw adds the descriptionNisw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithDescriptionNisw(descriptionNisw *string) *WirelessWirelessLinksListParams { + o.SetDescriptionNisw(descriptionNisw) + return o +} + +// SetDescriptionNisw adds the descriptionNisw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetDescriptionNisw(descriptionNisw *string) { + o.DescriptionNisw = descriptionNisw +} + +// WithID adds the id to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithID(id *string) *WirelessWirelessLinksListParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetID(id *string) { + o.ID = id +} + +// WithIDGt adds the iDGt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithIDGt(iDGt *string) *WirelessWirelessLinksListParams { + o.SetIDGt(iDGt) + return o +} + +// SetIDGt adds the idGt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetIDGt(iDGt *string) { + o.IDGt = iDGt +} + +// WithIDGte adds the iDGte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithIDGte(iDGte *string) *WirelessWirelessLinksListParams { + o.SetIDGte(iDGte) + return o +} + +// SetIDGte adds the idGte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetIDGte(iDGte *string) { + o.IDGte = iDGte +} + +// WithIDLt adds the iDLt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithIDLt(iDLt *string) *WirelessWirelessLinksListParams { + o.SetIDLt(iDLt) + return o +} + +// SetIDLt adds the idLt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetIDLt(iDLt *string) { + o.IDLt = iDLt +} + +// WithIDLte adds the iDLte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithIDLte(iDLte *string) *WirelessWirelessLinksListParams { + o.SetIDLte(iDLte) + return o +} + +// SetIDLte adds the idLte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetIDLte(iDLte *string) { + o.IDLte = iDLte +} + +// WithIDn adds the iDn to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithIDn(iDn *string) *WirelessWirelessLinksListParams { + o.SetIDn(iDn) + return o +} + +// SetIDn adds the idN to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetIDn(iDn *string) { + o.IDn = iDn +} + +// WithInterfaceaID adds the interfaceaID to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfaceaID(interfaceaID *string) *WirelessWirelessLinksListParams { + o.SetInterfaceaID(interfaceaID) + return o +} + +// SetInterfaceaID adds the interfaceAId to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfaceaID(interfaceaID *string) { + o.InterfaceaID = interfaceaID +} + +// WithInterfaceaIDGt adds the interfaceaIDGt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfaceaIDGt(interfaceaIDGt *string) *WirelessWirelessLinksListParams { + o.SetInterfaceaIDGt(interfaceaIDGt) + return o +} + +// SetInterfaceaIDGt adds the interfaceAIdGt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfaceaIDGt(interfaceaIDGt *string) { + o.InterfaceaIDGt = interfaceaIDGt +} + +// WithInterfaceaIDGte adds the interfaceaIDGte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfaceaIDGte(interfaceaIDGte *string) *WirelessWirelessLinksListParams { + o.SetInterfaceaIDGte(interfaceaIDGte) + return o +} + +// SetInterfaceaIDGte adds the interfaceAIdGte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfaceaIDGte(interfaceaIDGte *string) { + o.InterfaceaIDGte = interfaceaIDGte +} + +// WithInterfaceaIDLt adds the interfaceaIDLt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfaceaIDLt(interfaceaIDLt *string) *WirelessWirelessLinksListParams { + o.SetInterfaceaIDLt(interfaceaIDLt) + return o +} + +// SetInterfaceaIDLt adds the interfaceAIdLt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfaceaIDLt(interfaceaIDLt *string) { + o.InterfaceaIDLt = interfaceaIDLt +} + +// WithInterfaceaIDLte adds the interfaceaIDLte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfaceaIDLte(interfaceaIDLte *string) *WirelessWirelessLinksListParams { + o.SetInterfaceaIDLte(interfaceaIDLte) + return o +} + +// SetInterfaceaIDLte adds the interfaceAIdLte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfaceaIDLte(interfaceaIDLte *string) { + o.InterfaceaIDLte = interfaceaIDLte +} + +// WithInterfaceaIDn adds the interfaceaIDn to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfaceaIDn(interfaceaIDn *string) *WirelessWirelessLinksListParams { + o.SetInterfaceaIDn(interfaceaIDn) + return o +} + +// SetInterfaceaIDn adds the interfaceAIdN to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfaceaIDn(interfaceaIDn *string) { + o.InterfaceaIDn = interfaceaIDn +} + +// WithInterfacebID adds the interfacebID to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfacebID(interfacebID *string) *WirelessWirelessLinksListParams { + o.SetInterfacebID(interfacebID) + return o +} + +// SetInterfacebID adds the interfaceBId to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfacebID(interfacebID *string) { + o.InterfacebID = interfacebID +} + +// WithInterfacebIDGt adds the interfacebIDGt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfacebIDGt(interfacebIDGt *string) *WirelessWirelessLinksListParams { + o.SetInterfacebIDGt(interfacebIDGt) + return o +} + +// SetInterfacebIDGt adds the interfaceBIdGt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfacebIDGt(interfacebIDGt *string) { + o.InterfacebIDGt = interfacebIDGt +} + +// WithInterfacebIDGte adds the interfacebIDGte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfacebIDGte(interfacebIDGte *string) *WirelessWirelessLinksListParams { + o.SetInterfacebIDGte(interfacebIDGte) + return o +} + +// SetInterfacebIDGte adds the interfaceBIdGte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfacebIDGte(interfacebIDGte *string) { + o.InterfacebIDGte = interfacebIDGte +} + +// WithInterfacebIDLt adds the interfacebIDLt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfacebIDLt(interfacebIDLt *string) *WirelessWirelessLinksListParams { + o.SetInterfacebIDLt(interfacebIDLt) + return o +} + +// SetInterfacebIDLt adds the interfaceBIdLt to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfacebIDLt(interfacebIDLt *string) { + o.InterfacebIDLt = interfacebIDLt +} + +// WithInterfacebIDLte adds the interfacebIDLte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfacebIDLte(interfacebIDLte *string) *WirelessWirelessLinksListParams { + o.SetInterfacebIDLte(interfacebIDLte) + return o +} + +// SetInterfacebIDLte adds the interfaceBIdLte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfacebIDLte(interfacebIDLte *string) { + o.InterfacebIDLte = interfacebIDLte +} + +// WithInterfacebIDn adds the interfacebIDn to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithInterfacebIDn(interfacebIDn *string) *WirelessWirelessLinksListParams { + o.SetInterfacebIDn(interfacebIDn) + return o +} + +// SetInterfacebIDn adds the interfaceBIdN to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetInterfacebIDn(interfacebIDn *string) { + o.InterfacebIDn = interfacebIDn +} + +// WithLastUpdated adds the lastUpdated to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithLastUpdated(lastUpdated *string) *WirelessWirelessLinksListParams { + o.SetLastUpdated(lastUpdated) + return o +} + +// SetLastUpdated adds the lastUpdated to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetLastUpdated(lastUpdated *string) { + o.LastUpdated = lastUpdated +} + +// WithLastUpdatedGte adds the lastUpdatedGte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithLastUpdatedGte(lastUpdatedGte *string) *WirelessWirelessLinksListParams { + o.SetLastUpdatedGte(lastUpdatedGte) + return o +} + +// SetLastUpdatedGte adds the lastUpdatedGte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetLastUpdatedGte(lastUpdatedGte *string) { + o.LastUpdatedGte = lastUpdatedGte +} + +// WithLastUpdatedLte adds the lastUpdatedLte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithLastUpdatedLte(lastUpdatedLte *string) *WirelessWirelessLinksListParams { + o.SetLastUpdatedLte(lastUpdatedLte) + return o +} + +// SetLastUpdatedLte adds the lastUpdatedLte to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetLastUpdatedLte(lastUpdatedLte *string) { + o.LastUpdatedLte = lastUpdatedLte +} + +// WithLimit adds the limit to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithLimit(limit *int64) *WirelessWirelessLinksListParams { + o.SetLimit(limit) + return o +} + +// SetLimit adds the limit to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetLimit(limit *int64) { + o.Limit = limit +} + +// WithOffset adds the offset to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithOffset(offset *int64) *WirelessWirelessLinksListParams { + o.SetOffset(offset) + return o +} + +// SetOffset adds the offset to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetOffset(offset *int64) { + o.Offset = offset +} + +// WithQ adds the q to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithQ(q *string) *WirelessWirelessLinksListParams { + o.SetQ(q) + return o +} + +// SetQ adds the q to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetQ(q *string) { + o.Q = q +} + +// WithSsid adds the ssid to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithSsid(ssid *string) *WirelessWirelessLinksListParams { + o.SetSsid(ssid) + return o +} + +// SetSsid adds the ssid to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetSsid(ssid *string) { + o.Ssid = ssid +} + +// WithSsidEmpty adds the ssidEmpty to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithSsidEmpty(ssidEmpty *string) *WirelessWirelessLinksListParams { + o.SetSsidEmpty(ssidEmpty) + return o +} + +// SetSsidEmpty adds the ssidEmpty to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetSsidEmpty(ssidEmpty *string) { + o.SsidEmpty = ssidEmpty +} + +// WithSsidIc adds the ssidIc to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithSsidIc(ssidIc *string) *WirelessWirelessLinksListParams { + o.SetSsidIc(ssidIc) + return o +} + +// SetSsidIc adds the ssidIc to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetSsidIc(ssidIc *string) { + o.SsidIc = ssidIc +} + +// WithSsidIe adds the ssidIe to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithSsidIe(ssidIe *string) *WirelessWirelessLinksListParams { + o.SetSsidIe(ssidIe) + return o +} + +// SetSsidIe adds the ssidIe to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetSsidIe(ssidIe *string) { + o.SsidIe = ssidIe +} + +// WithSsidIew adds the ssidIew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithSsidIew(ssidIew *string) *WirelessWirelessLinksListParams { + o.SetSsidIew(ssidIew) + return o +} + +// SetSsidIew adds the ssidIew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetSsidIew(ssidIew *string) { + o.SsidIew = ssidIew +} + +// WithSsidIsw adds the ssidIsw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithSsidIsw(ssidIsw *string) *WirelessWirelessLinksListParams { + o.SetSsidIsw(ssidIsw) + return o +} + +// SetSsidIsw adds the ssidIsw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetSsidIsw(ssidIsw *string) { + o.SsidIsw = ssidIsw +} + +// WithSsidn adds the ssidn to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithSsidn(ssidn *string) *WirelessWirelessLinksListParams { + o.SetSsidn(ssidn) + return o +} + +// SetSsidn adds the ssidN to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetSsidn(ssidn *string) { + o.Ssidn = ssidn +} + +// WithSsidNic adds the ssidNic to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithSsidNic(ssidNic *string) *WirelessWirelessLinksListParams { + o.SetSsidNic(ssidNic) + return o +} + +// SetSsidNic adds the ssidNic to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetSsidNic(ssidNic *string) { + o.SsidNic = ssidNic +} + +// WithSsidNie adds the ssidNie to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithSsidNie(ssidNie *string) *WirelessWirelessLinksListParams { + o.SetSsidNie(ssidNie) + return o +} + +// SetSsidNie adds the ssidNie to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetSsidNie(ssidNie *string) { + o.SsidNie = ssidNie +} + +// WithSsidNiew adds the ssidNiew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithSsidNiew(ssidNiew *string) *WirelessWirelessLinksListParams { + o.SetSsidNiew(ssidNiew) + return o +} + +// SetSsidNiew adds the ssidNiew to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetSsidNiew(ssidNiew *string) { + o.SsidNiew = ssidNiew +} + +// WithSsidNisw adds the ssidNisw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithSsidNisw(ssidNisw *string) *WirelessWirelessLinksListParams { + o.SetSsidNisw(ssidNisw) + return o +} + +// SetSsidNisw adds the ssidNisw to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetSsidNisw(ssidNisw *string) { + o.SsidNisw = ssidNisw +} + +// WithStatus adds the status to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithStatus(status *string) *WirelessWirelessLinksListParams { + o.SetStatus(status) + return o +} + +// SetStatus adds the status to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetStatus(status *string) { + o.Status = status +} + +// WithStatusn adds the statusn to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithStatusn(statusn *string) *WirelessWirelessLinksListParams { + o.SetStatusn(statusn) + return o +} + +// SetStatusn adds the statusN to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetStatusn(statusn *string) { + o.Statusn = statusn +} + +// WithTag adds the tag to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithTag(tag *string) *WirelessWirelessLinksListParams { + o.SetTag(tag) + return o +} + +// SetTag adds the tag to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetTag(tag *string) { + o.Tag = tag +} + +// WithTagn adds the tagn to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) WithTagn(tagn *string) *WirelessWirelessLinksListParams { + o.SetTagn(tagn) + return o +} + +// SetTagn adds the tagN to the wireless wireless links list params +func (o *WirelessWirelessLinksListParams) SetTagn(tagn *string) { + o.Tagn = tagn +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLinksListParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + if o.AuthCipher != nil { + + // query param auth_cipher + var qrAuthCipher string + + if o.AuthCipher != nil { + qrAuthCipher = *o.AuthCipher + } + qAuthCipher := qrAuthCipher + if qAuthCipher != "" { + + if err := r.SetQueryParam("auth_cipher", qAuthCipher); err != nil { + return err + } + } + } + + if o.AuthCiphern != nil { + + // query param auth_cipher__n + var qrAuthCiphern string + + if o.AuthCiphern != nil { + qrAuthCiphern = *o.AuthCiphern + } + qAuthCiphern := qrAuthCiphern + if qAuthCiphern != "" { + + if err := r.SetQueryParam("auth_cipher__n", qAuthCiphern); err != nil { + return err + } + } + } + + if o.AuthPsk != nil { + + // query param auth_psk + var qrAuthPsk string + + if o.AuthPsk != nil { + qrAuthPsk = *o.AuthPsk + } + qAuthPsk := qrAuthPsk + if qAuthPsk != "" { + + if err := r.SetQueryParam("auth_psk", qAuthPsk); err != nil { + return err + } + } + } + + if o.AuthPskEmpty != nil { + + // query param auth_psk__empty + var qrAuthPskEmpty string + + if o.AuthPskEmpty != nil { + qrAuthPskEmpty = *o.AuthPskEmpty + } + qAuthPskEmpty := qrAuthPskEmpty + if qAuthPskEmpty != "" { + + if err := r.SetQueryParam("auth_psk__empty", qAuthPskEmpty); err != nil { + return err + } + } + } + + if o.AuthPskIc != nil { + + // query param auth_psk__ic + var qrAuthPskIc string + + if o.AuthPskIc != nil { + qrAuthPskIc = *o.AuthPskIc + } + qAuthPskIc := qrAuthPskIc + if qAuthPskIc != "" { + + if err := r.SetQueryParam("auth_psk__ic", qAuthPskIc); err != nil { + return err + } + } + } + + if o.AuthPskIe != nil { + + // query param auth_psk__ie + var qrAuthPskIe string + + if o.AuthPskIe != nil { + qrAuthPskIe = *o.AuthPskIe + } + qAuthPskIe := qrAuthPskIe + if qAuthPskIe != "" { + + if err := r.SetQueryParam("auth_psk__ie", qAuthPskIe); err != nil { + return err + } + } + } + + if o.AuthPskIew != nil { + + // query param auth_psk__iew + var qrAuthPskIew string + + if o.AuthPskIew != nil { + qrAuthPskIew = *o.AuthPskIew + } + qAuthPskIew := qrAuthPskIew + if qAuthPskIew != "" { + + if err := r.SetQueryParam("auth_psk__iew", qAuthPskIew); err != nil { + return err + } + } + } + + if o.AuthPskIsw != nil { + + // query param auth_psk__isw + var qrAuthPskIsw string + + if o.AuthPskIsw != nil { + qrAuthPskIsw = *o.AuthPskIsw + } + qAuthPskIsw := qrAuthPskIsw + if qAuthPskIsw != "" { + + if err := r.SetQueryParam("auth_psk__isw", qAuthPskIsw); err != nil { + return err + } + } + } + + if o.AuthPskn != nil { + + // query param auth_psk__n + var qrAuthPskn string + + if o.AuthPskn != nil { + qrAuthPskn = *o.AuthPskn + } + qAuthPskn := qrAuthPskn + if qAuthPskn != "" { + + if err := r.SetQueryParam("auth_psk__n", qAuthPskn); err != nil { + return err + } + } + } + + if o.AuthPskNic != nil { + + // query param auth_psk__nic + var qrAuthPskNic string + + if o.AuthPskNic != nil { + qrAuthPskNic = *o.AuthPskNic + } + qAuthPskNic := qrAuthPskNic + if qAuthPskNic != "" { + + if err := r.SetQueryParam("auth_psk__nic", qAuthPskNic); err != nil { + return err + } + } + } + + if o.AuthPskNie != nil { + + // query param auth_psk__nie + var qrAuthPskNie string + + if o.AuthPskNie != nil { + qrAuthPskNie = *o.AuthPskNie + } + qAuthPskNie := qrAuthPskNie + if qAuthPskNie != "" { + + if err := r.SetQueryParam("auth_psk__nie", qAuthPskNie); err != nil { + return err + } + } + } + + if o.AuthPskNiew != nil { + + // query param auth_psk__niew + var qrAuthPskNiew string + + if o.AuthPskNiew != nil { + qrAuthPskNiew = *o.AuthPskNiew + } + qAuthPskNiew := qrAuthPskNiew + if qAuthPskNiew != "" { + + if err := r.SetQueryParam("auth_psk__niew", qAuthPskNiew); err != nil { + return err + } + } + } + + if o.AuthPskNisw != nil { + + // query param auth_psk__nisw + var qrAuthPskNisw string + + if o.AuthPskNisw != nil { + qrAuthPskNisw = *o.AuthPskNisw + } + qAuthPskNisw := qrAuthPskNisw + if qAuthPskNisw != "" { + + if err := r.SetQueryParam("auth_psk__nisw", qAuthPskNisw); err != nil { + return err + } + } + } + + if o.AuthType != nil { + + // query param auth_type + var qrAuthType string + + if o.AuthType != nil { + qrAuthType = *o.AuthType + } + qAuthType := qrAuthType + if qAuthType != "" { + + if err := r.SetQueryParam("auth_type", qAuthType); err != nil { + return err + } + } + } + + if o.AuthTypen != nil { + + // query param auth_type__n + var qrAuthTypen string + + if o.AuthTypen != nil { + qrAuthTypen = *o.AuthTypen + } + qAuthTypen := qrAuthTypen + if qAuthTypen != "" { + + if err := r.SetQueryParam("auth_type__n", qAuthTypen); err != nil { + return err + } + } + } + + if o.Created != nil { + + // query param created + var qrCreated string + + if o.Created != nil { + qrCreated = *o.Created + } + qCreated := qrCreated + if qCreated != "" { + + if err := r.SetQueryParam("created", qCreated); err != nil { + return err + } + } + } + + if o.CreatedGte != nil { + + // query param created__gte + var qrCreatedGte string + + if o.CreatedGte != nil { + qrCreatedGte = *o.CreatedGte + } + qCreatedGte := qrCreatedGte + if qCreatedGte != "" { + + if err := r.SetQueryParam("created__gte", qCreatedGte); err != nil { + return err + } + } + } + + if o.CreatedLte != nil { + + // query param created__lte + var qrCreatedLte string + + if o.CreatedLte != nil { + qrCreatedLte = *o.CreatedLte + } + qCreatedLte := qrCreatedLte + if qCreatedLte != "" { + + if err := r.SetQueryParam("created__lte", qCreatedLte); err != nil { + return err + } + } + } + + if o.Description != nil { + + // query param description + var qrDescription string + + if o.Description != nil { + qrDescription = *o.Description + } + qDescription := qrDescription + if qDescription != "" { + + if err := r.SetQueryParam("description", qDescription); err != nil { + return err + } + } + } + + if o.DescriptionEmpty != nil { + + // query param description__empty + var qrDescriptionEmpty string + + if o.DescriptionEmpty != nil { + qrDescriptionEmpty = *o.DescriptionEmpty + } + qDescriptionEmpty := qrDescriptionEmpty + if qDescriptionEmpty != "" { + + if err := r.SetQueryParam("description__empty", qDescriptionEmpty); err != nil { + return err + } + } + } + + if o.DescriptionIc != nil { + + // query param description__ic + var qrDescriptionIc string + + if o.DescriptionIc != nil { + qrDescriptionIc = *o.DescriptionIc + } + qDescriptionIc := qrDescriptionIc + if qDescriptionIc != "" { + + if err := r.SetQueryParam("description__ic", qDescriptionIc); err != nil { + return err + } + } + } + + if o.DescriptionIe != nil { + + // query param description__ie + var qrDescriptionIe string + + if o.DescriptionIe != nil { + qrDescriptionIe = *o.DescriptionIe + } + qDescriptionIe := qrDescriptionIe + if qDescriptionIe != "" { + + if err := r.SetQueryParam("description__ie", qDescriptionIe); err != nil { + return err + } + } + } + + if o.DescriptionIew != nil { + + // query param description__iew + var qrDescriptionIew string + + if o.DescriptionIew != nil { + qrDescriptionIew = *o.DescriptionIew + } + qDescriptionIew := qrDescriptionIew + if qDescriptionIew != "" { + + if err := r.SetQueryParam("description__iew", qDescriptionIew); err != nil { + return err + } + } + } + + if o.DescriptionIsw != nil { + + // query param description__isw + var qrDescriptionIsw string + + if o.DescriptionIsw != nil { + qrDescriptionIsw = *o.DescriptionIsw + } + qDescriptionIsw := qrDescriptionIsw + if qDescriptionIsw != "" { + + if err := r.SetQueryParam("description__isw", qDescriptionIsw); err != nil { + return err + } + } + } + + if o.Descriptionn != nil { + + // query param description__n + var qrDescriptionn string + + if o.Descriptionn != nil { + qrDescriptionn = *o.Descriptionn + } + qDescriptionn := qrDescriptionn + if qDescriptionn != "" { + + if err := r.SetQueryParam("description__n", qDescriptionn); err != nil { + return err + } + } + } + + if o.DescriptionNic != nil { + + // query param description__nic + var qrDescriptionNic string + + if o.DescriptionNic != nil { + qrDescriptionNic = *o.DescriptionNic + } + qDescriptionNic := qrDescriptionNic + if qDescriptionNic != "" { + + if err := r.SetQueryParam("description__nic", qDescriptionNic); err != nil { + return err + } + } + } + + if o.DescriptionNie != nil { + + // query param description__nie + var qrDescriptionNie string + + if o.DescriptionNie != nil { + qrDescriptionNie = *o.DescriptionNie + } + qDescriptionNie := qrDescriptionNie + if qDescriptionNie != "" { + + if err := r.SetQueryParam("description__nie", qDescriptionNie); err != nil { + return err + } + } + } + + if o.DescriptionNiew != nil { + + // query param description__niew + var qrDescriptionNiew string + + if o.DescriptionNiew != nil { + qrDescriptionNiew = *o.DescriptionNiew + } + qDescriptionNiew := qrDescriptionNiew + if qDescriptionNiew != "" { + + if err := r.SetQueryParam("description__niew", qDescriptionNiew); err != nil { + return err + } + } + } + + if o.DescriptionNisw != nil { + + // query param description__nisw + var qrDescriptionNisw string + + if o.DescriptionNisw != nil { + qrDescriptionNisw = *o.DescriptionNisw + } + qDescriptionNisw := qrDescriptionNisw + if qDescriptionNisw != "" { + + if err := r.SetQueryParam("description__nisw", qDescriptionNisw); err != nil { + return err + } + } + } + + if o.ID != nil { + + // query param id + var qrID string + + if o.ID != nil { + qrID = *o.ID + } + qID := qrID + if qID != "" { + + if err := r.SetQueryParam("id", qID); err != nil { + return err + } + } + } + + if o.IDGt != nil { + + // query param id__gt + var qrIDGt string + + if o.IDGt != nil { + qrIDGt = *o.IDGt + } + qIDGt := qrIDGt + if qIDGt != "" { + + if err := r.SetQueryParam("id__gt", qIDGt); err != nil { + return err + } + } + } + + if o.IDGte != nil { + + // query param id__gte + var qrIDGte string + + if o.IDGte != nil { + qrIDGte = *o.IDGte + } + qIDGte := qrIDGte + if qIDGte != "" { + + if err := r.SetQueryParam("id__gte", qIDGte); err != nil { + return err + } + } + } + + if o.IDLt != nil { + + // query param id__lt + var qrIDLt string + + if o.IDLt != nil { + qrIDLt = *o.IDLt + } + qIDLt := qrIDLt + if qIDLt != "" { + + if err := r.SetQueryParam("id__lt", qIDLt); err != nil { + return err + } + } + } + + if o.IDLte != nil { + + // query param id__lte + var qrIDLte string + + if o.IDLte != nil { + qrIDLte = *o.IDLte + } + qIDLte := qrIDLte + if qIDLte != "" { + + if err := r.SetQueryParam("id__lte", qIDLte); err != nil { + return err + } + } + } + + if o.IDn != nil { + + // query param id__n + var qrIDn string + + if o.IDn != nil { + qrIDn = *o.IDn + } + qIDn := qrIDn + if qIDn != "" { + + if err := r.SetQueryParam("id__n", qIDn); err != nil { + return err + } + } + } + + if o.InterfaceaID != nil { + + // query param interface_a_id + var qrInterfaceaID string + + if o.InterfaceaID != nil { + qrInterfaceaID = *o.InterfaceaID + } + qInterfaceaID := qrInterfaceaID + if qInterfaceaID != "" { + + if err := r.SetQueryParam("interface_a_id", qInterfaceaID); err != nil { + return err + } + } + } + + if o.InterfaceaIDGt != nil { + + // query param interface_a_id__gt + var qrInterfaceaIDGt string + + if o.InterfaceaIDGt != nil { + qrInterfaceaIDGt = *o.InterfaceaIDGt + } + qInterfaceaIDGt := qrInterfaceaIDGt + if qInterfaceaIDGt != "" { + + if err := r.SetQueryParam("interface_a_id__gt", qInterfaceaIDGt); err != nil { + return err + } + } + } + + if o.InterfaceaIDGte != nil { + + // query param interface_a_id__gte + var qrInterfaceaIDGte string + + if o.InterfaceaIDGte != nil { + qrInterfaceaIDGte = *o.InterfaceaIDGte + } + qInterfaceaIDGte := qrInterfaceaIDGte + if qInterfaceaIDGte != "" { + + if err := r.SetQueryParam("interface_a_id__gte", qInterfaceaIDGte); err != nil { + return err + } + } + } + + if o.InterfaceaIDLt != nil { + + // query param interface_a_id__lt + var qrInterfaceaIDLt string + + if o.InterfaceaIDLt != nil { + qrInterfaceaIDLt = *o.InterfaceaIDLt + } + qInterfaceaIDLt := qrInterfaceaIDLt + if qInterfaceaIDLt != "" { + + if err := r.SetQueryParam("interface_a_id__lt", qInterfaceaIDLt); err != nil { + return err + } + } + } + + if o.InterfaceaIDLte != nil { + + // query param interface_a_id__lte + var qrInterfaceaIDLte string + + if o.InterfaceaIDLte != nil { + qrInterfaceaIDLte = *o.InterfaceaIDLte + } + qInterfaceaIDLte := qrInterfaceaIDLte + if qInterfaceaIDLte != "" { + + if err := r.SetQueryParam("interface_a_id__lte", qInterfaceaIDLte); err != nil { + return err + } + } + } + + if o.InterfaceaIDn != nil { + + // query param interface_a_id__n + var qrInterfaceaIDn string + + if o.InterfaceaIDn != nil { + qrInterfaceaIDn = *o.InterfaceaIDn + } + qInterfaceaIDn := qrInterfaceaIDn + if qInterfaceaIDn != "" { + + if err := r.SetQueryParam("interface_a_id__n", qInterfaceaIDn); err != nil { + return err + } + } + } + + if o.InterfacebID != nil { + + // query param interface_b_id + var qrInterfacebID string + + if o.InterfacebID != nil { + qrInterfacebID = *o.InterfacebID + } + qInterfacebID := qrInterfacebID + if qInterfacebID != "" { + + if err := r.SetQueryParam("interface_b_id", qInterfacebID); err != nil { + return err + } + } + } + + if o.InterfacebIDGt != nil { + + // query param interface_b_id__gt + var qrInterfacebIDGt string + + if o.InterfacebIDGt != nil { + qrInterfacebIDGt = *o.InterfacebIDGt + } + qInterfacebIDGt := qrInterfacebIDGt + if qInterfacebIDGt != "" { + + if err := r.SetQueryParam("interface_b_id__gt", qInterfacebIDGt); err != nil { + return err + } + } + } + + if o.InterfacebIDGte != nil { + + // query param interface_b_id__gte + var qrInterfacebIDGte string + + if o.InterfacebIDGte != nil { + qrInterfacebIDGte = *o.InterfacebIDGte + } + qInterfacebIDGte := qrInterfacebIDGte + if qInterfacebIDGte != "" { + + if err := r.SetQueryParam("interface_b_id__gte", qInterfacebIDGte); err != nil { + return err + } + } + } + + if o.InterfacebIDLt != nil { + + // query param interface_b_id__lt + var qrInterfacebIDLt string + + if o.InterfacebIDLt != nil { + qrInterfacebIDLt = *o.InterfacebIDLt + } + qInterfacebIDLt := qrInterfacebIDLt + if qInterfacebIDLt != "" { + + if err := r.SetQueryParam("interface_b_id__lt", qInterfacebIDLt); err != nil { + return err + } + } + } + + if o.InterfacebIDLte != nil { + + // query param interface_b_id__lte + var qrInterfacebIDLte string + + if o.InterfacebIDLte != nil { + qrInterfacebIDLte = *o.InterfacebIDLte + } + qInterfacebIDLte := qrInterfacebIDLte + if qInterfacebIDLte != "" { + + if err := r.SetQueryParam("interface_b_id__lte", qInterfacebIDLte); err != nil { + return err + } + } + } + + if o.InterfacebIDn != nil { + + // query param interface_b_id__n + var qrInterfacebIDn string + + if o.InterfacebIDn != nil { + qrInterfacebIDn = *o.InterfacebIDn + } + qInterfacebIDn := qrInterfacebIDn + if qInterfacebIDn != "" { + + if err := r.SetQueryParam("interface_b_id__n", qInterfacebIDn); err != nil { + return err + } + } + } + + if o.LastUpdated != nil { + + // query param last_updated + var qrLastUpdated string + + if o.LastUpdated != nil { + qrLastUpdated = *o.LastUpdated + } + qLastUpdated := qrLastUpdated + if qLastUpdated != "" { + + if err := r.SetQueryParam("last_updated", qLastUpdated); err != nil { + return err + } + } + } + + if o.LastUpdatedGte != nil { + + // query param last_updated__gte + var qrLastUpdatedGte string + + if o.LastUpdatedGte != nil { + qrLastUpdatedGte = *o.LastUpdatedGte + } + qLastUpdatedGte := qrLastUpdatedGte + if qLastUpdatedGte != "" { + + if err := r.SetQueryParam("last_updated__gte", qLastUpdatedGte); err != nil { + return err + } + } + } + + if o.LastUpdatedLte != nil { + + // query param last_updated__lte + var qrLastUpdatedLte string + + if o.LastUpdatedLte != nil { + qrLastUpdatedLte = *o.LastUpdatedLte + } + qLastUpdatedLte := qrLastUpdatedLte + if qLastUpdatedLte != "" { + + if err := r.SetQueryParam("last_updated__lte", qLastUpdatedLte); err != nil { + return err + } + } + } + + if o.Limit != nil { + + // query param limit + var qrLimit int64 + + if o.Limit != nil { + qrLimit = *o.Limit + } + qLimit := swag.FormatInt64(qrLimit) + if qLimit != "" { + + if err := r.SetQueryParam("limit", qLimit); err != nil { + return err + } + } + } + + if o.Offset != nil { + + // query param offset + var qrOffset int64 + + if o.Offset != nil { + qrOffset = *o.Offset + } + qOffset := swag.FormatInt64(qrOffset) + if qOffset != "" { + + if err := r.SetQueryParam("offset", qOffset); err != nil { + return err + } + } + } + + if o.Q != nil { + + // query param q + var qrQ string + + if o.Q != nil { + qrQ = *o.Q + } + qQ := qrQ + if qQ != "" { + + if err := r.SetQueryParam("q", qQ); err != nil { + return err + } + } + } + + if o.Ssid != nil { + + // query param ssid + var qrSsid string + + if o.Ssid != nil { + qrSsid = *o.Ssid + } + qSsid := qrSsid + if qSsid != "" { + + if err := r.SetQueryParam("ssid", qSsid); err != nil { + return err + } + } + } + + if o.SsidEmpty != nil { + + // query param ssid__empty + var qrSsidEmpty string + + if o.SsidEmpty != nil { + qrSsidEmpty = *o.SsidEmpty + } + qSsidEmpty := qrSsidEmpty + if qSsidEmpty != "" { + + if err := r.SetQueryParam("ssid__empty", qSsidEmpty); err != nil { + return err + } + } + } + + if o.SsidIc != nil { + + // query param ssid__ic + var qrSsidIc string + + if o.SsidIc != nil { + qrSsidIc = *o.SsidIc + } + qSsidIc := qrSsidIc + if qSsidIc != "" { + + if err := r.SetQueryParam("ssid__ic", qSsidIc); err != nil { + return err + } + } + } + + if o.SsidIe != nil { + + // query param ssid__ie + var qrSsidIe string + + if o.SsidIe != nil { + qrSsidIe = *o.SsidIe + } + qSsidIe := qrSsidIe + if qSsidIe != "" { + + if err := r.SetQueryParam("ssid__ie", qSsidIe); err != nil { + return err + } + } + } + + if o.SsidIew != nil { + + // query param ssid__iew + var qrSsidIew string + + if o.SsidIew != nil { + qrSsidIew = *o.SsidIew + } + qSsidIew := qrSsidIew + if qSsidIew != "" { + + if err := r.SetQueryParam("ssid__iew", qSsidIew); err != nil { + return err + } + } + } + + if o.SsidIsw != nil { + + // query param ssid__isw + var qrSsidIsw string + + if o.SsidIsw != nil { + qrSsidIsw = *o.SsidIsw + } + qSsidIsw := qrSsidIsw + if qSsidIsw != "" { + + if err := r.SetQueryParam("ssid__isw", qSsidIsw); err != nil { + return err + } + } + } + + if o.Ssidn != nil { + + // query param ssid__n + var qrSsidn string + + if o.Ssidn != nil { + qrSsidn = *o.Ssidn + } + qSsidn := qrSsidn + if qSsidn != "" { + + if err := r.SetQueryParam("ssid__n", qSsidn); err != nil { + return err + } + } + } + + if o.SsidNic != nil { + + // query param ssid__nic + var qrSsidNic string + + if o.SsidNic != nil { + qrSsidNic = *o.SsidNic + } + qSsidNic := qrSsidNic + if qSsidNic != "" { + + if err := r.SetQueryParam("ssid__nic", qSsidNic); err != nil { + return err + } + } + } + + if o.SsidNie != nil { + + // query param ssid__nie + var qrSsidNie string + + if o.SsidNie != nil { + qrSsidNie = *o.SsidNie + } + qSsidNie := qrSsidNie + if qSsidNie != "" { + + if err := r.SetQueryParam("ssid__nie", qSsidNie); err != nil { + return err + } + } + } + + if o.SsidNiew != nil { + + // query param ssid__niew + var qrSsidNiew string + + if o.SsidNiew != nil { + qrSsidNiew = *o.SsidNiew + } + qSsidNiew := qrSsidNiew + if qSsidNiew != "" { + + if err := r.SetQueryParam("ssid__niew", qSsidNiew); err != nil { + return err + } + } + } + + if o.SsidNisw != nil { + + // query param ssid__nisw + var qrSsidNisw string + + if o.SsidNisw != nil { + qrSsidNisw = *o.SsidNisw + } + qSsidNisw := qrSsidNisw + if qSsidNisw != "" { + + if err := r.SetQueryParam("ssid__nisw", qSsidNisw); err != nil { + return err + } + } + } + + if o.Status != nil { + + // query param status + var qrStatus string + + if o.Status != nil { + qrStatus = *o.Status + } + qStatus := qrStatus + if qStatus != "" { + + if err := r.SetQueryParam("status", qStatus); err != nil { + return err + } + } + } + + if o.Statusn != nil { + + // query param status__n + var qrStatusn string + + if o.Statusn != nil { + qrStatusn = *o.Statusn + } + qStatusn := qrStatusn + if qStatusn != "" { + + if err := r.SetQueryParam("status__n", qStatusn); err != nil { + return err + } + } + } + + if o.Tag != nil { + + // query param tag + var qrTag string + + if o.Tag != nil { + qrTag = *o.Tag + } + qTag := qrTag + if qTag != "" { + + if err := r.SetQueryParam("tag", qTag); err != nil { + return err + } + } + } + + if o.Tagn != nil { + + // query param tag__n + var qrTagn string + + if o.Tagn != nil { + qrTagn = *o.Tagn + } + qTagn := qrTagn + if qTagn != "" { + + if err := r.SetQueryParam("tag__n", qTagn); err != nil { + return err + } + } + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_list_responses.go b/netbox/client/wireless/wireless_wireless_links_list_responses.go new file mode 100644 index 00000000..1e0de2ed --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_list_responses.go @@ -0,0 +1,247 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "fmt" + "io" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLinksListReader is a Reader for the WirelessWirelessLinksList structure. +type WirelessWirelessLinksListReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLinksListReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLinksListOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLinksListOK creates a WirelessWirelessLinksListOK with default headers values +func NewWirelessWirelessLinksListOK() *WirelessWirelessLinksListOK { + return &WirelessWirelessLinksListOK{} +} + +/* WirelessWirelessLinksListOK describes a response with status code 200, with default header values. + +WirelessWirelessLinksListOK wireless wireless links list o k +*/ +type WirelessWirelessLinksListOK struct { + Payload *WirelessWirelessLinksListOKBody +} + +func (o *WirelessWirelessLinksListOK) Error() string { + return fmt.Sprintf("[GET /wireless/wireless-links/][%d] wirelessWirelessLinksListOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLinksListOK) GetPayload() *WirelessWirelessLinksListOKBody { + return o.Payload +} + +func (o *WirelessWirelessLinksListOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(WirelessWirelessLinksListOKBody) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} + +/*WirelessWirelessLinksListOKBody wireless wireless links list o k body +swagger:model WirelessWirelessLinksListOKBody +*/ +type WirelessWirelessLinksListOKBody struct { + + // count + // Required: true + Count *int64 `json:"count"` + + // next + // Format: uri + Next *strfmt.URI `json:"next,omitempty"` + + // previous + // Format: uri + Previous *strfmt.URI `json:"previous,omitempty"` + + // results + // Required: true + Results []*models.WirelessLink `json:"results"` +} + +// Validate validates this wireless wireless links list o k body +func (o *WirelessWirelessLinksListOKBody) Validate(formats strfmt.Registry) error { + var res []error + + if err := o.validateCount(formats); err != nil { + res = append(res, err) + } + + if err := o.validateNext(formats); err != nil { + res = append(res, err) + } + + if err := o.validatePrevious(formats); err != nil { + res = append(res, err) + } + + if err := o.validateResults(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *WirelessWirelessLinksListOKBody) validateCount(formats strfmt.Registry) error { + + if err := validate.Required("wirelessWirelessLinksListOK"+"."+"count", "body", o.Count); err != nil { + return err + } + + return nil +} + +func (o *WirelessWirelessLinksListOKBody) validateNext(formats strfmt.Registry) error { + if swag.IsZero(o.Next) { // not required + return nil + } + + if err := validate.FormatOf("wirelessWirelessLinksListOK"+"."+"next", "body", "uri", o.Next.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *WirelessWirelessLinksListOKBody) validatePrevious(formats strfmt.Registry) error { + if swag.IsZero(o.Previous) { // not required + return nil + } + + if err := validate.FormatOf("wirelessWirelessLinksListOK"+"."+"previous", "body", "uri", o.Previous.String(), formats); err != nil { + return err + } + + return nil +} + +func (o *WirelessWirelessLinksListOKBody) validateResults(formats strfmt.Registry) error { + + if err := validate.Required("wirelessWirelessLinksListOK"+"."+"results", "body", o.Results); err != nil { + return err + } + + for i := 0; i < len(o.Results); i++ { + if swag.IsZero(o.Results[i]) { // not required + continue + } + + if o.Results[i] != nil { + if err := o.Results[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("wirelessWirelessLinksListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("wirelessWirelessLinksListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// ContextValidate validate this wireless wireless links list o k body based on the context it is used +func (o *WirelessWirelessLinksListOKBody) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := o.contextValidateResults(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (o *WirelessWirelessLinksListOKBody) contextValidateResults(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(o.Results); i++ { + + if o.Results[i] != nil { + if err := o.Results[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("wirelessWirelessLinksListOK" + "." + "results" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("wirelessWirelessLinksListOK" + "." + "results" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +// MarshalBinary interface implementation +func (o *WirelessWirelessLinksListOKBody) MarshalBinary() ([]byte, error) { + if o == nil { + return nil, nil + } + return swag.WriteJSON(o) +} + +// UnmarshalBinary interface implementation +func (o *WirelessWirelessLinksListOKBody) UnmarshalBinary(b []byte) error { + var res WirelessWirelessLinksListOKBody + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *o = res + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_partial_update_parameters.go b/netbox/client/wireless/wireless_wireless_links_partial_update_parameters.go new file mode 100644 index 00000000..2e8ed853 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_partial_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLinksPartialUpdateParams creates a new WirelessWirelessLinksPartialUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLinksPartialUpdateParams() *WirelessWirelessLinksPartialUpdateParams { + return &WirelessWirelessLinksPartialUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLinksPartialUpdateParamsWithTimeout creates a new WirelessWirelessLinksPartialUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLinksPartialUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLinksPartialUpdateParams { + return &WirelessWirelessLinksPartialUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLinksPartialUpdateParamsWithContext creates a new WirelessWirelessLinksPartialUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLinksPartialUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLinksPartialUpdateParams { + return &WirelessWirelessLinksPartialUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLinksPartialUpdateParamsWithHTTPClient creates a new WirelessWirelessLinksPartialUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLinksPartialUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLinksPartialUpdateParams { + return &WirelessWirelessLinksPartialUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLinksPartialUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless links partial update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLinksPartialUpdateParams struct { + + // Data. + Data *models.WritableWirelessLink + + /* ID. + + A unique integer value identifying this wireless link. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless links partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksPartialUpdateParams) WithDefaults() *WirelessWirelessLinksPartialUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless links partial update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksPartialUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless links partial update params +func (o *WirelessWirelessLinksPartialUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLinksPartialUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless links partial update params +func (o *WirelessWirelessLinksPartialUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless links partial update params +func (o *WirelessWirelessLinksPartialUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLinksPartialUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless links partial update params +func (o *WirelessWirelessLinksPartialUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless links partial update params +func (o *WirelessWirelessLinksPartialUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLinksPartialUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless links partial update params +func (o *WirelessWirelessLinksPartialUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless links partial update params +func (o *WirelessWirelessLinksPartialUpdateParams) WithData(data *models.WritableWirelessLink) *WirelessWirelessLinksPartialUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless links partial update params +func (o *WirelessWirelessLinksPartialUpdateParams) SetData(data *models.WritableWirelessLink) { + o.Data = data +} + +// WithID adds the id to the wireless wireless links partial update params +func (o *WirelessWirelessLinksPartialUpdateParams) WithID(id int64) *WirelessWirelessLinksPartialUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless links partial update params +func (o *WirelessWirelessLinksPartialUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLinksPartialUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_partial_update_responses.go b/netbox/client/wireless/wireless_wireless_links_partial_update_responses.go new file mode 100644 index 00000000..9a011c05 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_partial_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLinksPartialUpdateReader is a Reader for the WirelessWirelessLinksPartialUpdate structure. +type WirelessWirelessLinksPartialUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLinksPartialUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLinksPartialUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLinksPartialUpdateOK creates a WirelessWirelessLinksPartialUpdateOK with default headers values +func NewWirelessWirelessLinksPartialUpdateOK() *WirelessWirelessLinksPartialUpdateOK { + return &WirelessWirelessLinksPartialUpdateOK{} +} + +/* WirelessWirelessLinksPartialUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLinksPartialUpdateOK wireless wireless links partial update o k +*/ +type WirelessWirelessLinksPartialUpdateOK struct { + Payload *models.WirelessLink +} + +func (o *WirelessWirelessLinksPartialUpdateOK) Error() string { + return fmt.Sprintf("[PATCH /wireless/wireless-links/{id}/][%d] wirelessWirelessLinksPartialUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLinksPartialUpdateOK) GetPayload() *models.WirelessLink { + return o.Payload +} + +func (o *WirelessWirelessLinksPartialUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLink) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_read_parameters.go b/netbox/client/wireless/wireless_wireless_links_read_parameters.go new file mode 100644 index 00000000..cb4bb880 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_read_parameters.go @@ -0,0 +1,165 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" +) + +// NewWirelessWirelessLinksReadParams creates a new WirelessWirelessLinksReadParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLinksReadParams() *WirelessWirelessLinksReadParams { + return &WirelessWirelessLinksReadParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLinksReadParamsWithTimeout creates a new WirelessWirelessLinksReadParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLinksReadParamsWithTimeout(timeout time.Duration) *WirelessWirelessLinksReadParams { + return &WirelessWirelessLinksReadParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLinksReadParamsWithContext creates a new WirelessWirelessLinksReadParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLinksReadParamsWithContext(ctx context.Context) *WirelessWirelessLinksReadParams { + return &WirelessWirelessLinksReadParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLinksReadParamsWithHTTPClient creates a new WirelessWirelessLinksReadParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLinksReadParamsWithHTTPClient(client *http.Client) *WirelessWirelessLinksReadParams { + return &WirelessWirelessLinksReadParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLinksReadParams contains all the parameters to send to the API endpoint + for the wireless wireless links read operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLinksReadParams struct { + + /* ID. + + A unique integer value identifying this wireless link. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless links read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksReadParams) WithDefaults() *WirelessWirelessLinksReadParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless links read params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksReadParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless links read params +func (o *WirelessWirelessLinksReadParams) WithTimeout(timeout time.Duration) *WirelessWirelessLinksReadParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless links read params +func (o *WirelessWirelessLinksReadParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless links read params +func (o *WirelessWirelessLinksReadParams) WithContext(ctx context.Context) *WirelessWirelessLinksReadParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless links read params +func (o *WirelessWirelessLinksReadParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless links read params +func (o *WirelessWirelessLinksReadParams) WithHTTPClient(client *http.Client) *WirelessWirelessLinksReadParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless links read params +func (o *WirelessWirelessLinksReadParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithID adds the id to the wireless wireless links read params +func (o *WirelessWirelessLinksReadParams) WithID(id int64) *WirelessWirelessLinksReadParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless links read params +func (o *WirelessWirelessLinksReadParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLinksReadParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_read_responses.go b/netbox/client/wireless/wireless_wireless_links_read_responses.go new file mode 100644 index 00000000..4fa0499e --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_read_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLinksReadReader is a Reader for the WirelessWirelessLinksRead structure. +type WirelessWirelessLinksReadReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLinksReadReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLinksReadOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLinksReadOK creates a WirelessWirelessLinksReadOK with default headers values +func NewWirelessWirelessLinksReadOK() *WirelessWirelessLinksReadOK { + return &WirelessWirelessLinksReadOK{} +} + +/* WirelessWirelessLinksReadOK describes a response with status code 200, with default header values. + +WirelessWirelessLinksReadOK wireless wireless links read o k +*/ +type WirelessWirelessLinksReadOK struct { + Payload *models.WirelessLink +} + +func (o *WirelessWirelessLinksReadOK) Error() string { + return fmt.Sprintf("[GET /wireless/wireless-links/{id}/][%d] wirelessWirelessLinksReadOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLinksReadOK) GetPayload() *models.WirelessLink { + return o.Payload +} + +func (o *WirelessWirelessLinksReadOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLink) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_update_parameters.go b/netbox/client/wireless/wireless_wireless_links_update_parameters.go new file mode 100644 index 00000000..819504d5 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_update_parameters.go @@ -0,0 +1,186 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "net/http" + "time" + + "github.com/go-openapi/errors" + "github.com/go-openapi/runtime" + cr "github.com/go-openapi/runtime/client" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + + "github.com/smutel/go-netbox/netbox/models" +) + +// NewWirelessWirelessLinksUpdateParams creates a new WirelessWirelessLinksUpdateParams object, +// with the default timeout for this client. +// +// Default values are not hydrated, since defaults are normally applied by the API server side. +// +// To enforce default values in parameter, use SetDefaults or WithDefaults. +func NewWirelessWirelessLinksUpdateParams() *WirelessWirelessLinksUpdateParams { + return &WirelessWirelessLinksUpdateParams{ + timeout: cr.DefaultTimeout, + } +} + +// NewWirelessWirelessLinksUpdateParamsWithTimeout creates a new WirelessWirelessLinksUpdateParams object +// with the ability to set a timeout on a request. +func NewWirelessWirelessLinksUpdateParamsWithTimeout(timeout time.Duration) *WirelessWirelessLinksUpdateParams { + return &WirelessWirelessLinksUpdateParams{ + timeout: timeout, + } +} + +// NewWirelessWirelessLinksUpdateParamsWithContext creates a new WirelessWirelessLinksUpdateParams object +// with the ability to set a context for a request. +func NewWirelessWirelessLinksUpdateParamsWithContext(ctx context.Context) *WirelessWirelessLinksUpdateParams { + return &WirelessWirelessLinksUpdateParams{ + Context: ctx, + } +} + +// NewWirelessWirelessLinksUpdateParamsWithHTTPClient creates a new WirelessWirelessLinksUpdateParams object +// with the ability to set a custom HTTPClient for a request. +func NewWirelessWirelessLinksUpdateParamsWithHTTPClient(client *http.Client) *WirelessWirelessLinksUpdateParams { + return &WirelessWirelessLinksUpdateParams{ + HTTPClient: client, + } +} + +/* WirelessWirelessLinksUpdateParams contains all the parameters to send to the API endpoint + for the wireless wireless links update operation. + + Typically these are written to a http.Request. +*/ +type WirelessWirelessLinksUpdateParams struct { + + // Data. + Data *models.WritableWirelessLink + + /* ID. + + A unique integer value identifying this wireless link. + */ + ID int64 + + timeout time.Duration + Context context.Context + HTTPClient *http.Client +} + +// WithDefaults hydrates default values in the wireless wireless links update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksUpdateParams) WithDefaults() *WirelessWirelessLinksUpdateParams { + o.SetDefaults() + return o +} + +// SetDefaults hydrates default values in the wireless wireless links update params (not the query body). +// +// All values with no default are reset to their zero value. +func (o *WirelessWirelessLinksUpdateParams) SetDefaults() { + // no default values defined for this parameter +} + +// WithTimeout adds the timeout to the wireless wireless links update params +func (o *WirelessWirelessLinksUpdateParams) WithTimeout(timeout time.Duration) *WirelessWirelessLinksUpdateParams { + o.SetTimeout(timeout) + return o +} + +// SetTimeout adds the timeout to the wireless wireless links update params +func (o *WirelessWirelessLinksUpdateParams) SetTimeout(timeout time.Duration) { + o.timeout = timeout +} + +// WithContext adds the context to the wireless wireless links update params +func (o *WirelessWirelessLinksUpdateParams) WithContext(ctx context.Context) *WirelessWirelessLinksUpdateParams { + o.SetContext(ctx) + return o +} + +// SetContext adds the context to the wireless wireless links update params +func (o *WirelessWirelessLinksUpdateParams) SetContext(ctx context.Context) { + o.Context = ctx +} + +// WithHTTPClient adds the HTTPClient to the wireless wireless links update params +func (o *WirelessWirelessLinksUpdateParams) WithHTTPClient(client *http.Client) *WirelessWirelessLinksUpdateParams { + o.SetHTTPClient(client) + return o +} + +// SetHTTPClient adds the HTTPClient to the wireless wireless links update params +func (o *WirelessWirelessLinksUpdateParams) SetHTTPClient(client *http.Client) { + o.HTTPClient = client +} + +// WithData adds the data to the wireless wireless links update params +func (o *WirelessWirelessLinksUpdateParams) WithData(data *models.WritableWirelessLink) *WirelessWirelessLinksUpdateParams { + o.SetData(data) + return o +} + +// SetData adds the data to the wireless wireless links update params +func (o *WirelessWirelessLinksUpdateParams) SetData(data *models.WritableWirelessLink) { + o.Data = data +} + +// WithID adds the id to the wireless wireless links update params +func (o *WirelessWirelessLinksUpdateParams) WithID(id int64) *WirelessWirelessLinksUpdateParams { + o.SetID(id) + return o +} + +// SetID adds the id to the wireless wireless links update params +func (o *WirelessWirelessLinksUpdateParams) SetID(id int64) { + o.ID = id +} + +// WriteToRequest writes these params to a swagger request +func (o *WirelessWirelessLinksUpdateParams) WriteToRequest(r runtime.ClientRequest, reg strfmt.Registry) error { + + if err := r.SetTimeout(o.timeout); err != nil { + return err + } + var res []error + if o.Data != nil { + if err := r.SetBodyParam(o.Data); err != nil { + return err + } + } + + // path param id + if err := r.SetPathParam("id", swag.FormatInt64(o.ID)); err != nil { + return err + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} diff --git a/netbox/client/wireless/wireless_wireless_links_update_responses.go b/netbox/client/wireless/wireless_wireless_links_update_responses.go new file mode 100644 index 00000000..7cfaf7e6 --- /dev/null +++ b/netbox/client/wireless/wireless_wireless_links_update_responses.go @@ -0,0 +1,82 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package wireless + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "fmt" + "io" + + "github.com/go-openapi/runtime" + "github.com/go-openapi/strfmt" + + "github.com/smutel/go-netbox/netbox/models" +) + +// WirelessWirelessLinksUpdateReader is a Reader for the WirelessWirelessLinksUpdate structure. +type WirelessWirelessLinksUpdateReader struct { + formats strfmt.Registry +} + +// ReadResponse reads a server response into the received o. +func (o *WirelessWirelessLinksUpdateReader) ReadResponse(response runtime.ClientResponse, consumer runtime.Consumer) (interface{}, error) { + switch response.Code() { + case 200: + result := NewWirelessWirelessLinksUpdateOK() + if err := result.readResponse(response, consumer, o.formats); err != nil { + return nil, err + } + return result, nil + default: + return nil, runtime.NewAPIError("response status code does not match any response statuses defined for this endpoint in the swagger spec", response, response.Code()) + } +} + +// NewWirelessWirelessLinksUpdateOK creates a WirelessWirelessLinksUpdateOK with default headers values +func NewWirelessWirelessLinksUpdateOK() *WirelessWirelessLinksUpdateOK { + return &WirelessWirelessLinksUpdateOK{} +} + +/* WirelessWirelessLinksUpdateOK describes a response with status code 200, with default header values. + +WirelessWirelessLinksUpdateOK wireless wireless links update o k +*/ +type WirelessWirelessLinksUpdateOK struct { + Payload *models.WirelessLink +} + +func (o *WirelessWirelessLinksUpdateOK) Error() string { + return fmt.Sprintf("[PUT /wireless/wireless-links/{id}/][%d] wirelessWirelessLinksUpdateOK %+v", 200, o.Payload) +} +func (o *WirelessWirelessLinksUpdateOK) GetPayload() *models.WirelessLink { + return o.Payload +} + +func (o *WirelessWirelessLinksUpdateOK) readResponse(response runtime.ClientResponse, consumer runtime.Consumer, formats strfmt.Registry) error { + + o.Payload = new(models.WirelessLink) + + // response payload + if err := consumer.Consume(response.Body(), o.Payload); err != nil && err != io.EOF { + return err + } + + return nil +} diff --git a/netbox/models/a_s_n.go b/netbox/models/a_s_n.go new file mode 100644 index 00000000..96b796ec --- /dev/null +++ b/netbox/models/a_s_n.go @@ -0,0 +1,400 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// ASN a s n +// +// swagger:model ASN +type ASN struct { + + // ASN + // + // 32-bit autonomous system number + // Required: true + // Maximum: 4.294967295e+09 + // Minimum: 1 + Asn *int64 `json:"asn"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // RIR + // Required: true + Rir *int64 `json:"rir"` + + // Site count + // Read Only: true + SiteCount int64 `json:"site_count,omitempty"` + + // tags + Tags []*NestedTag `json:"tags"` + + // tenant + Tenant *NestedTenant `json:"tenant,omitempty"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this a s n +func (m *ASN) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAsn(formats); err != nil { + res = append(res, err) + } + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateRir(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTenant(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ASN) validateAsn(formats strfmt.Registry) error { + + if err := validate.Required("asn", "body", m.Asn); err != nil { + return err + } + + if err := validate.MinimumInt("asn", "body", *m.Asn, 1, false); err != nil { + return err + } + + if err := validate.MaximumInt("asn", "body", *m.Asn, 4.294967295e+09, false); err != nil { + return err + } + + return nil +} + +func (m *ASN) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *ASN) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *ASN) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *ASN) validateRir(formats strfmt.Registry) error { + + if err := validate.Required("rir", "body", m.Rir); err != nil { + return err + } + + return nil +} + +func (m *ASN) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *ASN) validateTenant(formats strfmt.Registry) error { + if swag.IsZero(m.Tenant) { // not required + return nil + } + + if m.Tenant != nil { + if err := m.Tenant.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenant") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenant") + } + return err + } + } + + return nil +} + +func (m *ASN) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this a s n based on the context it is used +func (m *ASN) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateSiteCount(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTenant(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ASN) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *ASN) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *ASN) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *ASN) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *ASN) contextValidateSiteCount(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "site_count", "body", int64(m.SiteCount)); err != nil { + return err + } + + return nil +} + +func (m *ASN) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *ASN) contextValidateTenant(ctx context.Context, formats strfmt.Registry) error { + + if m.Tenant != nil { + if err := m.Tenant.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenant") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenant") + } + return err + } + } + + return nil +} + +func (m *ASN) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *ASN) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *ASN) UnmarshalBinary(b []byte) error { + var res ASN + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/cable.go b/netbox/models/cable.go index b434313d..038df470 100644 --- a/netbox/models/cable.go +++ b/netbox/models/cable.go @@ -41,6 +41,11 @@ type Cable struct { // Pattern: ^[0-9a-f]{6}$ Color string `json:"color,omitempty"` + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Custom fields CustomFields interface{} `json:"custom_fields,omitempty"` @@ -56,6 +61,11 @@ type Cable struct { // Max Length: 100 Label string `json:"label,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Length Length *float64 `json:"length,omitempty"` @@ -68,6 +78,9 @@ type Cable struct { // tags Tags []*NestedTag `json:"tags"` + // tenant + Tenant *NestedTenant `json:"tenant,omitempty"` + // Termination a // Read Only: true Terminationa map[string]*string `json:"termination_a,omitempty"` @@ -114,10 +127,18 @@ func (m *Cable) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateLabel(formats); err != nil { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateLengthUnit(formats); err != nil { res = append(res, err) } @@ -130,6 +151,10 @@ func (m *Cable) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTenant(formats); err != nil { + res = append(res, err) + } + if err := m.validateTerminationaID(formats); err != nil { res = append(res, err) } @@ -176,6 +201,18 @@ func (m *Cable) validateColor(formats strfmt.Registry) error { return nil } +func (m *Cable) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *Cable) validateLabel(formats strfmt.Registry) error { if swag.IsZero(m.Label) { // not required return nil @@ -188,6 +225,18 @@ func (m *Cable) validateLabel(formats strfmt.Registry) error { return nil } +func (m *Cable) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *Cable) validateLengthUnit(formats strfmt.Registry) error { if swag.IsZero(m.LengthUnit) { // not required return nil @@ -252,6 +301,25 @@ func (m *Cable) validateTags(formats strfmt.Registry) error { return nil } +func (m *Cable) validateTenant(formats strfmt.Registry) error { + if swag.IsZero(m.Tenant) { // not required + return nil + } + + if m.Tenant != nil { + if err := m.Tenant.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenant") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenant") + } + return err + } + } + + return nil +} + func (m *Cable) validateTerminationaID(formats strfmt.Registry) error { if err := validate.Required("termination_a_id", "body", m.TerminationaID); err != nil { @@ -425,6 +493,10 @@ func (m *Cable) validateURL(formats strfmt.Registry) error { func (m *Cable) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -433,6 +505,10 @@ func (m *Cable) ContextValidate(ctx context.Context, formats strfmt.Registry) er res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateLengthUnit(ctx, formats); err != nil { res = append(res, err) } @@ -445,6 +521,10 @@ func (m *Cable) ContextValidate(ctx context.Context, formats strfmt.Registry) er res = append(res, err) } + if err := m.contextValidateTenant(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTerminationa(ctx, formats); err != nil { res = append(res, err) } @@ -463,6 +543,15 @@ func (m *Cable) ContextValidate(ctx context.Context, formats strfmt.Registry) er return nil } +func (m *Cable) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *Cable) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -481,6 +570,15 @@ func (m *Cable) contextValidateID(ctx context.Context, formats strfmt.Registry) return nil } +func (m *Cable) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *Cable) contextValidateLengthUnit(ctx context.Context, formats strfmt.Registry) error { if m.LengthUnit != nil { @@ -533,6 +631,22 @@ func (m *Cable) contextValidateTags(ctx context.Context, formats strfmt.Registry return nil } +func (m *Cable) contextValidateTenant(ctx context.Context, formats strfmt.Registry) error { + + if m.Tenant != nil { + if err := m.Tenant.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenant") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenant") + } + return err + } + } + + return nil +} + func (m *Cable) contextValidateTerminationa(ctx context.Context, formats strfmt.Registry) error { return nil diff --git a/netbox/models/circuit_termination.go b/netbox/models/circuit_termination.go index 7fea11c8..bd0326d6 100644 --- a/netbox/models/circuit_termination.go +++ b/netbox/models/circuit_termination.go @@ -42,22 +42,15 @@ type CircuitTermination struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // circuit // Required: true Circuit *NestedCircuit `json:"circuit"` + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Description // Max Length: 200 Description string `json:"description,omitempty"` @@ -70,6 +63,23 @@ type CircuitTermination struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -124,10 +134,18 @@ func (m *CircuitTermination) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateDescription(formats); err != nil { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validatePortSpeed(formats); err != nil { res = append(res, err) } @@ -205,6 +223,18 @@ func (m *CircuitTermination) validateCircuit(formats strfmt.Registry) error { return nil } +func (m *CircuitTermination) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *CircuitTermination) validateDescription(formats strfmt.Registry) error { if swag.IsZero(m.Description) { // not required return nil @@ -217,6 +247,18 @@ func (m *CircuitTermination) validateDescription(formats strfmt.Registry) error return nil } +func (m *CircuitTermination) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *CircuitTermination) validatePortSpeed(formats strfmt.Registry) error { if swag.IsZero(m.PortSpeed) { // not required return nil @@ -378,23 +420,31 @@ func (m *CircuitTermination) ContextValidate(ctx context.Context, formats strfmt res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { + if err := m.contextValidateCircuit(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { + if err := m.contextValidateCreated(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCircuit(ctx, formats); err != nil { + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateDisplay(ctx, formats); err != nil { + if err := m.contextValidateID(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateID(ctx, formats); err != nil { + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { res = append(res, err) } @@ -441,20 +491,6 @@ func (m *CircuitTermination) contextValidateCable(ctx context.Context, formats s return nil } -func (m *CircuitTermination) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *CircuitTermination) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *CircuitTermination) contextValidateCircuit(ctx context.Context, formats strfmt.Registry) error { if m.Circuit != nil { @@ -471,6 +507,15 @@ func (m *CircuitTermination) contextValidateCircuit(ctx context.Context, formats return nil } +func (m *CircuitTermination) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *CircuitTermination) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -489,6 +534,29 @@ func (m *CircuitTermination) contextValidateID(ctx context.Context, formats strf return nil } +func (m *CircuitTermination) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *CircuitTermination) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *CircuitTermination) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *CircuitTermination) contextValidateProviderNetwork(ctx context.Context, formats strfmt.Registry) error { if m.ProviderNetwork != nil { diff --git a/netbox/models/circuit_type.go b/netbox/models/circuit_type.go index 0acaaf8c..f1891391 100644 --- a/netbox/models/circuit_type.go +++ b/netbox/models/circuit_type.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -76,6 +77,9 @@ type CircuitType struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -106,6 +110,10 @@ func (m *CircuitType) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -190,6 +198,32 @@ func (m *CircuitType) validateSlug(formats strfmt.Registry) error { return nil } +func (m *CircuitType) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *CircuitType) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -226,6 +260,10 @@ func (m *CircuitType) ContextValidate(ctx context.Context, formats strfmt.Regist res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -281,6 +319,26 @@ func (m *CircuitType) contextValidateLastUpdated(ctx context.Context, formats st return nil } +func (m *CircuitType) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *CircuitType) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/cluster_group.go b/netbox/models/cluster_group.go index afd75ddd..14a749ee 100644 --- a/netbox/models/cluster_group.go +++ b/netbox/models/cluster_group.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -76,6 +77,9 @@ type ClusterGroup struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -106,6 +110,10 @@ func (m *ClusterGroup) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -190,6 +198,32 @@ func (m *ClusterGroup) validateSlug(formats strfmt.Registry) error { return nil } +func (m *ClusterGroup) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *ClusterGroup) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -226,6 +260,10 @@ func (m *ClusterGroup) ContextValidate(ctx context.Context, formats strfmt.Regis res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -281,6 +319,26 @@ func (m *ClusterGroup) contextValidateLastUpdated(ctx context.Context, formats s return nil } +func (m *ClusterGroup) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *ClusterGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/cluster_type.go b/netbox/models/cluster_type.go index 4f2f7104..854d072b 100644 --- a/netbox/models/cluster_type.go +++ b/netbox/models/cluster_type.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -76,6 +77,9 @@ type ClusterType struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -106,6 +110,10 @@ func (m *ClusterType) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -190,6 +198,32 @@ func (m *ClusterType) validateSlug(formats strfmt.Registry) error { return nil } +func (m *ClusterType) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *ClusterType) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -226,6 +260,10 @@ func (m *ClusterType) ContextValidate(ctx context.Context, formats strfmt.Regist res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -281,6 +319,26 @@ func (m *ClusterType) contextValidateLastUpdated(ctx context.Context, formats st return nil } +func (m *ClusterType) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *ClusterType) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/console_port.go b/netbox/models/console_port.go index 21d0a8da..61f7dc8c 100644 --- a/netbox/models/console_port.go +++ b/netbox/models/console_port.go @@ -43,18 +43,6 @@ type ConsolePort struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Connected endpoint // // @@ -106,6 +94,18 @@ type ConsolePort struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -378,14 +378,6 @@ func (m *ConsolePort) ContextValidate(ctx context.Context, formats strfmt.Regist res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { - res = append(res, err) - } - if err := m.contextValidateConnectedEndpoint(ctx, formats); err != nil { res = append(res, err) } @@ -418,6 +410,14 @@ func (m *ConsolePort) ContextValidate(ctx context.Context, formats strfmt.Regist res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateSpeed(ctx, formats); err != nil { res = append(res, err) } @@ -465,20 +465,6 @@ func (m *ConsolePort) contextValidateCable(ctx context.Context, formats strfmt.R return nil } -func (m *ConsolePort) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *ConsolePort) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *ConsolePort) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil @@ -554,6 +540,20 @@ func (m *ConsolePort) contextValidateLastUpdated(ctx context.Context, formats st return nil } +func (m *ConsolePort) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *ConsolePort) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *ConsolePort) contextValidateSpeed(ctx context.Context, formats strfmt.Registry) error { if m.Speed != nil { diff --git a/netbox/models/console_server_port.go b/netbox/models/console_server_port.go index 63b73142..9d1ec016 100644 --- a/netbox/models/console_server_port.go +++ b/netbox/models/console_server_port.go @@ -43,18 +43,6 @@ type ConsoleServerPort struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Connected endpoint // // @@ -106,6 +94,18 @@ type ConsoleServerPort struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -378,14 +378,6 @@ func (m *ConsoleServerPort) ContextValidate(ctx context.Context, formats strfmt. res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { - res = append(res, err) - } - if err := m.contextValidateConnectedEndpoint(ctx, formats); err != nil { res = append(res, err) } @@ -418,6 +410,14 @@ func (m *ConsoleServerPort) ContextValidate(ctx context.Context, formats strfmt. res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateSpeed(ctx, formats); err != nil { res = append(res, err) } @@ -465,20 +465,6 @@ func (m *ConsoleServerPort) contextValidateCable(ctx context.Context, formats st return nil } -func (m *ConsoleServerPort) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *ConsoleServerPort) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *ConsoleServerPort) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil @@ -554,6 +540,20 @@ func (m *ConsoleServerPort) contextValidateLastUpdated(ctx context.Context, form return nil } +func (m *ConsoleServerPort) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *ConsoleServerPort) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *ConsoleServerPort) contextValidateSpeed(ctx context.Context, formats strfmt.Registry) error { if m.Speed != nil { diff --git a/netbox/models/contact.go b/netbox/models/contact.go new file mode 100644 index 00000000..1bea8a52 --- /dev/null +++ b/netbox/models/contact.go @@ -0,0 +1,432 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// Contact contact +// +// swagger:model Contact +type Contact struct { + + // Address + // Max Length: 200 + Address string `json:"address,omitempty"` + + // Comments + Comments string `json:"comments,omitempty"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Email + // Max Length: 254 + // Format: email + Email strfmt.Email `json:"email,omitempty"` + + // group + Group *NestedContactGroup `json:"group,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Name + // Required: true + // Max Length: 100 + // Min Length: 1 + Name *string `json:"name"` + + // Phone + // Max Length: 50 + Phone string `json:"phone,omitempty"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Title + // Max Length: 100 + Title string `json:"title,omitempty"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this contact +func (m *Contact) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAddress(formats); err != nil { + res = append(res, err) + } + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateEmail(formats); err != nil { + res = append(res, err) + } + + if err := m.validateGroup(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateName(formats); err != nil { + res = append(res, err) + } + + if err := m.validatePhone(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTitle(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Contact) validateAddress(formats strfmt.Registry) error { + if swag.IsZero(m.Address) { // not required + return nil + } + + if err := validate.MaxLength("address", "body", m.Address, 200); err != nil { + return err + } + + return nil +} + +func (m *Contact) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *Contact) validateEmail(formats strfmt.Registry) error { + if swag.IsZero(m.Email) { // not required + return nil + } + + if err := validate.MaxLength("email", "body", m.Email.String(), 254); err != nil { + return err + } + + if err := validate.FormatOf("email", "body", "email", m.Email.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *Contact) validateGroup(formats strfmt.Registry) error { + if swag.IsZero(m.Group) { // not required + return nil + } + + if m.Group != nil { + if err := m.Group.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("group") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("group") + } + return err + } + } + + return nil +} + +func (m *Contact) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *Contact) validateName(formats strfmt.Registry) error { + + if err := validate.Required("name", "body", m.Name); err != nil { + return err + } + + if err := validate.MinLength("name", "body", *m.Name, 1); err != nil { + return err + } + + if err := validate.MaxLength("name", "body", *m.Name, 100); err != nil { + return err + } + + return nil +} + +func (m *Contact) validatePhone(formats strfmt.Registry) error { + if swag.IsZero(m.Phone) { // not required + return nil + } + + if err := validate.MaxLength("phone", "body", m.Phone, 50); err != nil { + return err + } + + return nil +} + +func (m *Contact) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *Contact) validateTitle(formats strfmt.Registry) error { + if swag.IsZero(m.Title) { // not required + return nil + } + + if err := validate.MaxLength("title", "body", m.Title, 100); err != nil { + return err + } + + return nil +} + +func (m *Contact) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this contact based on the context it is used +func (m *Contact) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateGroup(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *Contact) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *Contact) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *Contact) contextValidateGroup(ctx context.Context, formats strfmt.Registry) error { + + if m.Group != nil { + if err := m.Group.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("group") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("group") + } + return err + } + } + + return nil +} + +func (m *Contact) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *Contact) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *Contact) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *Contact) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *Contact) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *Contact) UnmarshalBinary(b []byte) error { + var res Contact + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/contact_assignment.go b/netbox/models/contact_assignment.go new file mode 100644 index 00000000..e44ed542 --- /dev/null +++ b/netbox/models/contact_assignment.go @@ -0,0 +1,563 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "encoding/json" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// ContactAssignment contact assignment +// +// swagger:model ContactAssignment +type ContactAssignment struct { + + // contact + // Required: true + Contact *NestedContact `json:"contact"` + + // Content type + // Required: true + ContentType *string `json:"content_type"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Object + // Read Only: true + Object map[string]*string `json:"object,omitempty"` + + // Object id + // Required: true + // Maximum: 2.147483647e+09 + // Minimum: 0 + ObjectID *int64 `json:"object_id"` + + // priority + Priority *ContactAssignmentPriority `json:"priority,omitempty"` + + // role + Role *NestedContactRole `json:"role,omitempty"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this contact assignment +func (m *ContactAssignment) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateContact(formats); err != nil { + res = append(res, err) + } + + if err := m.validateContentType(formats); err != nil { + res = append(res, err) + } + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateObjectID(formats); err != nil { + res = append(res, err) + } + + if err := m.validatePriority(formats); err != nil { + res = append(res, err) + } + + if err := m.validateRole(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ContactAssignment) validateContact(formats strfmt.Registry) error { + + if err := validate.Required("contact", "body", m.Contact); err != nil { + return err + } + + if m.Contact != nil { + if err := m.Contact.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("contact") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("contact") + } + return err + } + } + + return nil +} + +func (m *ContactAssignment) validateContentType(formats strfmt.Registry) error { + + if err := validate.Required("content_type", "body", m.ContentType); err != nil { + return err + } + + return nil +} + +func (m *ContactAssignment) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *ContactAssignment) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *ContactAssignment) validateObjectID(formats strfmt.Registry) error { + + if err := validate.Required("object_id", "body", m.ObjectID); err != nil { + return err + } + + if err := validate.MinimumInt("object_id", "body", *m.ObjectID, 0, false); err != nil { + return err + } + + if err := validate.MaximumInt("object_id", "body", *m.ObjectID, 2.147483647e+09, false); err != nil { + return err + } + + return nil +} + +func (m *ContactAssignment) validatePriority(formats strfmt.Registry) error { + if swag.IsZero(m.Priority) { // not required + return nil + } + + if m.Priority != nil { + if err := m.Priority.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("priority") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("priority") + } + return err + } + } + + return nil +} + +func (m *ContactAssignment) validateRole(formats strfmt.Registry) error { + if swag.IsZero(m.Role) { // not required + return nil + } + + if m.Role != nil { + if err := m.Role.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("role") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("role") + } + return err + } + } + + return nil +} + +func (m *ContactAssignment) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this contact assignment based on the context it is used +func (m *ContactAssignment) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateContact(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateObject(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidatePriority(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateRole(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ContactAssignment) contextValidateContact(ctx context.Context, formats strfmt.Registry) error { + + if m.Contact != nil { + if err := m.Contact.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("contact") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("contact") + } + return err + } + } + + return nil +} + +func (m *ContactAssignment) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *ContactAssignment) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *ContactAssignment) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *ContactAssignment) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *ContactAssignment) contextValidateObject(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *ContactAssignment) contextValidatePriority(ctx context.Context, formats strfmt.Registry) error { + + if m.Priority != nil { + if err := m.Priority.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("priority") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("priority") + } + return err + } + } + + return nil +} + +func (m *ContactAssignment) contextValidateRole(ctx context.Context, formats strfmt.Registry) error { + + if m.Role != nil { + if err := m.Role.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("role") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("role") + } + return err + } + } + + return nil +} + +func (m *ContactAssignment) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *ContactAssignment) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *ContactAssignment) UnmarshalBinary(b []byte) error { + var res ContactAssignment + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + +// ContactAssignmentPriority Priority +// +// swagger:model ContactAssignmentPriority +type ContactAssignmentPriority struct { + + // label + // Required: true + // Enum: [Primary Secondary Tertiary Inactive] + Label *string `json:"label"` + + // value + // Required: true + // Enum: [primary secondary tertiary inactive] + Value *string `json:"value"` +} + +// Validate validates this contact assignment priority +func (m *ContactAssignmentPriority) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateLabel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateValue(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var contactAssignmentPriorityTypeLabelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["Primary","Secondary","Tertiary","Inactive"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + contactAssignmentPriorityTypeLabelPropEnum = append(contactAssignmentPriorityTypeLabelPropEnum, v) + } +} + +const ( + + // ContactAssignmentPriorityLabelPrimary captures enum value "Primary" + ContactAssignmentPriorityLabelPrimary string = "Primary" + + // ContactAssignmentPriorityLabelSecondary captures enum value "Secondary" + ContactAssignmentPriorityLabelSecondary string = "Secondary" + + // ContactAssignmentPriorityLabelTertiary captures enum value "Tertiary" + ContactAssignmentPriorityLabelTertiary string = "Tertiary" + + // ContactAssignmentPriorityLabelInactive captures enum value "Inactive" + ContactAssignmentPriorityLabelInactive string = "Inactive" +) + +// prop value enum +func (m *ContactAssignmentPriority) validateLabelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, contactAssignmentPriorityTypeLabelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *ContactAssignmentPriority) validateLabel(formats strfmt.Registry) error { + + if err := validate.Required("priority"+"."+"label", "body", m.Label); err != nil { + return err + } + + // value enum + if err := m.validateLabelEnum("priority"+"."+"label", "body", *m.Label); err != nil { + return err + } + + return nil +} + +var contactAssignmentPriorityTypeValuePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["primary","secondary","tertiary","inactive"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + contactAssignmentPriorityTypeValuePropEnum = append(contactAssignmentPriorityTypeValuePropEnum, v) + } +} + +const ( + + // ContactAssignmentPriorityValuePrimary captures enum value "primary" + ContactAssignmentPriorityValuePrimary string = "primary" + + // ContactAssignmentPriorityValueSecondary captures enum value "secondary" + ContactAssignmentPriorityValueSecondary string = "secondary" + + // ContactAssignmentPriorityValueTertiary captures enum value "tertiary" + ContactAssignmentPriorityValueTertiary string = "tertiary" + + // ContactAssignmentPriorityValueInactive captures enum value "inactive" + ContactAssignmentPriorityValueInactive string = "inactive" +) + +// prop value enum +func (m *ContactAssignmentPriority) validateValueEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, contactAssignmentPriorityTypeValuePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *ContactAssignmentPriority) validateValue(formats strfmt.Registry) error { + + if err := validate.Required("priority"+"."+"value", "body", m.Value); err != nil { + return err + } + + // value enum + if err := m.validateValueEnum("priority"+"."+"value", "body", *m.Value); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this contact assignment priority based on context it is used +func (m *ContactAssignmentPriority) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *ContactAssignmentPriority) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *ContactAssignmentPriority) UnmarshalBinary(b []byte) error { + var res ContactAssignmentPriority + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/contact_group.go b/netbox/models/contact_group.go new file mode 100644 index 00000000..fe17cc5a --- /dev/null +++ b/netbox/models/contact_group.go @@ -0,0 +1,430 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// ContactGroup contact group +// +// swagger:model ContactGroup +type ContactGroup struct { + + // depth + // Read Only: true + Depth int64 `json:"_depth,omitempty"` + + // Contact count + // Read Only: true + ContactCount int64 `json:"contact_count,omitempty"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Name + // Required: true + // Max Length: 100 + // Min Length: 1 + Name *string `json:"name"` + + // parent + Parent *NestedContactGroup `json:"parent,omitempty"` + + // Slug + // Required: true + // Max Length: 100 + // Min Length: 1 + // Pattern: ^[-a-zA-Z0-9_]+$ + Slug *string `json:"slug"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this contact group +func (m *ContactGroup) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateName(formats); err != nil { + res = append(res, err) + } + + if err := m.validateParent(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSlug(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ContactGroup) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *ContactGroup) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *ContactGroup) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *ContactGroup) validateName(formats strfmt.Registry) error { + + if err := validate.Required("name", "body", m.Name); err != nil { + return err + } + + if err := validate.MinLength("name", "body", *m.Name, 1); err != nil { + return err + } + + if err := validate.MaxLength("name", "body", *m.Name, 100); err != nil { + return err + } + + return nil +} + +func (m *ContactGroup) validateParent(formats strfmt.Registry) error { + if swag.IsZero(m.Parent) { // not required + return nil + } + + if m.Parent != nil { + if err := m.Parent.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("parent") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("parent") + } + return err + } + } + + return nil +} + +func (m *ContactGroup) validateSlug(formats strfmt.Registry) error { + + if err := validate.Required("slug", "body", m.Slug); err != nil { + return err + } + + if err := validate.MinLength("slug", "body", *m.Slug, 1); err != nil { + return err + } + + if err := validate.MaxLength("slug", "body", *m.Slug, 100); err != nil { + return err + } + + if err := validate.Pattern("slug", "body", *m.Slug, `^[-a-zA-Z0-9_]+$`); err != nil { + return err + } + + return nil +} + +func (m *ContactGroup) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *ContactGroup) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this contact group based on the context it is used +func (m *ContactGroup) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDepth(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateContactCount(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateParent(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ContactGroup) contextValidateDepth(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "_depth", "body", int64(m.Depth)); err != nil { + return err + } + + return nil +} + +func (m *ContactGroup) contextValidateContactCount(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "contact_count", "body", int64(m.ContactCount)); err != nil { + return err + } + + return nil +} + +func (m *ContactGroup) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *ContactGroup) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *ContactGroup) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *ContactGroup) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *ContactGroup) contextValidateParent(ctx context.Context, formats strfmt.Registry) error { + + if m.Parent != nil { + if err := m.Parent.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("parent") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("parent") + } + return err + } + } + + return nil +} + +func (m *ContactGroup) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *ContactGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *ContactGroup) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *ContactGroup) UnmarshalBinary(b []byte) error { + var res ContactGroup + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/contact_role.go b/netbox/models/contact_role.go new file mode 100644 index 00000000..ee940df7 --- /dev/null +++ b/netbox/models/contact_role.go @@ -0,0 +1,350 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// ContactRole contact role +// +// swagger:model ContactRole +type ContactRole struct { + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Name + // Required: true + // Max Length: 100 + // Min Length: 1 + Name *string `json:"name"` + + // Slug + // Required: true + // Max Length: 100 + // Min Length: 1 + // Pattern: ^[-a-zA-Z0-9_]+$ + Slug *string `json:"slug"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this contact role +func (m *ContactRole) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateName(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSlug(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ContactRole) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *ContactRole) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *ContactRole) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *ContactRole) validateName(formats strfmt.Registry) error { + + if err := validate.Required("name", "body", m.Name); err != nil { + return err + } + + if err := validate.MinLength("name", "body", *m.Name, 1); err != nil { + return err + } + + if err := validate.MaxLength("name", "body", *m.Name, 100); err != nil { + return err + } + + return nil +} + +func (m *ContactRole) validateSlug(formats strfmt.Registry) error { + + if err := validate.Required("slug", "body", m.Slug); err != nil { + return err + } + + if err := validate.MinLength("slug", "body", *m.Slug, 1); err != nil { + return err + } + + if err := validate.MaxLength("slug", "body", *m.Slug, 100); err != nil { + return err + } + + if err := validate.Pattern("slug", "body", *m.Slug, `^[-a-zA-Z0-9_]+$`); err != nil { + return err + } + + return nil +} + +func (m *ContactRole) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *ContactRole) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this contact role based on the context it is used +func (m *ContactRole) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *ContactRole) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *ContactRole) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *ContactRole) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *ContactRole) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *ContactRole) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *ContactRole) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *ContactRole) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *ContactRole) UnmarshalBinary(b []byte) error { + var res ContactRole + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/custom_field.go b/netbox/models/custom_field.go index 2a5fbc47..729c3cbd 100644 --- a/netbox/models/custom_field.go +++ b/netbox/models/custom_field.go @@ -44,6 +44,11 @@ type CustomField struct { // Unique: true ContentTypes []string `json:"content_types"` + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Default // // Default value for the field (must be a JSON value). Encapsulate strings with double quotes (e.g. "Foo"). @@ -70,12 +75,18 @@ type CustomField struct { // Max Length: 50 Label string `json:"label,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Name // // Internal field name // Required: true // Max Length: 50 // Min Length: 1 + // Pattern: ^[a-z0-9_]+$ Name *string `json:"name"` // Required @@ -96,14 +107,14 @@ type CustomField struct { // // Maximum allowed value (for numeric fields) // Maximum: 2.147483647e+09 - // Minimum: 0 + // Minimum: -2.147483648e+09 ValidationMaximum *int64 `json:"validation_maximum,omitempty"` // Minimum value // // Minimum allowed value (for numeric fields) // Maximum: 2.147483647e+09 - // Minimum: 0 + // Minimum: -2.147483648e+09 ValidationMinimum *int64 `json:"validation_minimum,omitempty"` // Validation regex @@ -132,6 +143,10 @@ func (m *CustomField) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateDescription(formats); err != nil { res = append(res, err) } @@ -144,6 +159,10 @@ func (m *CustomField) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateName(formats); err != nil { res = append(res, err) } @@ -211,6 +230,18 @@ func (m *CustomField) validateContentTypes(formats strfmt.Registry) error { return nil } +func (m *CustomField) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *CustomField) validateDescription(formats strfmt.Registry) error { if swag.IsZero(m.Description) { // not required return nil @@ -254,6 +285,18 @@ func (m *CustomField) validateLabel(formats strfmt.Registry) error { return nil } +func (m *CustomField) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *CustomField) validateName(formats strfmt.Registry) error { if err := validate.Required("name", "body", m.Name); err != nil { @@ -268,6 +311,10 @@ func (m *CustomField) validateName(formats strfmt.Registry) error { return err } + if err := validate.Pattern("name", "body", *m.Name, `^[a-z0-9_]+$`); err != nil { + return err + } + return nil } @@ -308,7 +355,7 @@ func (m *CustomField) validateValidationMaximum(formats strfmt.Registry) error { return nil } - if err := validate.MinimumInt("validation_maximum", "body", *m.ValidationMaximum, 0, false); err != nil { + if err := validate.MinimumInt("validation_maximum", "body", *m.ValidationMaximum, -2.147483648e+09, false); err != nil { return err } @@ -324,7 +371,7 @@ func (m *CustomField) validateValidationMinimum(formats strfmt.Registry) error { return nil } - if err := validate.MinimumInt("validation_minimum", "body", *m.ValidationMinimum, 0, false); err != nil { + if err := validate.MinimumInt("validation_minimum", "body", *m.ValidationMinimum, -2.147483648e+09, false); err != nil { return err } @@ -367,6 +414,10 @@ func (m *CustomField) validateWeight(formats strfmt.Registry) error { func (m *CustomField) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -379,6 +430,10 @@ func (m *CustomField) ContextValidate(ctx context.Context, formats strfmt.Regist res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateType(ctx, formats); err != nil { res = append(res, err) } @@ -393,6 +448,15 @@ func (m *CustomField) ContextValidate(ctx context.Context, formats strfmt.Regist return nil } +func (m *CustomField) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *CustomField) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -427,6 +491,15 @@ func (m *CustomField) contextValidateID(ctx context.Context, formats strfmt.Regi return nil } +func (m *CustomField) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *CustomField) contextValidateType(ctx context.Context, formats strfmt.Registry) error { if m.Type != nil { @@ -626,12 +699,12 @@ type CustomFieldType struct { // label // Required: true - // Enum: [Text Integer Boolean (true/false) Date URL Selection Multiple selection] + // Enum: [Text Text (long) Integer Boolean (true/false) Date URL JSON Selection Multiple selection] Label *string `json:"label"` // value // Required: true - // Enum: [text integer boolean date url select multiselect] + // Enum: [text longtext integer boolean date url json select multiselect] Value *string `json:"value"` } @@ -657,7 +730,7 @@ var customFieldTypeTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["Text","Integer","Boolean (true/false)","Date","URL","Selection","Multiple selection"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["Text","Text (long)","Integer","Boolean (true/false)","Date","URL","JSON","Selection","Multiple selection"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -670,6 +743,9 @@ const ( // CustomFieldTypeLabelText captures enum value "Text" CustomFieldTypeLabelText string = "Text" + // CustomFieldTypeLabelTextLong captures enum value "Text (long)" + CustomFieldTypeLabelTextLong string = "Text (long)" + // CustomFieldTypeLabelInteger captures enum value "Integer" CustomFieldTypeLabelInteger string = "Integer" @@ -682,6 +758,9 @@ const ( // CustomFieldTypeLabelURL captures enum value "URL" CustomFieldTypeLabelURL string = "URL" + // CustomFieldTypeLabelJSON captures enum value "JSON" + CustomFieldTypeLabelJSON string = "JSON" + // CustomFieldTypeLabelSelection captures enum value "Selection" CustomFieldTypeLabelSelection string = "Selection" @@ -715,7 +794,7 @@ var customFieldTypeTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["text","integer","boolean","date","url","select","multiselect"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["text","longtext","integer","boolean","date","url","json","select","multiselect"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -728,6 +807,9 @@ const ( // CustomFieldTypeValueText captures enum value "text" CustomFieldTypeValueText string = "text" + // CustomFieldTypeValueLongtext captures enum value "longtext" + CustomFieldTypeValueLongtext string = "longtext" + // CustomFieldTypeValueInteger captures enum value "integer" CustomFieldTypeValueInteger string = "integer" @@ -740,6 +822,9 @@ const ( // CustomFieldTypeValueURL captures enum value "url" CustomFieldTypeValueURL string = "url" + // CustomFieldTypeValueJSON captures enum value "json" + CustomFieldTypeValueJSON string = "json" + // CustomFieldTypeValueSelect captures enum value "select" CustomFieldTypeValueSelect string = "select" diff --git a/netbox/models/custom_link.go b/netbox/models/custom_link.go index 39a223a6..90718de5 100644 --- a/netbox/models/custom_link.go +++ b/netbox/models/custom_link.go @@ -45,6 +45,11 @@ type CustomLink struct { // Required: true ContentType *string `json:"content_type"` + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Display // Read Only: true Display string `json:"display,omitempty"` @@ -59,6 +64,11 @@ type CustomLink struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link text // // Jinja2 template code for link text @@ -109,10 +119,18 @@ func (m *CustomLink) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateGroupName(formats); err != nil { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateLinkText(formats); err != nil { res = append(res, err) } @@ -223,6 +241,18 @@ func (m *CustomLink) validateContentType(formats strfmt.Registry) error { return nil } +func (m *CustomLink) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *CustomLink) validateGroupName(formats strfmt.Registry) error { if swag.IsZero(m.GroupName) { // not required return nil @@ -235,6 +265,18 @@ func (m *CustomLink) validateGroupName(formats strfmt.Registry) error { return nil } +func (m *CustomLink) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *CustomLink) validateLinkText(formats strfmt.Registry) error { if err := validate.Required("link_text", "body", m.LinkText); err != nil { @@ -318,6 +360,10 @@ func (m *CustomLink) validateWeight(formats strfmt.Registry) error { func (m *CustomLink) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -326,6 +372,10 @@ func (m *CustomLink) ContextValidate(ctx context.Context, formats strfmt.Registr res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -336,6 +386,15 @@ func (m *CustomLink) ContextValidate(ctx context.Context, formats strfmt.Registr return nil } +func (m *CustomLink) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *CustomLink) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -354,6 +413,15 @@ func (m *CustomLink) contextValidateID(ctx context.Context, formats strfmt.Regis return nil } +func (m *CustomLink) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *CustomLink) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/device.go b/netbox/models/device.go index 4219506a..5a957d0f 100644 --- a/netbox/models/device.go +++ b/netbox/models/device.go @@ -36,6 +36,9 @@ import ( // swagger:model Device type Device struct { + // airflow + Airflow *DeviceAirflow `json:"airflow,omitempty"` + // Asset tag // // A unique tag used to identify this device @@ -87,8 +90,9 @@ type Device struct { Location *NestedLocation `json:"location,omitempty"` // Name + // Required: true // Max Length: 64 - Name *string `json:"name,omitempty"` + Name *string `json:"name"` // parent device ParentDevice *NestedDevice `json:"parent_device,omitempty"` @@ -97,9 +101,6 @@ type Device struct { Platform *NestedPlatform `json:"platform,omitempty"` // Position (U) - // - // The lowest-numbered unit occupied by the device - // Maximum: 32767 // Minimum: 1 Position *int64 `json:"position,omitempty"` @@ -155,6 +156,10 @@ type Device struct { func (m *Device) Validate(formats strfmt.Registry) error { var res []error + if err := m.validateAirflow(formats); err != nil { + res = append(res, err) + } + if err := m.validateAssetTag(formats); err != nil { res = append(res, err) } @@ -261,6 +266,25 @@ func (m *Device) Validate(formats strfmt.Registry) error { return nil } +func (m *Device) validateAirflow(formats strfmt.Registry) error { + if swag.IsZero(m.Airflow) { // not required + return nil + } + + if m.Airflow != nil { + if err := m.Airflow.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("airflow") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("airflow") + } + return err + } + } + + return nil +} + func (m *Device) validateAssetTag(formats strfmt.Registry) error { if swag.IsZero(m.AssetTag) { // not required return nil @@ -395,8 +419,9 @@ func (m *Device) validateLocation(formats strfmt.Registry) error { } func (m *Device) validateName(formats strfmt.Registry) error { - if swag.IsZero(m.Name) { // not required - return nil + + if err := validate.Required("name", "body", m.Name); err != nil { + return err } if err := validate.MaxLength("name", "body", *m.Name, 64); err != nil { @@ -453,10 +478,6 @@ func (m *Device) validatePosition(formats strfmt.Registry) error { return err } - if err := validate.MaximumInt("position", "body", *m.Position, 32767, false); err != nil { - return err - } - return nil } @@ -699,6 +720,10 @@ func (m *Device) validateVirtualChassis(formats strfmt.Registry) error { func (m *Device) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateAirflow(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateCluster(ctx, formats); err != nil { res = append(res, err) } @@ -789,6 +814,22 @@ func (m *Device) ContextValidate(ctx context.Context, formats strfmt.Registry) e return nil } +func (m *Device) contextValidateAirflow(ctx context.Context, formats strfmt.Registry) error { + + if m.Airflow != nil { + if err := m.Airflow.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("airflow") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("airflow") + } + return err + } + } + + return nil +} + func (m *Device) contextValidateCluster(ctx context.Context, formats strfmt.Registry) error { if m.Cluster != nil { @@ -1112,6 +1153,173 @@ func (m *Device) UnmarshalBinary(b []byte) error { return nil } +// DeviceAirflow Airflow +// +// swagger:model DeviceAirflow +type DeviceAirflow struct { + + // label + // Required: true + // Enum: [Front to rear Rear to front Left to right Right to left Side to rear Passive] + Label *string `json:"label"` + + // value + // Required: true + // Enum: [front-to-rear rear-to-front left-to-right right-to-left side-to-rear passive] + Value *string `json:"value"` +} + +// Validate validates this device airflow +func (m *DeviceAirflow) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateLabel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateValue(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var deviceAirflowTypeLabelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["Front to rear","Rear to front","Left to right","Right to left","Side to rear","Passive"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + deviceAirflowTypeLabelPropEnum = append(deviceAirflowTypeLabelPropEnum, v) + } +} + +const ( + + // DeviceAirflowLabelFrontToRear captures enum value "Front to rear" + DeviceAirflowLabelFrontToRear string = "Front to rear" + + // DeviceAirflowLabelRearToFront captures enum value "Rear to front" + DeviceAirflowLabelRearToFront string = "Rear to front" + + // DeviceAirflowLabelLeftToRight captures enum value "Left to right" + DeviceAirflowLabelLeftToRight string = "Left to right" + + // DeviceAirflowLabelRightToLeft captures enum value "Right to left" + DeviceAirflowLabelRightToLeft string = "Right to left" + + // DeviceAirflowLabelSideToRear captures enum value "Side to rear" + DeviceAirflowLabelSideToRear string = "Side to rear" + + // DeviceAirflowLabelPassive captures enum value "Passive" + DeviceAirflowLabelPassive string = "Passive" +) + +// prop value enum +func (m *DeviceAirflow) validateLabelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, deviceAirflowTypeLabelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *DeviceAirflow) validateLabel(formats strfmt.Registry) error { + + if err := validate.Required("airflow"+"."+"label", "body", m.Label); err != nil { + return err + } + + // value enum + if err := m.validateLabelEnum("airflow"+"."+"label", "body", *m.Label); err != nil { + return err + } + + return nil +} + +var deviceAirflowTypeValuePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["front-to-rear","rear-to-front","left-to-right","right-to-left","side-to-rear","passive"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + deviceAirflowTypeValuePropEnum = append(deviceAirflowTypeValuePropEnum, v) + } +} + +const ( + + // DeviceAirflowValueFrontDashToDashRear captures enum value "front-to-rear" + DeviceAirflowValueFrontDashToDashRear string = "front-to-rear" + + // DeviceAirflowValueRearDashToDashFront captures enum value "rear-to-front" + DeviceAirflowValueRearDashToDashFront string = "rear-to-front" + + // DeviceAirflowValueLeftDashToDashRight captures enum value "left-to-right" + DeviceAirflowValueLeftDashToDashRight string = "left-to-right" + + // DeviceAirflowValueRightDashToDashLeft captures enum value "right-to-left" + DeviceAirflowValueRightDashToDashLeft string = "right-to-left" + + // DeviceAirflowValueSideDashToDashRear captures enum value "side-to-rear" + DeviceAirflowValueSideDashToDashRear string = "side-to-rear" + + // DeviceAirflowValuePassive captures enum value "passive" + DeviceAirflowValuePassive string = "passive" +) + +// prop value enum +func (m *DeviceAirflow) validateValueEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, deviceAirflowTypeValuePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *DeviceAirflow) validateValue(formats strfmt.Registry) error { + + if err := validate.Required("airflow"+"."+"value", "body", m.Value); err != nil { + return err + } + + // value enum + if err := m.validateValueEnum("airflow"+"."+"value", "body", *m.Value); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this device airflow based on context it is used +func (m *DeviceAirflow) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *DeviceAirflow) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *DeviceAirflow) UnmarshalBinary(b []byte) error { + var res DeviceAirflow + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + // DeviceFace Face // // swagger:model DeviceFace diff --git a/netbox/models/device_role.go b/netbox/models/device_role.go index 28df7232..2376b9ee 100644 --- a/netbox/models/device_role.go +++ b/netbox/models/device_role.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -82,6 +83,9 @@ type DeviceRole struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -125,6 +129,10 @@ func (m *DeviceRole) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -229,6 +237,32 @@ func (m *DeviceRole) validateSlug(formats strfmt.Registry) error { return nil } +func (m *DeviceRole) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *DeviceRole) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -265,6 +299,10 @@ func (m *DeviceRole) ContextValidate(ctx context.Context, formats strfmt.Registr res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -324,6 +362,26 @@ func (m *DeviceRole) contextValidateLastUpdated(ctx context.Context, formats str return nil } +func (m *DeviceRole) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *DeviceRole) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/device_type.go b/netbox/models/device_type.go index 7df52e9d..3fdf27d9 100644 --- a/netbox/models/device_type.go +++ b/netbox/models/device_type.go @@ -36,6 +36,9 @@ import ( // swagger:model DeviceType type DeviceType struct { + // airflow + Airflow *DeviceTypeAirflow `json:"airflow,omitempty"` + // Comments Comments string `json:"comments,omitempty"` @@ -123,6 +126,10 @@ type DeviceType struct { func (m *DeviceType) Validate(formats strfmt.Registry) error { var res []error + if err := m.validateAirflow(formats); err != nil { + res = append(res, err) + } + if err := m.validateCreated(formats); err != nil { res = append(res, err) } @@ -177,6 +184,25 @@ func (m *DeviceType) Validate(formats strfmt.Registry) error { return nil } +func (m *DeviceType) validateAirflow(formats strfmt.Registry) error { + if swag.IsZero(m.Airflow) { // not required + return nil + } + + if m.Airflow != nil { + if err := m.Airflow.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("airflow") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("airflow") + } + return err + } + } + + return nil +} + func (m *DeviceType) validateCreated(formats strfmt.Registry) error { if swag.IsZero(m.Created) { // not required return nil @@ -372,6 +398,10 @@ func (m *DeviceType) validateURL(formats strfmt.Registry) error { func (m *DeviceType) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateAirflow(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateCreated(ctx, formats); err != nil { res = append(res, err) } @@ -422,6 +452,22 @@ func (m *DeviceType) ContextValidate(ctx context.Context, formats strfmt.Registr return nil } +func (m *DeviceType) contextValidateAirflow(ctx context.Context, formats strfmt.Registry) error { + + if m.Airflow != nil { + if err := m.Airflow.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("airflow") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("airflow") + } + return err + } + } + + return nil +} + func (m *DeviceType) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { @@ -564,6 +610,173 @@ func (m *DeviceType) UnmarshalBinary(b []byte) error { return nil } +// DeviceTypeAirflow Airflow +// +// swagger:model DeviceTypeAirflow +type DeviceTypeAirflow struct { + + // label + // Required: true + // Enum: [Front to rear Rear to front Left to right Right to left Side to rear Passive] + Label *string `json:"label"` + + // value + // Required: true + // Enum: [front-to-rear rear-to-front left-to-right right-to-left side-to-rear passive] + Value *string `json:"value"` +} + +// Validate validates this device type airflow +func (m *DeviceTypeAirflow) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateLabel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateValue(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var deviceTypeAirflowTypeLabelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["Front to rear","Rear to front","Left to right","Right to left","Side to rear","Passive"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + deviceTypeAirflowTypeLabelPropEnum = append(deviceTypeAirflowTypeLabelPropEnum, v) + } +} + +const ( + + // DeviceTypeAirflowLabelFrontToRear captures enum value "Front to rear" + DeviceTypeAirflowLabelFrontToRear string = "Front to rear" + + // DeviceTypeAirflowLabelRearToFront captures enum value "Rear to front" + DeviceTypeAirflowLabelRearToFront string = "Rear to front" + + // DeviceTypeAirflowLabelLeftToRight captures enum value "Left to right" + DeviceTypeAirflowLabelLeftToRight string = "Left to right" + + // DeviceTypeAirflowLabelRightToLeft captures enum value "Right to left" + DeviceTypeAirflowLabelRightToLeft string = "Right to left" + + // DeviceTypeAirflowLabelSideToRear captures enum value "Side to rear" + DeviceTypeAirflowLabelSideToRear string = "Side to rear" + + // DeviceTypeAirflowLabelPassive captures enum value "Passive" + DeviceTypeAirflowLabelPassive string = "Passive" +) + +// prop value enum +func (m *DeviceTypeAirflow) validateLabelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, deviceTypeAirflowTypeLabelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *DeviceTypeAirflow) validateLabel(formats strfmt.Registry) error { + + if err := validate.Required("airflow"+"."+"label", "body", m.Label); err != nil { + return err + } + + // value enum + if err := m.validateLabelEnum("airflow"+"."+"label", "body", *m.Label); err != nil { + return err + } + + return nil +} + +var deviceTypeAirflowTypeValuePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["front-to-rear","rear-to-front","left-to-right","right-to-left","side-to-rear","passive"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + deviceTypeAirflowTypeValuePropEnum = append(deviceTypeAirflowTypeValuePropEnum, v) + } +} + +const ( + + // DeviceTypeAirflowValueFrontDashToDashRear captures enum value "front-to-rear" + DeviceTypeAirflowValueFrontDashToDashRear string = "front-to-rear" + + // DeviceTypeAirflowValueRearDashToDashFront captures enum value "rear-to-front" + DeviceTypeAirflowValueRearDashToDashFront string = "rear-to-front" + + // DeviceTypeAirflowValueLeftDashToDashRight captures enum value "left-to-right" + DeviceTypeAirflowValueLeftDashToDashRight string = "left-to-right" + + // DeviceTypeAirflowValueRightDashToDashLeft captures enum value "right-to-left" + DeviceTypeAirflowValueRightDashToDashLeft string = "right-to-left" + + // DeviceTypeAirflowValueSideDashToDashRear captures enum value "side-to-rear" + DeviceTypeAirflowValueSideDashToDashRear string = "side-to-rear" + + // DeviceTypeAirflowValuePassive captures enum value "passive" + DeviceTypeAirflowValuePassive string = "passive" +) + +// prop value enum +func (m *DeviceTypeAirflow) validateValueEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, deviceTypeAirflowTypeValuePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *DeviceTypeAirflow) validateValue(formats strfmt.Registry) error { + + if err := validate.Required("airflow"+"."+"value", "body", m.Value); err != nil { + return err + } + + // value enum + if err := m.validateValueEnum("airflow"+"."+"value", "body", *m.Value); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this device type airflow based on context it is used +func (m *DeviceTypeAirflow) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *DeviceTypeAirflow) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *DeviceTypeAirflow) UnmarshalBinary(b []byte) error { + var res DeviceTypeAirflow + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + // DeviceTypeSubdeviceRole Subdevice role // // swagger:model DeviceTypeSubdeviceRole diff --git a/netbox/models/device_with_config_context.go b/netbox/models/device_with_config_context.go index 4016f59e..ff3984fe 100644 --- a/netbox/models/device_with_config_context.go +++ b/netbox/models/device_with_config_context.go @@ -36,6 +36,9 @@ import ( // swagger:model DeviceWithConfigContext type DeviceWithConfigContext struct { + // airflow + Airflow *DeviceWithConfigContextAirflow `json:"airflow,omitempty"` + // Asset tag // // A unique tag used to identify this device @@ -91,8 +94,9 @@ type DeviceWithConfigContext struct { Location *NestedLocation `json:"location,omitempty"` // Name + // Required: true // Max Length: 64 - Name *string `json:"name,omitempty"` + Name *string `json:"name"` // parent device ParentDevice *NestedDevice `json:"parent_device,omitempty"` @@ -101,9 +105,6 @@ type DeviceWithConfigContext struct { Platform *NestedPlatform `json:"platform,omitempty"` // Position (U) - // - // The lowest-numbered unit occupied by the device - // Maximum: 32767 // Minimum: 1 Position *int64 `json:"position,omitempty"` @@ -159,6 +160,10 @@ type DeviceWithConfigContext struct { func (m *DeviceWithConfigContext) Validate(formats strfmt.Registry) error { var res []error + if err := m.validateAirflow(formats); err != nil { + res = append(res, err) + } + if err := m.validateAssetTag(formats); err != nil { res = append(res, err) } @@ -265,6 +270,25 @@ func (m *DeviceWithConfigContext) Validate(formats strfmt.Registry) error { return nil } +func (m *DeviceWithConfigContext) validateAirflow(formats strfmt.Registry) error { + if swag.IsZero(m.Airflow) { // not required + return nil + } + + if m.Airflow != nil { + if err := m.Airflow.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("airflow") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("airflow") + } + return err + } + } + + return nil +} + func (m *DeviceWithConfigContext) validateAssetTag(formats strfmt.Registry) error { if swag.IsZero(m.AssetTag) { // not required return nil @@ -399,8 +423,9 @@ func (m *DeviceWithConfigContext) validateLocation(formats strfmt.Registry) erro } func (m *DeviceWithConfigContext) validateName(formats strfmt.Registry) error { - if swag.IsZero(m.Name) { // not required - return nil + + if err := validate.Required("name", "body", m.Name); err != nil { + return err } if err := validate.MaxLength("name", "body", *m.Name, 64); err != nil { @@ -457,10 +482,6 @@ func (m *DeviceWithConfigContext) validatePosition(formats strfmt.Registry) erro return err } - if err := validate.MaximumInt("position", "body", *m.Position, 32767, false); err != nil { - return err - } - return nil } @@ -703,6 +724,10 @@ func (m *DeviceWithConfigContext) validateVirtualChassis(formats strfmt.Registry func (m *DeviceWithConfigContext) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateAirflow(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateCluster(ctx, formats); err != nil { res = append(res, err) } @@ -793,6 +818,22 @@ func (m *DeviceWithConfigContext) ContextValidate(ctx context.Context, formats s return nil } +func (m *DeviceWithConfigContext) contextValidateAirflow(ctx context.Context, formats strfmt.Registry) error { + + if m.Airflow != nil { + if err := m.Airflow.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("airflow") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("airflow") + } + return err + } + } + + return nil +} + func (m *DeviceWithConfigContext) contextValidateCluster(ctx context.Context, formats strfmt.Registry) error { if m.Cluster != nil { @@ -1116,6 +1157,173 @@ func (m *DeviceWithConfigContext) UnmarshalBinary(b []byte) error { return nil } +// DeviceWithConfigContextAirflow Airflow +// +// swagger:model DeviceWithConfigContextAirflow +type DeviceWithConfigContextAirflow struct { + + // label + // Required: true + // Enum: [Front to rear Rear to front Left to right Right to left Side to rear Passive] + Label *string `json:"label"` + + // value + // Required: true + // Enum: [front-to-rear rear-to-front left-to-right right-to-left side-to-rear passive] + Value *string `json:"value"` +} + +// Validate validates this device with config context airflow +func (m *DeviceWithConfigContextAirflow) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateLabel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateValue(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var deviceWithConfigContextAirflowTypeLabelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["Front to rear","Rear to front","Left to right","Right to left","Side to rear","Passive"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + deviceWithConfigContextAirflowTypeLabelPropEnum = append(deviceWithConfigContextAirflowTypeLabelPropEnum, v) + } +} + +const ( + + // DeviceWithConfigContextAirflowLabelFrontToRear captures enum value "Front to rear" + DeviceWithConfigContextAirflowLabelFrontToRear string = "Front to rear" + + // DeviceWithConfigContextAirflowLabelRearToFront captures enum value "Rear to front" + DeviceWithConfigContextAirflowLabelRearToFront string = "Rear to front" + + // DeviceWithConfigContextAirflowLabelLeftToRight captures enum value "Left to right" + DeviceWithConfigContextAirflowLabelLeftToRight string = "Left to right" + + // DeviceWithConfigContextAirflowLabelRightToLeft captures enum value "Right to left" + DeviceWithConfigContextAirflowLabelRightToLeft string = "Right to left" + + // DeviceWithConfigContextAirflowLabelSideToRear captures enum value "Side to rear" + DeviceWithConfigContextAirflowLabelSideToRear string = "Side to rear" + + // DeviceWithConfigContextAirflowLabelPassive captures enum value "Passive" + DeviceWithConfigContextAirflowLabelPassive string = "Passive" +) + +// prop value enum +func (m *DeviceWithConfigContextAirflow) validateLabelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, deviceWithConfigContextAirflowTypeLabelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *DeviceWithConfigContextAirflow) validateLabel(formats strfmt.Registry) error { + + if err := validate.Required("airflow"+"."+"label", "body", m.Label); err != nil { + return err + } + + // value enum + if err := m.validateLabelEnum("airflow"+"."+"label", "body", *m.Label); err != nil { + return err + } + + return nil +} + +var deviceWithConfigContextAirflowTypeValuePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["front-to-rear","rear-to-front","left-to-right","right-to-left","side-to-rear","passive"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + deviceWithConfigContextAirflowTypeValuePropEnum = append(deviceWithConfigContextAirflowTypeValuePropEnum, v) + } +} + +const ( + + // DeviceWithConfigContextAirflowValueFrontDashToDashRear captures enum value "front-to-rear" + DeviceWithConfigContextAirflowValueFrontDashToDashRear string = "front-to-rear" + + // DeviceWithConfigContextAirflowValueRearDashToDashFront captures enum value "rear-to-front" + DeviceWithConfigContextAirflowValueRearDashToDashFront string = "rear-to-front" + + // DeviceWithConfigContextAirflowValueLeftDashToDashRight captures enum value "left-to-right" + DeviceWithConfigContextAirflowValueLeftDashToDashRight string = "left-to-right" + + // DeviceWithConfigContextAirflowValueRightDashToDashLeft captures enum value "right-to-left" + DeviceWithConfigContextAirflowValueRightDashToDashLeft string = "right-to-left" + + // DeviceWithConfigContextAirflowValueSideDashToDashRear captures enum value "side-to-rear" + DeviceWithConfigContextAirflowValueSideDashToDashRear string = "side-to-rear" + + // DeviceWithConfigContextAirflowValuePassive captures enum value "passive" + DeviceWithConfigContextAirflowValuePassive string = "passive" +) + +// prop value enum +func (m *DeviceWithConfigContextAirflow) validateValueEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, deviceWithConfigContextAirflowTypeValuePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *DeviceWithConfigContextAirflow) validateValue(formats strfmt.Registry) error { + + if err := validate.Required("airflow"+"."+"value", "body", m.Value); err != nil { + return err + } + + // value enum + if err := m.validateValueEnum("airflow"+"."+"value", "body", *m.Value); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this device with config context airflow based on context it is used +func (m *DeviceWithConfigContextAirflow) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *DeviceWithConfigContextAirflow) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *DeviceWithConfigContextAirflow) UnmarshalBinary(b []byte) error { + var res DeviceWithConfigContextAirflow + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + // DeviceWithConfigContextFace Face // // swagger:model DeviceWithConfigContextFace diff --git a/netbox/models/export_template.go b/netbox/models/export_template.go index 2133cdf2..1addd5cc 100644 --- a/netbox/models/export_template.go +++ b/netbox/models/export_template.go @@ -43,6 +43,11 @@ type ExportTemplate struct { // Required: true ContentType *string `json:"content_type"` + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Description // Max Length: 200 Description string `json:"description,omitempty"` @@ -61,6 +66,11 @@ type ExportTemplate struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // MIME type // // Defaults to text/plain @@ -94,6 +104,10 @@ func (m *ExportTemplate) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateDescription(formats); err != nil { res = append(res, err) } @@ -102,6 +116,10 @@ func (m *ExportTemplate) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateMimeType(formats); err != nil { res = append(res, err) } @@ -133,6 +151,18 @@ func (m *ExportTemplate) validateContentType(formats strfmt.Registry) error { return nil } +func (m *ExportTemplate) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *ExportTemplate) validateDescription(formats strfmt.Registry) error { if swag.IsZero(m.Description) { // not required return nil @@ -157,6 +187,18 @@ func (m *ExportTemplate) validateFileExtension(formats strfmt.Registry) error { return nil } +func (m *ExportTemplate) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *ExportTemplate) validateMimeType(formats strfmt.Registry) error { if swag.IsZero(m.MimeType) { // not required return nil @@ -215,6 +257,10 @@ func (m *ExportTemplate) validateURL(formats strfmt.Registry) error { func (m *ExportTemplate) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -223,6 +269,10 @@ func (m *ExportTemplate) ContextValidate(ctx context.Context, formats strfmt.Reg res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -233,6 +283,15 @@ func (m *ExportTemplate) ContextValidate(ctx context.Context, formats strfmt.Reg return nil } +func (m *ExportTemplate) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *ExportTemplate) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -251,6 +310,15 @@ func (m *ExportTemplate) contextValidateID(ctx context.Context, formats strfmt.R return nil } +func (m *ExportTemplate) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *ExportTemplate) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/f_h_r_p_group.go b/netbox/models/f_h_r_p_group.go new file mode 100644 index 00000000..ba3aa248 --- /dev/null +++ b/netbox/models/f_h_r_p_group.go @@ -0,0 +1,518 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "encoding/json" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// FHRPGroup f h r p group +// +// swagger:model FHRPGroup +type FHRPGroup struct { + + // Authentication key + // Max Length: 255 + AuthKey string `json:"auth_key,omitempty"` + + // Authentication type + // Enum: [plaintext md5] + AuthType string `json:"auth_type,omitempty"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Group ID + // Required: true + // Maximum: 32767 + // Minimum: 0 + GroupID *int64 `json:"group_id"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // ip addresses + // Read Only: true + IPAddresses []*NestedIPAddress `json:"ip_addresses"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Protocol + // Required: true + // Enum: [vrrp2 vrrp3 carp clusterxl hsrp glbp other] + Protocol *string `json:"protocol"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this f h r p group +func (m *FHRPGroup) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAuthKey(formats); err != nil { + res = append(res, err) + } + + if err := m.validateAuthType(formats); err != nil { + res = append(res, err) + } + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateGroupID(formats); err != nil { + res = append(res, err) + } + + if err := m.validateIPAddresses(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateProtocol(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *FHRPGroup) validateAuthKey(formats strfmt.Registry) error { + if swag.IsZero(m.AuthKey) { // not required + return nil + } + + if err := validate.MaxLength("auth_key", "body", m.AuthKey, 255); err != nil { + return err + } + + return nil +} + +var fHRPGroupTypeAuthTypePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["plaintext","md5"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + fHRPGroupTypeAuthTypePropEnum = append(fHRPGroupTypeAuthTypePropEnum, v) + } +} + +const ( + + // FHRPGroupAuthTypePlaintext captures enum value "plaintext" + FHRPGroupAuthTypePlaintext string = "plaintext" + + // FHRPGroupAuthTypeMd5 captures enum value "md5" + FHRPGroupAuthTypeMd5 string = "md5" +) + +// prop value enum +func (m *FHRPGroup) validateAuthTypeEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, fHRPGroupTypeAuthTypePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *FHRPGroup) validateAuthType(formats strfmt.Registry) error { + if swag.IsZero(m.AuthType) { // not required + return nil + } + + // value enum + if err := m.validateAuthTypeEnum("auth_type", "body", m.AuthType); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroup) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroup) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroup) validateGroupID(formats strfmt.Registry) error { + + if err := validate.Required("group_id", "body", m.GroupID); err != nil { + return err + } + + if err := validate.MinimumInt("group_id", "body", *m.GroupID, 0, false); err != nil { + return err + } + + if err := validate.MaximumInt("group_id", "body", *m.GroupID, 32767, false); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroup) validateIPAddresses(formats strfmt.Registry) error { + if swag.IsZero(m.IPAddresses) { // not required + return nil + } + + for i := 0; i < len(m.IPAddresses); i++ { + if swag.IsZero(m.IPAddresses[i]) { // not required + continue + } + + if m.IPAddresses[i] != nil { + if err := m.IPAddresses[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("ip_addresses" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("ip_addresses" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *FHRPGroup) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +var fHRPGroupTypeProtocolPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["vrrp2","vrrp3","carp","clusterxl","hsrp","glbp","other"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + fHRPGroupTypeProtocolPropEnum = append(fHRPGroupTypeProtocolPropEnum, v) + } +} + +const ( + + // FHRPGroupProtocolVrrp2 captures enum value "vrrp2" + FHRPGroupProtocolVrrp2 string = "vrrp2" + + // FHRPGroupProtocolVrrp3 captures enum value "vrrp3" + FHRPGroupProtocolVrrp3 string = "vrrp3" + + // FHRPGroupProtocolCarp captures enum value "carp" + FHRPGroupProtocolCarp string = "carp" + + // FHRPGroupProtocolClusterxl captures enum value "clusterxl" + FHRPGroupProtocolClusterxl string = "clusterxl" + + // FHRPGroupProtocolHsrp captures enum value "hsrp" + FHRPGroupProtocolHsrp string = "hsrp" + + // FHRPGroupProtocolGlbp captures enum value "glbp" + FHRPGroupProtocolGlbp string = "glbp" + + // FHRPGroupProtocolOther captures enum value "other" + FHRPGroupProtocolOther string = "other" +) + +// prop value enum +func (m *FHRPGroup) validateProtocolEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, fHRPGroupTypeProtocolPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *FHRPGroup) validateProtocol(formats strfmt.Registry) error { + + if err := validate.Required("protocol", "body", m.Protocol); err != nil { + return err + } + + // value enum + if err := m.validateProtocolEnum("protocol", "body", *m.Protocol); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroup) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *FHRPGroup) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this f h r p group based on the context it is used +func (m *FHRPGroup) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateIPAddresses(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *FHRPGroup) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroup) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroup) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroup) contextValidateIPAddresses(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "ip_addresses", "body", []*NestedIPAddress(m.IPAddresses)); err != nil { + return err + } + + for i := 0; i < len(m.IPAddresses); i++ { + + if m.IPAddresses[i] != nil { + if err := m.IPAddresses[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("ip_addresses" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("ip_addresses" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *FHRPGroup) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroup) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *FHRPGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *FHRPGroup) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *FHRPGroup) UnmarshalBinary(b []byte) error { + var res FHRPGroup + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/f_h_r_p_group_assignment.go b/netbox/models/f_h_r_p_group_assignment.go new file mode 100644 index 00000000..19aaf6b5 --- /dev/null +++ b/netbox/models/f_h_r_p_group_assignment.go @@ -0,0 +1,342 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// FHRPGroupAssignment f h r p group assignment +// +// swagger:model FHRPGroupAssignment +type FHRPGroupAssignment struct { + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // group + // Required: true + Group *NestedFHRPGroup `json:"group"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Interface + // Read Only: true + Interface map[string]*string `json:"interface,omitempty"` + + // Interface id + // Required: true + // Maximum: 2.147483647e+09 + // Minimum: 0 + InterfaceID *int64 `json:"interface_id"` + + // Interface type + // Required: true + InterfaceType *string `json:"interface_type"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Priority + // Required: true + // Maximum: 255 + // Minimum: 0 + Priority *int64 `json:"priority"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this f h r p group assignment +func (m *FHRPGroupAssignment) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateGroup(formats); err != nil { + res = append(res, err) + } + + if err := m.validateInterfaceID(formats); err != nil { + res = append(res, err) + } + + if err := m.validateInterfaceType(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validatePriority(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *FHRPGroupAssignment) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroupAssignment) validateGroup(formats strfmt.Registry) error { + + if err := validate.Required("group", "body", m.Group); err != nil { + return err + } + + if m.Group != nil { + if err := m.Group.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("group") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("group") + } + return err + } + } + + return nil +} + +func (m *FHRPGroupAssignment) validateInterfaceID(formats strfmt.Registry) error { + + if err := validate.Required("interface_id", "body", m.InterfaceID); err != nil { + return err + } + + if err := validate.MinimumInt("interface_id", "body", *m.InterfaceID, 0, false); err != nil { + return err + } + + if err := validate.MaximumInt("interface_id", "body", *m.InterfaceID, 2.147483647e+09, false); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroupAssignment) validateInterfaceType(formats strfmt.Registry) error { + + if err := validate.Required("interface_type", "body", m.InterfaceType); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroupAssignment) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroupAssignment) validatePriority(formats strfmt.Registry) error { + + if err := validate.Required("priority", "body", m.Priority); err != nil { + return err + } + + if err := validate.MinimumInt("priority", "body", *m.Priority, 0, false); err != nil { + return err + } + + if err := validate.MaximumInt("priority", "body", *m.Priority, 255, false); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroupAssignment) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this f h r p group assignment based on the context it is used +func (m *FHRPGroupAssignment) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateGroup(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateInterface(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *FHRPGroupAssignment) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroupAssignment) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroupAssignment) contextValidateGroup(ctx context.Context, formats strfmt.Registry) error { + + if m.Group != nil { + if err := m.Group.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("group") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("group") + } + return err + } + } + + return nil +} + +func (m *FHRPGroupAssignment) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroupAssignment) contextValidateInterface(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *FHRPGroupAssignment) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *FHRPGroupAssignment) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *FHRPGroupAssignment) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *FHRPGroupAssignment) UnmarshalBinary(b []byte) error { + var res FHRPGroupAssignment + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/front_port.go b/netbox/models/front_port.go index 66799244..e3e1f336 100644 --- a/netbox/models/front_port.go +++ b/netbox/models/front_port.go @@ -43,18 +43,6 @@ type FrontPort struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Color // Max Length: 6 // Pattern: ^[0-9a-f]{6}$ @@ -95,6 +83,18 @@ type FrontPort struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -416,31 +416,31 @@ func (m *FrontPort) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { + if err := m.contextValidateCreated(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { + if err := m.contextValidateDevice(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCreated(ctx, formats); err != nil { + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateDevice(ctx, formats); err != nil { + if err := m.contextValidateID(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateDisplay(ctx, formats); err != nil { + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateID(ctx, formats); err != nil { + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { res = append(res, err) } @@ -491,20 +491,6 @@ func (m *FrontPort) contextValidateCable(ctx context.Context, formats strfmt.Reg return nil } -func (m *FrontPort) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *FrontPort) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *FrontPort) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { @@ -557,6 +543,20 @@ func (m *FrontPort) contextValidateLastUpdated(ctx context.Context, formats strf return nil } +func (m *FrontPort) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *FrontPort) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *FrontPort) contextValidateRearPort(ctx context.Context, formats strfmt.Registry) error { if m.RearPort != nil { @@ -643,12 +643,12 @@ type FrontPortType struct { // label // Required: true - // Enum: [8P8C 8P6C 8P4C 8P2C 6P6C 6P4C 6P2C 4P4C 4P2C GG45 TERA 4P TERA 2P TERA 1P 110 Punch BNC F Connector N Connector MRJ21 FC LC LC/APC LSH LSH/APC MPO MTRJ SC SC/APC ST CS SN SMA 905 SMA 906 URM-P2 URM-P4 URM-P8 Splice] + // Enum: [8P8C 8P6C 8P4C 8P2C 6P6C 6P4C 6P2C 4P4C 4P2C GG45 TERA 4P TERA 2P TERA 1P 110 Punch BNC F Connector N Connector MRJ21 FC LC LC/PC LC/UPC LC/APC LSH LSH/PC LSH/UPC LSH/APC MPO MTRJ SC SC/PC SC/UPC SC/APC ST CS SN SMA 905 SMA 906 URM-P2 URM-P4 URM-P8 Splice] Label *string `json:"label"` // value // Required: true - // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-apc lsh lsh-apc mpo mtrj sc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] + // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-pc lc-upc lc-apc lsh lsh-pc lsh-upc lsh-apc mpo mtrj sc sc-pc sc-upc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] Value *string `json:"value"` } @@ -674,7 +674,7 @@ var frontPortTypeTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8P8C","8P6C","8P4C","8P2C","6P6C","6P4C","6P2C","4P4C","4P2C","GG45","TERA 4P","TERA 2P","TERA 1P","110 Punch","BNC","F Connector","N Connector","MRJ21","FC","LC","LC/APC","LSH","LSH/APC","MPO","MTRJ","SC","SC/APC","ST","CS","SN","SMA 905","SMA 906","URM-P2","URM-P4","URM-P8","Splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8P8C","8P6C","8P4C","8P2C","6P6C","6P4C","6P2C","4P4C","4P2C","GG45","TERA 4P","TERA 2P","TERA 1P","110 Punch","BNC","F Connector","N Connector","MRJ21","FC","LC","LC/PC","LC/UPC","LC/APC","LSH","LSH/PC","LSH/UPC","LSH/APC","MPO","MTRJ","SC","SC/PC","SC/UPC","SC/APC","ST","CS","SN","SMA 905","SMA 906","URM-P2","URM-P4","URM-P8","Splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -744,12 +744,24 @@ const ( // FrontPortTypeLabelLC captures enum value "LC" FrontPortTypeLabelLC string = "LC" + // FrontPortTypeLabelLCPC captures enum value "LC/PC" + FrontPortTypeLabelLCPC string = "LC/PC" + + // FrontPortTypeLabelLCUPC captures enum value "LC/UPC" + FrontPortTypeLabelLCUPC string = "LC/UPC" + // FrontPortTypeLabelLCAPC captures enum value "LC/APC" FrontPortTypeLabelLCAPC string = "LC/APC" // FrontPortTypeLabelLSH captures enum value "LSH" FrontPortTypeLabelLSH string = "LSH" + // FrontPortTypeLabelLSHPC captures enum value "LSH/PC" + FrontPortTypeLabelLSHPC string = "LSH/PC" + + // FrontPortTypeLabelLSHUPC captures enum value "LSH/UPC" + FrontPortTypeLabelLSHUPC string = "LSH/UPC" + // FrontPortTypeLabelLSHAPC captures enum value "LSH/APC" FrontPortTypeLabelLSHAPC string = "LSH/APC" @@ -762,6 +774,12 @@ const ( // FrontPortTypeLabelSC captures enum value "SC" FrontPortTypeLabelSC string = "SC" + // FrontPortTypeLabelSCPC captures enum value "SC/PC" + FrontPortTypeLabelSCPC string = "SC/PC" + + // FrontPortTypeLabelSCUPC captures enum value "SC/UPC" + FrontPortTypeLabelSCUPC string = "SC/UPC" + // FrontPortTypeLabelSCAPC captures enum value "SC/APC" FrontPortTypeLabelSCAPC string = "SC/APC" @@ -819,7 +837,7 @@ var frontPortTypeTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-apc","lsh","lsh-apc","mpo","mtrj","sc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-pc","lc-upc","lc-apc","lsh","lsh-pc","lsh-upc","lsh-apc","mpo","mtrj","sc","sc-pc","sc-upc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -889,12 +907,24 @@ const ( // FrontPortTypeValueLc captures enum value "lc" FrontPortTypeValueLc string = "lc" + // FrontPortTypeValueLcDashPc captures enum value "lc-pc" + FrontPortTypeValueLcDashPc string = "lc-pc" + + // FrontPortTypeValueLcDashUpc captures enum value "lc-upc" + FrontPortTypeValueLcDashUpc string = "lc-upc" + // FrontPortTypeValueLcDashApc captures enum value "lc-apc" FrontPortTypeValueLcDashApc string = "lc-apc" // FrontPortTypeValueLsh captures enum value "lsh" FrontPortTypeValueLsh string = "lsh" + // FrontPortTypeValueLshDashPc captures enum value "lsh-pc" + FrontPortTypeValueLshDashPc string = "lsh-pc" + + // FrontPortTypeValueLshDashUpc captures enum value "lsh-upc" + FrontPortTypeValueLshDashUpc string = "lsh-upc" + // FrontPortTypeValueLshDashApc captures enum value "lsh-apc" FrontPortTypeValueLshDashApc string = "lsh-apc" @@ -907,6 +937,12 @@ const ( // FrontPortTypeValueSc captures enum value "sc" FrontPortTypeValueSc string = "sc" + // FrontPortTypeValueScDashPc captures enum value "sc-pc" + FrontPortTypeValueScDashPc string = "sc-pc" + + // FrontPortTypeValueScDashUpc captures enum value "sc-upc" + FrontPortTypeValueScDashUpc string = "sc-upc" + // FrontPortTypeValueScDashApc captures enum value "sc-apc" FrontPortTypeValueScDashApc string = "sc-apc" diff --git a/netbox/models/front_port_template.go b/netbox/models/front_port_template.go index 4bbe4614..f1b3344e 100644 --- a/netbox/models/front_port_template.go +++ b/netbox/models/front_port_template.go @@ -480,12 +480,12 @@ type FrontPortTemplateType struct { // label // Required: true - // Enum: [8P8C 8P6C 8P4C 8P2C 6P6C 6P4C 6P2C 4P4C 4P2C GG45 TERA 4P TERA 2P TERA 1P 110 Punch BNC F Connector N Connector MRJ21 FC LC LC/APC LSH LSH/APC MPO MTRJ SC SC/APC ST CS SN SMA 905 SMA 906 URM-P2 URM-P4 URM-P8 Splice] + // Enum: [8P8C 8P6C 8P4C 8P2C 6P6C 6P4C 6P2C 4P4C 4P2C GG45 TERA 4P TERA 2P TERA 1P 110 Punch BNC F Connector N Connector MRJ21 FC LC LC/PC LC/UPC LC/APC LSH LSH/PC LSH/UPC LSH/APC MPO MTRJ SC SC/PC SC/UPC SC/APC ST CS SN SMA 905 SMA 906 URM-P2 URM-P4 URM-P8 Splice] Label *string `json:"label"` // value // Required: true - // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-apc lsh lsh-apc mpo mtrj sc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] + // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-pc lc-upc lc-apc lsh lsh-pc lsh-upc lsh-apc mpo mtrj sc sc-pc sc-upc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] Value *string `json:"value"` } @@ -511,7 +511,7 @@ var frontPortTemplateTypeTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8P8C","8P6C","8P4C","8P2C","6P6C","6P4C","6P2C","4P4C","4P2C","GG45","TERA 4P","TERA 2P","TERA 1P","110 Punch","BNC","F Connector","N Connector","MRJ21","FC","LC","LC/APC","LSH","LSH/APC","MPO","MTRJ","SC","SC/APC","ST","CS","SN","SMA 905","SMA 906","URM-P2","URM-P4","URM-P8","Splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8P8C","8P6C","8P4C","8P2C","6P6C","6P4C","6P2C","4P4C","4P2C","GG45","TERA 4P","TERA 2P","TERA 1P","110 Punch","BNC","F Connector","N Connector","MRJ21","FC","LC","LC/PC","LC/UPC","LC/APC","LSH","LSH/PC","LSH/UPC","LSH/APC","MPO","MTRJ","SC","SC/PC","SC/UPC","SC/APC","ST","CS","SN","SMA 905","SMA 906","URM-P2","URM-P4","URM-P8","Splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -581,12 +581,24 @@ const ( // FrontPortTemplateTypeLabelLC captures enum value "LC" FrontPortTemplateTypeLabelLC string = "LC" + // FrontPortTemplateTypeLabelLCPC captures enum value "LC/PC" + FrontPortTemplateTypeLabelLCPC string = "LC/PC" + + // FrontPortTemplateTypeLabelLCUPC captures enum value "LC/UPC" + FrontPortTemplateTypeLabelLCUPC string = "LC/UPC" + // FrontPortTemplateTypeLabelLCAPC captures enum value "LC/APC" FrontPortTemplateTypeLabelLCAPC string = "LC/APC" // FrontPortTemplateTypeLabelLSH captures enum value "LSH" FrontPortTemplateTypeLabelLSH string = "LSH" + // FrontPortTemplateTypeLabelLSHPC captures enum value "LSH/PC" + FrontPortTemplateTypeLabelLSHPC string = "LSH/PC" + + // FrontPortTemplateTypeLabelLSHUPC captures enum value "LSH/UPC" + FrontPortTemplateTypeLabelLSHUPC string = "LSH/UPC" + // FrontPortTemplateTypeLabelLSHAPC captures enum value "LSH/APC" FrontPortTemplateTypeLabelLSHAPC string = "LSH/APC" @@ -599,6 +611,12 @@ const ( // FrontPortTemplateTypeLabelSC captures enum value "SC" FrontPortTemplateTypeLabelSC string = "SC" + // FrontPortTemplateTypeLabelSCPC captures enum value "SC/PC" + FrontPortTemplateTypeLabelSCPC string = "SC/PC" + + // FrontPortTemplateTypeLabelSCUPC captures enum value "SC/UPC" + FrontPortTemplateTypeLabelSCUPC string = "SC/UPC" + // FrontPortTemplateTypeLabelSCAPC captures enum value "SC/APC" FrontPortTemplateTypeLabelSCAPC string = "SC/APC" @@ -656,7 +674,7 @@ var frontPortTemplateTypeTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-apc","lsh","lsh-apc","mpo","mtrj","sc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-pc","lc-upc","lc-apc","lsh","lsh-pc","lsh-upc","lsh-apc","mpo","mtrj","sc","sc-pc","sc-upc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -726,12 +744,24 @@ const ( // FrontPortTemplateTypeValueLc captures enum value "lc" FrontPortTemplateTypeValueLc string = "lc" + // FrontPortTemplateTypeValueLcDashPc captures enum value "lc-pc" + FrontPortTemplateTypeValueLcDashPc string = "lc-pc" + + // FrontPortTemplateTypeValueLcDashUpc captures enum value "lc-upc" + FrontPortTemplateTypeValueLcDashUpc string = "lc-upc" + // FrontPortTemplateTypeValueLcDashApc captures enum value "lc-apc" FrontPortTemplateTypeValueLcDashApc string = "lc-apc" // FrontPortTemplateTypeValueLsh captures enum value "lsh" FrontPortTemplateTypeValueLsh string = "lsh" + // FrontPortTemplateTypeValueLshDashPc captures enum value "lsh-pc" + FrontPortTemplateTypeValueLshDashPc string = "lsh-pc" + + // FrontPortTemplateTypeValueLshDashUpc captures enum value "lsh-upc" + FrontPortTemplateTypeValueLshDashUpc string = "lsh-upc" + // FrontPortTemplateTypeValueLshDashApc captures enum value "lsh-apc" FrontPortTemplateTypeValueLshDashApc string = "lsh-apc" @@ -744,6 +774,12 @@ const ( // FrontPortTemplateTypeValueSc captures enum value "sc" FrontPortTemplateTypeValueSc string = "sc" + // FrontPortTemplateTypeValueScDashPc captures enum value "sc-pc" + FrontPortTemplateTypeValueScDashPc string = "sc-pc" + + // FrontPortTemplateTypeValueScDashUpc captures enum value "sc-upc" + FrontPortTemplateTypeValueScDashUpc string = "sc-upc" + // FrontPortTemplateTypeValueScDashApc captures enum value "sc-apc" FrontPortTemplateTypeValueScDashApc string = "sc-apc" diff --git a/netbox/models/image_attachment.go b/netbox/models/image_attachment.go index 76b8447e..a2600690 100644 --- a/netbox/models/image_attachment.go +++ b/netbox/models/image_attachment.go @@ -68,6 +68,11 @@ type ImageAttachment struct { // Minimum: 0 ImageWidth *int64 `json:"image_width"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Name // Max Length: 50 Name string `json:"name,omitempty"` @@ -112,6 +117,10 @@ func (m *ImageAttachment) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateName(formats); err != nil { res = append(res, err) } @@ -197,6 +206,18 @@ func (m *ImageAttachment) validateImageWidth(formats strfmt.Registry) error { return nil } +func (m *ImageAttachment) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *ImageAttachment) validateName(formats strfmt.Registry) error { if swag.IsZero(m.Name) { // not required return nil @@ -258,6 +279,10 @@ func (m *ImageAttachment) ContextValidate(ctx context.Context, formats strfmt.Re res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateParent(ctx, formats); err != nil { res = append(res, err) } @@ -308,6 +333,15 @@ func (m *ImageAttachment) contextValidateImage(ctx context.Context, formats strf return nil } +func (m *ImageAttachment) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *ImageAttachment) contextValidateParent(ctx context.Context, formats strfmt.Registry) error { return nil diff --git a/netbox/models/interface.go b/netbox/models/interface.go index 59fd86e7..357d9f16 100644 --- a/netbox/models/interface.go +++ b/netbox/models/interface.go @@ -40,21 +40,12 @@ type Interface struct { // Read Only: true Occupied *bool `json:"_occupied,omitempty"` + // bridge + Bridge *NestedInterface `json:"bridge,omitempty"` + // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Connected endpoint // // @@ -71,6 +62,10 @@ type Interface struct { // Read Only: true ConnectedEndpointType string `json:"connected_endpoint_type,omitempty"` + // Count fhrp groups + // Read Only: true + CountFhrpGroups int64 `json:"count_fhrp_groups,omitempty"` + // Count ipaddresses // Read Only: true CountIpaddresses int64 `json:"count_ipaddresses,omitempty"` @@ -116,6 +111,18 @@ type Interface struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // MAC Address MacAddress *string `json:"mac_address,omitempty"` @@ -146,6 +153,18 @@ type Interface struct { // parent Parent *NestedInterface `json:"parent,omitempty"` + // rf channel + RfChannel *InterfaceRfChannel `json:"rf_channel,omitempty"` + + // Channel frequency (MHz) + RfChannelFrequency *float64 `json:"rf_channel_frequency,omitempty"` + + // Channel width (MHz) + RfChannelWidth *float64 `json:"rf_channel_width,omitempty"` + + // rf role + RfRole *InterfaceRfRole `json:"rf_role,omitempty"` + // tagged vlans // Unique: true TaggedVlans []*NestedVLAN `json:"tagged_vlans"` @@ -153,6 +172,11 @@ type Interface struct { // tags Tags []*NestedTag `json:"tags"` + // Transmit power (dBm) + // Maximum: 127 + // Minimum: 0 + TxPower *int64 `json:"tx_power,omitempty"` + // type // Required: true Type *InterfaceType `json:"type"` @@ -164,12 +188,28 @@ type Interface struct { // Read Only: true // Format: uri URL strfmt.URI `json:"url,omitempty"` + + // wireless lans + // Unique: true + WirelessLans []*NestedWirelessLAN `json:"wireless_lans"` + + // wireless link + WirelessLink *NestedWirelessLink `json:"wireless_link,omitempty"` + + // WWN + // + // 64-bit World Wide Name + Wwn *string `json:"wwn,omitempty"` } // Validate validates this interface func (m *Interface) Validate(formats strfmt.Registry) error { var res []error + if err := m.validateBridge(formats); err != nil { + res = append(res, err) + } + if err := m.validateCable(formats); err != nil { res = append(res, err) } @@ -214,6 +254,14 @@ func (m *Interface) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateRfChannel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateRfRole(formats); err != nil { + res = append(res, err) + } + if err := m.validateTaggedVlans(formats); err != nil { res = append(res, err) } @@ -222,6 +270,10 @@ func (m *Interface) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTxPower(formats); err != nil { + res = append(res, err) + } + if err := m.validateType(formats); err != nil { res = append(res, err) } @@ -234,12 +286,39 @@ func (m *Interface) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateWirelessLans(formats); err != nil { + res = append(res, err) + } + + if err := m.validateWirelessLink(formats); err != nil { + res = append(res, err) + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } return nil } +func (m *Interface) validateBridge(formats strfmt.Registry) error { + if swag.IsZero(m.Bridge) { // not required + return nil + } + + if m.Bridge != nil { + if err := m.Bridge.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("bridge") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("bridge") + } + return err + } + } + + return nil +} + func (m *Interface) validateCable(formats strfmt.Registry) error { if swag.IsZero(m.Cable) { // not required return nil @@ -417,6 +496,44 @@ func (m *Interface) validateParent(formats strfmt.Registry) error { return nil } +func (m *Interface) validateRfChannel(formats strfmt.Registry) error { + if swag.IsZero(m.RfChannel) { // not required + return nil + } + + if m.RfChannel != nil { + if err := m.RfChannel.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("rf_channel") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("rf_channel") + } + return err + } + } + + return nil +} + +func (m *Interface) validateRfRole(formats strfmt.Registry) error { + if swag.IsZero(m.RfRole) { // not required + return nil + } + + if m.RfRole != nil { + if err := m.RfRole.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("rf_role") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("rf_role") + } + return err + } + } + + return nil +} + func (m *Interface) validateTaggedVlans(formats strfmt.Registry) error { if swag.IsZero(m.TaggedVlans) { // not required return nil @@ -473,6 +590,22 @@ func (m *Interface) validateTags(formats strfmt.Registry) error { return nil } +func (m *Interface) validateTxPower(formats strfmt.Registry) error { + if swag.IsZero(m.TxPower) { // not required + return nil + } + + if err := validate.MinimumInt("tx_power", "body", *m.TxPower, 0, false); err != nil { + return err + } + + if err := validate.MaximumInt("tx_power", "body", *m.TxPower, 127, false); err != nil { + return err + } + + return nil +} + func (m *Interface) validateType(formats strfmt.Registry) error { if err := validate.Required("type", "body", m.Type); err != nil { @@ -524,6 +657,55 @@ func (m *Interface) validateURL(formats strfmt.Registry) error { return nil } +func (m *Interface) validateWirelessLans(formats strfmt.Registry) error { + if swag.IsZero(m.WirelessLans) { // not required + return nil + } + + if err := validate.UniqueItems("wireless_lans", "body", m.WirelessLans); err != nil { + return err + } + + for i := 0; i < len(m.WirelessLans); i++ { + if swag.IsZero(m.WirelessLans[i]) { // not required + continue + } + + if m.WirelessLans[i] != nil { + if err := m.WirelessLans[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("wireless_lans" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("wireless_lans" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *Interface) validateWirelessLink(formats strfmt.Registry) error { + if swag.IsZero(m.WirelessLink) { // not required + return nil + } + + if m.WirelessLink != nil { + if err := m.WirelessLink.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("wireless_link") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("wireless_link") + } + return err + } + } + + return nil +} + // ContextValidate validate this interface based on the context it is used func (m *Interface) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error @@ -532,15 +714,11 @@ func (m *Interface) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } - if err := m.contextValidateCable(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeer(ctx, formats); err != nil { + if err := m.contextValidateBridge(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { + if err := m.contextValidateCable(ctx, formats); err != nil { res = append(res, err) } @@ -556,6 +734,10 @@ func (m *Interface) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } + if err := m.contextValidateCountFhrpGroups(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateCountIpaddresses(ctx, formats); err != nil { res = append(res, err) } @@ -584,6 +766,14 @@ func (m *Interface) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateMode(ctx, formats); err != nil { res = append(res, err) } @@ -592,6 +782,14 @@ func (m *Interface) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } + if err := m.contextValidateRfChannel(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateRfRole(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTaggedVlans(ctx, formats); err != nil { res = append(res, err) } @@ -612,6 +810,14 @@ func (m *Interface) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } + if err := m.contextValidateWirelessLans(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateWirelessLink(ctx, formats); err != nil { + res = append(res, err) + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } @@ -627,6 +833,22 @@ func (m *Interface) contextValidateOccupied(ctx context.Context, formats strfmt. return nil } +func (m *Interface) contextValidateBridge(ctx context.Context, formats strfmt.Registry) error { + + if m.Bridge != nil { + if err := m.Bridge.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("bridge") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("bridge") + } + return err + } + } + + return nil +} + func (m *Interface) contextValidateCable(ctx context.Context, formats strfmt.Registry) error { if m.Cable != nil { @@ -643,37 +865,32 @@ func (m *Interface) contextValidateCable(ctx context.Context, formats strfmt.Reg return nil } -func (m *Interface) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { +func (m *Interface) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil } -func (m *Interface) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { +func (m *Interface) contextValidateConnectedEndpointReachable(ctx context.Context, formats strfmt.Registry) error { - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { + if err := validate.ReadOnly(ctx, "connected_endpoint_reachable", "body", m.ConnectedEndpointReachable); err != nil { return err } return nil } -func (m *Interface) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *Interface) contextValidateConnectedEndpointReachable(ctx context.Context, formats strfmt.Registry) error { +func (m *Interface) contextValidateConnectedEndpointType(ctx context.Context, formats strfmt.Registry) error { - if err := validate.ReadOnly(ctx, "connected_endpoint_reachable", "body", m.ConnectedEndpointReachable); err != nil { + if err := validate.ReadOnly(ctx, "connected_endpoint_type", "body", string(m.ConnectedEndpointType)); err != nil { return err } return nil } -func (m *Interface) contextValidateConnectedEndpointType(ctx context.Context, formats strfmt.Registry) error { +func (m *Interface) contextValidateCountFhrpGroups(ctx context.Context, formats strfmt.Registry) error { - if err := validate.ReadOnly(ctx, "connected_endpoint_type", "body", string(m.ConnectedEndpointType)); err != nil { + if err := validate.ReadOnly(ctx, "count_fhrp_groups", "body", int64(m.CountFhrpGroups)); err != nil { return err } @@ -757,6 +974,20 @@ func (m *Interface) contextValidateLastUpdated(ctx context.Context, formats strf return nil } +func (m *Interface) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *Interface) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *Interface) contextValidateMode(ctx context.Context, formats strfmt.Registry) error { if m.Mode != nil { @@ -789,6 +1020,38 @@ func (m *Interface) contextValidateParent(ctx context.Context, formats strfmt.Re return nil } +func (m *Interface) contextValidateRfChannel(ctx context.Context, formats strfmt.Registry) error { + + if m.RfChannel != nil { + if err := m.RfChannel.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("rf_channel") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("rf_channel") + } + return err + } + } + + return nil +} + +func (m *Interface) contextValidateRfRole(ctx context.Context, formats strfmt.Registry) error { + + if m.RfRole != nil { + if err := m.RfRole.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("rf_role") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("rf_role") + } + return err + } + } + + return nil +} + func (m *Interface) contextValidateTaggedVlans(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.TaggedVlans); i++ { @@ -870,6 +1133,42 @@ func (m *Interface) contextValidateURL(ctx context.Context, formats strfmt.Regis return nil } +func (m *Interface) contextValidateWirelessLans(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.WirelessLans); i++ { + + if m.WirelessLans[i] != nil { + if err := m.WirelessLans[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("wireless_lans" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("wireless_lans" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *Interface) contextValidateWirelessLink(ctx context.Context, formats strfmt.Registry) error { + + if m.WirelessLink != nil { + if err := m.WirelessLink.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("wireless_link") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("wireless_link") + } + return err + } + } + + return nil +} + // MarshalBinary interface implementation func (m *Interface) MarshalBinary() ([]byte, error) { if m == nil { @@ -1037,24 +1336,24 @@ func (m *InterfaceMode) UnmarshalBinary(b []byte) error { return nil } -// InterfaceType Type +// InterfaceRfChannel Rf channel // -// swagger:model InterfaceType -type InterfaceType struct { +// swagger:model InterfaceRfChannel +type InterfaceRfChannel struct { // label // Required: true - // Enum: [Virtual Link Aggregation Group (LAG) 100BASE-TX (10/100ME) 1000BASE-T (1GE) 2.5GBASE-T (2.5GE) 5GBASE-T (5GE) 10GBASE-T (10GE) 10GBASE-CX4 (10GE) GBIC (1GE) SFP (1GE) SFP+ (10GE) XFP (10GE) XENPAK (10GE) X2 (10GE) SFP28 (25GE) SFP56 (50GE) QSFP+ (40GE) QSFP28 (50GE) CFP (100GE) CFP2 (100GE) CFP2 (200GE) CFP4 (100GE) Cisco CPAK (100GE) QSFP28 (100GE) QSFP56 (200GE) QSFP-DD (400GE) OSFP (400GE) IEEE 802.11a IEEE 802.11b/g IEEE 802.11n IEEE 802.11ac IEEE 802.11ad IEEE 802.11ax IEEE 802.15.1 (Bluetooth) GSM CDMA LTE OC-3/STM-1 OC-12/STM-4 OC-48/STM-16 OC-192/STM-64 OC-768/STM-256 OC-1920/STM-640 OC-3840/STM-1234 SFP (1GFC) SFP (2GFC) SFP (4GFC) SFP+ (8GFC) SFP+ (16GFC) SFP28 (32GFC) QSFP+ (64GFC) QSFP28 (128GFC) SDR (2 Gbps) DDR (4 Gbps) QDR (8 Gbps) FDR10 (10 Gbps) FDR (13.5 Gbps) EDR (25 Gbps) HDR (50 Gbps) NDR (100 Gbps) XDR (250 Gbps) T1 (1.544 Mbps) E1 (2.048 Mbps) T3 (45 Mbps) E3 (34 Mbps) xDSL Cisco StackWise Cisco StackWise Plus Cisco FlexStack Cisco FlexStack Plus Juniper VCP Extreme SummitStack Extreme SummitStack-128 Extreme SummitStack-256 Extreme SummitStack-512 Other] + // Enum: [1 (2412 MHz) 2 (2417 MHz) 3 (2422 MHz) 4 (2427 MHz) 5 (2432 MHz) 6 (2437 MHz) 7 (2442 MHz) 8 (2447 MHz) 9 (2452 MHz) 10 (2457 MHz) 11 (2462 MHz) 12 (2467 MHz) 13 (2472 MHz) 32 (5160/20 MHz) 34 (5170/40 MHz) 36 (5180/20 MHz) 38 (5190/40 MHz) 40 (5200/20 MHz) 42 (5210/80 MHz) 44 (5220/20 MHz) 46 (5230/40 MHz) 48 (5240/20 MHz) 50 (5250/160 MHz) 52 (5260/20 MHz) 54 (5270/40 MHz) 56 (5280/20 MHz) 58 (5290/80 MHz) 60 (5300/20 MHz) 62 (5310/40 MHz) 64 (5320/20 MHz) 100 (5500/20 MHz) 102 (5510/40 MHz) 104 (5520/20 MHz) 106 (5530/80 MHz) 108 (5540/20 MHz) 110 (5550/40 MHz) 112 (5560/20 MHz) 114 (5570/160 MHz) 116 (5580/20 MHz) 118 (5590/40 MHz) 120 (5600/20 MHz) 122 (5610/80 MHz) 124 (5620/20 MHz) 126 (5630/40 MHz) 128 (5640/20 MHz) 132 (5660/20 MHz) 134 (5670/40 MHz) 136 (5680/20 MHz) 138 (5690/80 MHz) 140 (5700/20 MHz) 142 (5710/40 MHz) 144 (5720/20 MHz) 149 (5745/20 MHz) 151 (5755/40 MHz) 153 (5765/20 MHz) 155 (5775/80 MHz) 157 (5785/20 MHz) 159 (5795/40 MHz) 161 (5805/20 MHz) 163 (5815/160 MHz) 165 (5825/20 MHz) 167 (5835/40 MHz) 169 (5845/20 MHz) 171 (5855/80 MHz) 173 (5865/20 MHz) 175 (5875/40 MHz) 177 (5885/20 MHz) 1 (5955/20 MHz) 3 (5965/40 MHz) 5 (5975/20 MHz) 7 (5985/80 MHz) 9 (5995/20 MHz) 11 (6005/40 MHz) 13 (6015/20 MHz) 15 (6025/160 MHz) 17 (6035/20 MHz) 19 (6045/40 MHz) 21 (6055/20 MHz) 23 (6065/80 MHz) 25 (6075/20 MHz) 27 (6085/40 MHz) 29 (6095/20 MHz) 31 (6105/320 MHz) 33 (6115/20 MHz) 35 (6125/40 MHz) 37 (6135/20 MHz) 39 (6145/80 MHz) 41 (6155/20 MHz) 43 (6165/40 MHz) 45 (6175/20 MHz) 47 (6185/160 MHz) 49 (6195/20 MHz) 51 (6205/40 MHz) 53 (6215/20 MHz) 55 (6225/80 MHz) 57 (6235/20 MHz) 59 (6245/40 MHz) 61 (6255/20 MHz) 65 (6275/20 MHz) 67 (6285/40 MHz) 69 (6295/20 MHz) 71 (6305/80 MHz) 73 (6315/20 MHz) 75 (6325/40 MHz) 77 (6335/20 MHz) 79 (6345/160 MHz) 81 (6355/20 MHz) 83 (6365/40 MHz) 85 (6375/20 MHz) 87 (6385/80 MHz) 89 (6395/20 MHz) 91 (6405/40 MHz) 93 (6415/20 MHz) 95 (6425/320 MHz) 97 (6435/20 MHz) 99 (6445/40 MHz) 101 (6455/20 MHz) 103 (6465/80 MHz) 105 (6475/20 MHz) 107 (6485/40 MHz) 109 (6495/20 MHz) 111 (6505/160 MHz) 113 (6515/20 MHz) 115 (6525/40 MHz) 117 (6535/20 MHz) 119 (6545/80 MHz) 121 (6555/20 MHz) 123 (6565/40 MHz) 125 (6575/20 MHz) 129 (6595/20 MHz) 131 (6605/40 MHz) 133 (6615/20 MHz) 135 (6625/80 MHz) 137 (6635/20 MHz) 139 (6645/40 MHz) 141 (6655/20 MHz) 143 (6665/160 MHz) 145 (6675/20 MHz) 147 (6685/40 MHz) 149 (6695/20 MHz) 151 (6705/80 MHz) 153 (6715/20 MHz) 155 (6725/40 MHz) 157 (6735/20 MHz) 159 (6745/320 MHz) 161 (6755/20 MHz) 163 (6765/40 MHz) 165 (6775/20 MHz) 167 (6785/80 MHz) 169 (6795/20 MHz) 171 (6805/40 MHz) 173 (6815/20 MHz) 175 (6825/160 MHz) 177 (6835/20 MHz) 179 (6845/40 MHz) 181 (6855/20 MHz) 183 (6865/80 MHz) 185 (6875/20 MHz) 187 (6885/40 MHz) 189 (6895/20 MHz) 193 (6915/20 MHz) 195 (6925/40 MHz) 197 (6935/20 MHz) 199 (6945/80 MHz) 201 (6955/20 MHz) 203 (6965/40 MHz) 205 (6975/20 MHz) 207 (6985/160 MHz) 209 (6995/20 MHz) 211 (7005/40 MHz) 213 (7015/20 MHz) 215 (7025/80 MHz) 217 (7035/20 MHz) 219 (7045/40 MHz) 221 (7055/20 MHz) 225 (7075/20 MHz) 227 (7085/40 MHz) 229 (7095/20 MHz) 233 (7115/20 MHz) 1 (58.32/2.16 GHz) 2 (60.48/2.16 GHz) 3 (62.64/2.16 GHz) 4 (64.80/2.16 GHz) 5 (66.96/2.16 GHz) 6 (69.12/2.16 GHz) 9 (59.40/4.32 GHz) 10 (61.56/4.32 GHz) 11 (63.72/4.32 GHz) 12 (65.88/4.32 GHz) 13 (68.04/4.32 GHz) 17 (60.48/6.48 GHz) 18 (62.64/6.48 GHz) 19 (64.80/6.48 GHz) 20 (66.96/6.48 GHz) 25 (61.56/8.64 GHz) 26 (63.72/8.64 GHz) 27 (65.88/8.64 GHz)] Label *string `json:"label"` // value // Required: true - // Enum: [virtual lag 100base-tx 1000base-t 2.5gbase-t 5gbase-t 10gbase-t 10gbase-cx4 1000base-x-gbic 1000base-x-sfp 10gbase-x-sfpp 10gbase-x-xfp 10gbase-x-xenpak 10gbase-x-x2 25gbase-x-sfp28 50gbase-x-sfp56 40gbase-x-qsfpp 50gbase-x-sfp28 100gbase-x-cfp 100gbase-x-cfp2 200gbase-x-cfp2 100gbase-x-cfp4 100gbase-x-cpak 100gbase-x-qsfp28 200gbase-x-qsfp56 400gbase-x-qsfpdd 400gbase-x-osfp ieee802.11a ieee802.11g ieee802.11n ieee802.11ac ieee802.11ad ieee802.11ax ieee802.15.1 gsm cdma lte sonet-oc3 sonet-oc12 sonet-oc48 sonet-oc192 sonet-oc768 sonet-oc1920 sonet-oc3840 1gfc-sfp 2gfc-sfp 4gfc-sfp 8gfc-sfpp 16gfc-sfpp 32gfc-sfp28 64gfc-qsfpp 128gfc-sfp28 infiniband-sdr infiniband-ddr infiniband-qdr infiniband-fdr10 infiniband-fdr infiniband-edr infiniband-hdr infiniband-ndr infiniband-xdr t1 e1 t3 e3 xdsl cisco-stackwise cisco-stackwise-plus cisco-flexstack cisco-flexstack-plus juniper-vcp extreme-summitstack extreme-summitstack-128 extreme-summitstack-256 extreme-summitstack-512 other] + // Enum: [2.4g-1-2412-22 2.4g-2-2417-22 2.4g-3-2422-22 2.4g-4-2427-22 2.4g-5-2432-22 2.4g-6-2437-22 2.4g-7-2442-22 2.4g-8-2447-22 2.4g-9-2452-22 2.4g-10-2457-22 2.4g-11-2462-22 2.4g-12-2467-22 2.4g-13-2472-22 5g-32-5160-20 5g-34-5170-40 5g-36-5180-20 5g-38-5190-40 5g-40-5200-20 5g-42-5210-80 5g-44-5220-20 5g-46-5230-40 5g-48-5240-20 5g-50-5250-160 5g-52-5260-20 5g-54-5270-40 5g-56-5280-20 5g-58-5290-80 5g-60-5300-20 5g-62-5310-40 5g-64-5320-20 5g-100-5500-20 5g-102-5510-40 5g-104-5520-20 5g-106-5530-80 5g-108-5540-20 5g-110-5550-40 5g-112-5560-20 5g-114-5570-160 5g-116-5580-20 5g-118-5590-40 5g-120-5600-20 5g-122-5610-80 5g-124-5620-20 5g-126-5630-40 5g-128-5640-20 5g-132-5660-20 5g-134-5670-40 5g-136-5680-20 5g-138-5690-80 5g-140-5700-20 5g-142-5710-40 5g-144-5720-20 5g-149-5745-20 5g-151-5755-40 5g-153-5765-20 5g-155-5775-80 5g-157-5785-20 5g-159-5795-40 5g-161-5805-20 5g-163-5815-160 5g-165-5825-20 5g-167-5835-40 5g-169-5845-20 5g-171-5855-80 5g-173-5865-20 5g-175-5875-40 5g-177-5885-20 6g-1-5955-20 6g-3-5965-40 6g-5-5975-20 6g-7-5985-80 6g-9-5995-20 6g-11-6005-40 6g-13-6015-20 6g-15-6025-160 6g-17-6035-20 6g-19-6045-40 6g-21-6055-20 6g-23-6065-80 6g-25-6075-20 6g-27-6085-40 6g-29-6095-20 6g-31-6105-320 6g-33-6115-20 6g-35-6125-40 6g-37-6135-20 6g-39-6145-80 6g-41-6155-20 6g-43-6165-40 6g-45-6175-20 6g-47-6185-160 6g-49-6195-20 6g-51-6205-40 6g-53-6215-20 6g-55-6225-80 6g-57-6235-20 6g-59-6245-40 6g-61-6255-20 6g-65-6275-20 6g-67-6285-40 6g-69-6295-20 6g-71-6305-80 6g-73-6315-20 6g-75-6325-40 6g-77-6335-20 6g-79-6345-160 6g-81-6355-20 6g-83-6365-40 6g-85-6375-20 6g-87-6385-80 6g-89-6395-20 6g-91-6405-40 6g-93-6415-20 6g-95-6425-320 6g-97-6435-20 6g-99-6445-40 6g-101-6455-20 6g-103-6465-80 6g-105-6475-20 6g-107-6485-40 6g-109-6495-20 6g-111-6505-160 6g-113-6515-20 6g-115-6525-40 6g-117-6535-20 6g-119-6545-80 6g-121-6555-20 6g-123-6565-40 6g-125-6575-20 6g-129-6595-20 6g-131-6605-40 6g-133-6615-20 6g-135-6625-80 6g-137-6635-20 6g-139-6645-40 6g-141-6655-20 6g-143-6665-160 6g-145-6675-20 6g-147-6685-40 6g-149-6695-20 6g-151-6705-80 6g-153-6715-20 6g-155-6725-40 6g-157-6735-20 6g-159-6745-320 6g-161-6755-20 6g-163-6765-40 6g-165-6775-20 6g-167-6785-80 6g-169-6795-20 6g-171-6805-40 6g-173-6815-20 6g-175-6825-160 6g-177-6835-20 6g-179-6845-40 6g-181-6855-20 6g-183-6865-80 6g-185-6875-20 6g-187-6885-40 6g-189-6895-20 6g-193-6915-20 6g-195-6925-40 6g-197-6935-20 6g-199-6945-80 6g-201-6955-20 6g-203-6965-40 6g-205-6975-20 6g-207-6985-160 6g-209-6995-20 6g-211-7005-40 6g-213-7015-20 6g-215-7025-80 6g-217-7035-20 6g-219-7045-40 6g-221-7055-20 6g-225-7075-20 6g-227-7085-40 6g-229-7095-20 6g-233-7115-20 60g-1-58320-2160 60g-2-60480-2160 60g-3-62640-2160 60g-4-64800-2160 60g-5-66960-2160 60g-6-69120-2160 60g-9-59400-4320 60g-10-61560-4320 60g-11-63720-4320 60g-12-65880-4320 60g-13-68040-4320 60g-17-60480-6480 60g-18-62640-6480 60g-19-64800-6480 60g-20-66960-6480 60g-25-61560-6480 60g-26-63720-6480 60g-27-65880-6480] Value *string `json:"value"` } -// Validate validates this interface type -func (m *InterfaceType) Validate(formats strfmt.Registry) error { +// Validate validates this interface rf channel +func (m *InterfaceRfChannel) Validate(formats strfmt.Registry) error { var res []error if err := m.validateLabel(formats); err != nil { @@ -1071,34 +1370,1493 @@ func (m *InterfaceType) Validate(formats strfmt.Registry) error { return nil } -var interfaceTypeTypeLabelPropEnum []interface{} +var interfaceRfChannelTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["Virtual","Link Aggregation Group (LAG)","100BASE-TX (10/100ME)","1000BASE-T (1GE)","2.5GBASE-T (2.5GE)","5GBASE-T (5GE)","10GBASE-T (10GE)","10GBASE-CX4 (10GE)","GBIC (1GE)","SFP (1GE)","SFP+ (10GE)","XFP (10GE)","XENPAK (10GE)","X2 (10GE)","SFP28 (25GE)","SFP56 (50GE)","QSFP+ (40GE)","QSFP28 (50GE)","CFP (100GE)","CFP2 (100GE)","CFP2 (200GE)","CFP4 (100GE)","Cisco CPAK (100GE)","QSFP28 (100GE)","QSFP56 (200GE)","QSFP-DD (400GE)","OSFP (400GE)","IEEE 802.11a","IEEE 802.11b/g","IEEE 802.11n","IEEE 802.11ac","IEEE 802.11ad","IEEE 802.11ax","IEEE 802.15.1 (Bluetooth)","GSM","CDMA","LTE","OC-3/STM-1","OC-12/STM-4","OC-48/STM-16","OC-192/STM-64","OC-768/STM-256","OC-1920/STM-640","OC-3840/STM-1234","SFP (1GFC)","SFP (2GFC)","SFP (4GFC)","SFP+ (8GFC)","SFP+ (16GFC)","SFP28 (32GFC)","QSFP+ (64GFC)","QSFP28 (128GFC)","SDR (2 Gbps)","DDR (4 Gbps)","QDR (8 Gbps)","FDR10 (10 Gbps)","FDR (13.5 Gbps)","EDR (25 Gbps)","HDR (50 Gbps)","NDR (100 Gbps)","XDR (250 Gbps)","T1 (1.544 Mbps)","E1 (2.048 Mbps)","T3 (45 Mbps)","E3 (34 Mbps)","xDSL","Cisco StackWise","Cisco StackWise Plus","Cisco FlexStack","Cisco FlexStack Plus","Juniper VCP","Extreme SummitStack","Extreme SummitStack-128","Extreme SummitStack-256","Extreme SummitStack-512","Other"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["1 (2412 MHz)","2 (2417 MHz)","3 (2422 MHz)","4 (2427 MHz)","5 (2432 MHz)","6 (2437 MHz)","7 (2442 MHz)","8 (2447 MHz)","9 (2452 MHz)","10 (2457 MHz)","11 (2462 MHz)","12 (2467 MHz)","13 (2472 MHz)","32 (5160/20 MHz)","34 (5170/40 MHz)","36 (5180/20 MHz)","38 (5190/40 MHz)","40 (5200/20 MHz)","42 (5210/80 MHz)","44 (5220/20 MHz)","46 (5230/40 MHz)","48 (5240/20 MHz)","50 (5250/160 MHz)","52 (5260/20 MHz)","54 (5270/40 MHz)","56 (5280/20 MHz)","58 (5290/80 MHz)","60 (5300/20 MHz)","62 (5310/40 MHz)","64 (5320/20 MHz)","100 (5500/20 MHz)","102 (5510/40 MHz)","104 (5520/20 MHz)","106 (5530/80 MHz)","108 (5540/20 MHz)","110 (5550/40 MHz)","112 (5560/20 MHz)","114 (5570/160 MHz)","116 (5580/20 MHz)","118 (5590/40 MHz)","120 (5600/20 MHz)","122 (5610/80 MHz)","124 (5620/20 MHz)","126 (5630/40 MHz)","128 (5640/20 MHz)","132 (5660/20 MHz)","134 (5670/40 MHz)","136 (5680/20 MHz)","138 (5690/80 MHz)","140 (5700/20 MHz)","142 (5710/40 MHz)","144 (5720/20 MHz)","149 (5745/20 MHz)","151 (5755/40 MHz)","153 (5765/20 MHz)","155 (5775/80 MHz)","157 (5785/20 MHz)","159 (5795/40 MHz)","161 (5805/20 MHz)","163 (5815/160 MHz)","165 (5825/20 MHz)","167 (5835/40 MHz)","169 (5845/20 MHz)","171 (5855/80 MHz)","173 (5865/20 MHz)","175 (5875/40 MHz)","177 (5885/20 MHz)","1 (5955/20 MHz)","3 (5965/40 MHz)","5 (5975/20 MHz)","7 (5985/80 MHz)","9 (5995/20 MHz)","11 (6005/40 MHz)","13 (6015/20 MHz)","15 (6025/160 MHz)","17 (6035/20 MHz)","19 (6045/40 MHz)","21 (6055/20 MHz)","23 (6065/80 MHz)","25 (6075/20 MHz)","27 (6085/40 MHz)","29 (6095/20 MHz)","31 (6105/320 MHz)","33 (6115/20 MHz)","35 (6125/40 MHz)","37 (6135/20 MHz)","39 (6145/80 MHz)","41 (6155/20 MHz)","43 (6165/40 MHz)","45 (6175/20 MHz)","47 (6185/160 MHz)","49 (6195/20 MHz)","51 (6205/40 MHz)","53 (6215/20 MHz)","55 (6225/80 MHz)","57 (6235/20 MHz)","59 (6245/40 MHz)","61 (6255/20 MHz)","65 (6275/20 MHz)","67 (6285/40 MHz)","69 (6295/20 MHz)","71 (6305/80 MHz)","73 (6315/20 MHz)","75 (6325/40 MHz)","77 (6335/20 MHz)","79 (6345/160 MHz)","81 (6355/20 MHz)","83 (6365/40 MHz)","85 (6375/20 MHz)","87 (6385/80 MHz)","89 (6395/20 MHz)","91 (6405/40 MHz)","93 (6415/20 MHz)","95 (6425/320 MHz)","97 (6435/20 MHz)","99 (6445/40 MHz)","101 (6455/20 MHz)","103 (6465/80 MHz)","105 (6475/20 MHz)","107 (6485/40 MHz)","109 (6495/20 MHz)","111 (6505/160 MHz)","113 (6515/20 MHz)","115 (6525/40 MHz)","117 (6535/20 MHz)","119 (6545/80 MHz)","121 (6555/20 MHz)","123 (6565/40 MHz)","125 (6575/20 MHz)","129 (6595/20 MHz)","131 (6605/40 MHz)","133 (6615/20 MHz)","135 (6625/80 MHz)","137 (6635/20 MHz)","139 (6645/40 MHz)","141 (6655/20 MHz)","143 (6665/160 MHz)","145 (6675/20 MHz)","147 (6685/40 MHz)","149 (6695/20 MHz)","151 (6705/80 MHz)","153 (6715/20 MHz)","155 (6725/40 MHz)","157 (6735/20 MHz)","159 (6745/320 MHz)","161 (6755/20 MHz)","163 (6765/40 MHz)","165 (6775/20 MHz)","167 (6785/80 MHz)","169 (6795/20 MHz)","171 (6805/40 MHz)","173 (6815/20 MHz)","175 (6825/160 MHz)","177 (6835/20 MHz)","179 (6845/40 MHz)","181 (6855/20 MHz)","183 (6865/80 MHz)","185 (6875/20 MHz)","187 (6885/40 MHz)","189 (6895/20 MHz)","193 (6915/20 MHz)","195 (6925/40 MHz)","197 (6935/20 MHz)","199 (6945/80 MHz)","201 (6955/20 MHz)","203 (6965/40 MHz)","205 (6975/20 MHz)","207 (6985/160 MHz)","209 (6995/20 MHz)","211 (7005/40 MHz)","213 (7015/20 MHz)","215 (7025/80 MHz)","217 (7035/20 MHz)","219 (7045/40 MHz)","221 (7055/20 MHz)","225 (7075/20 MHz)","227 (7085/40 MHz)","229 (7095/20 MHz)","233 (7115/20 MHz)","1 (58.32/2.16 GHz)","2 (60.48/2.16 GHz)","3 (62.64/2.16 GHz)","4 (64.80/2.16 GHz)","5 (66.96/2.16 GHz)","6 (69.12/2.16 GHz)","9 (59.40/4.32 GHz)","10 (61.56/4.32 GHz)","11 (63.72/4.32 GHz)","12 (65.88/4.32 GHz)","13 (68.04/4.32 GHz)","17 (60.48/6.48 GHz)","18 (62.64/6.48 GHz)","19 (64.80/6.48 GHz)","20 (66.96/6.48 GHz)","25 (61.56/8.64 GHz)","26 (63.72/8.64 GHz)","27 (65.88/8.64 GHz)"]`), &res); err != nil { panic(err) } for _, v := range res { - interfaceTypeTypeLabelPropEnum = append(interfaceTypeTypeLabelPropEnum, v) + interfaceRfChannelTypeLabelPropEnum = append(interfaceRfChannelTypeLabelPropEnum, v) } } const ( - // InterfaceTypeLabelVirtual captures enum value "Virtual" - InterfaceTypeLabelVirtual string = "Virtual" + // InterfaceRfChannelLabelNr12412MHz captures enum value "1 (2412 MHz)" + InterfaceRfChannelLabelNr12412MHz string = "1 (2412 MHz)" - // InterfaceTypeLabelLinkAggregationGroupLAG captures enum value "Link Aggregation Group (LAG)" - InterfaceTypeLabelLinkAggregationGroupLAG string = "Link Aggregation Group (LAG)" + // InterfaceRfChannelLabelNr22417MHz captures enum value "2 (2417 MHz)" + InterfaceRfChannelLabelNr22417MHz string = "2 (2417 MHz)" - // InterfaceTypeLabelNr100BASEDashTX10100ME captures enum value "100BASE-TX (10/100ME)" - InterfaceTypeLabelNr100BASEDashTX10100ME string = "100BASE-TX (10/100ME)" + // InterfaceRfChannelLabelNr32422MHz captures enum value "3 (2422 MHz)" + InterfaceRfChannelLabelNr32422MHz string = "3 (2422 MHz)" - // InterfaceTypeLabelNr1000BASEDashT1GE captures enum value "1000BASE-T (1GE)" - InterfaceTypeLabelNr1000BASEDashT1GE string = "1000BASE-T (1GE)" + // InterfaceRfChannelLabelNr42427MHz captures enum value "4 (2427 MHz)" + InterfaceRfChannelLabelNr42427MHz string = "4 (2427 MHz)" - // InterfaceTypeLabelNr2Dot5GBASEDashT2Dot5GE captures enum value "2.5GBASE-T (2.5GE)" - InterfaceTypeLabelNr2Dot5GBASEDashT2Dot5GE string = "2.5GBASE-T (2.5GE)" + // InterfaceRfChannelLabelNr52432MHz captures enum value "5 (2432 MHz)" + InterfaceRfChannelLabelNr52432MHz string = "5 (2432 MHz)" + + // InterfaceRfChannelLabelNr62437MHz captures enum value "6 (2437 MHz)" + InterfaceRfChannelLabelNr62437MHz string = "6 (2437 MHz)" + + // InterfaceRfChannelLabelNr72442MHz captures enum value "7 (2442 MHz)" + InterfaceRfChannelLabelNr72442MHz string = "7 (2442 MHz)" + + // InterfaceRfChannelLabelNr82447MHz captures enum value "8 (2447 MHz)" + InterfaceRfChannelLabelNr82447MHz string = "8 (2447 MHz)" + + // InterfaceRfChannelLabelNr92452MHz captures enum value "9 (2452 MHz)" + InterfaceRfChannelLabelNr92452MHz string = "9 (2452 MHz)" + + // InterfaceRfChannelLabelNr102457MHz captures enum value "10 (2457 MHz)" + InterfaceRfChannelLabelNr102457MHz string = "10 (2457 MHz)" + + // InterfaceRfChannelLabelNr112462MHz captures enum value "11 (2462 MHz)" + InterfaceRfChannelLabelNr112462MHz string = "11 (2462 MHz)" + + // InterfaceRfChannelLabelNr122467MHz captures enum value "12 (2467 MHz)" + InterfaceRfChannelLabelNr122467MHz string = "12 (2467 MHz)" + + // InterfaceRfChannelLabelNr132472MHz captures enum value "13 (2472 MHz)" + InterfaceRfChannelLabelNr132472MHz string = "13 (2472 MHz)" + + // InterfaceRfChannelLabelNr32516020MHz captures enum value "32 (5160/20 MHz)" + InterfaceRfChannelLabelNr32516020MHz string = "32 (5160/20 MHz)" + + // InterfaceRfChannelLabelNr34517040MHz captures enum value "34 (5170/40 MHz)" + InterfaceRfChannelLabelNr34517040MHz string = "34 (5170/40 MHz)" + + // InterfaceRfChannelLabelNr36518020MHz captures enum value "36 (5180/20 MHz)" + InterfaceRfChannelLabelNr36518020MHz string = "36 (5180/20 MHz)" + + // InterfaceRfChannelLabelNr38519040MHz captures enum value "38 (5190/40 MHz)" + InterfaceRfChannelLabelNr38519040MHz string = "38 (5190/40 MHz)" + + // InterfaceRfChannelLabelNr40520020MHz captures enum value "40 (5200/20 MHz)" + InterfaceRfChannelLabelNr40520020MHz string = "40 (5200/20 MHz)" + + // InterfaceRfChannelLabelNr42521080MHz captures enum value "42 (5210/80 MHz)" + InterfaceRfChannelLabelNr42521080MHz string = "42 (5210/80 MHz)" + + // InterfaceRfChannelLabelNr44522020MHz captures enum value "44 (5220/20 MHz)" + InterfaceRfChannelLabelNr44522020MHz string = "44 (5220/20 MHz)" + + // InterfaceRfChannelLabelNr46523040MHz captures enum value "46 (5230/40 MHz)" + InterfaceRfChannelLabelNr46523040MHz string = "46 (5230/40 MHz)" + + // InterfaceRfChannelLabelNr48524020MHz captures enum value "48 (5240/20 MHz)" + InterfaceRfChannelLabelNr48524020MHz string = "48 (5240/20 MHz)" + + // InterfaceRfChannelLabelNr505250160MHz captures enum value "50 (5250/160 MHz)" + InterfaceRfChannelLabelNr505250160MHz string = "50 (5250/160 MHz)" + + // InterfaceRfChannelLabelNr52526020MHz captures enum value "52 (5260/20 MHz)" + InterfaceRfChannelLabelNr52526020MHz string = "52 (5260/20 MHz)" + + // InterfaceRfChannelLabelNr54527040MHz captures enum value "54 (5270/40 MHz)" + InterfaceRfChannelLabelNr54527040MHz string = "54 (5270/40 MHz)" + + // InterfaceRfChannelLabelNr56528020MHz captures enum value "56 (5280/20 MHz)" + InterfaceRfChannelLabelNr56528020MHz string = "56 (5280/20 MHz)" + + // InterfaceRfChannelLabelNr58529080MHz captures enum value "58 (5290/80 MHz)" + InterfaceRfChannelLabelNr58529080MHz string = "58 (5290/80 MHz)" + + // InterfaceRfChannelLabelNr60530020MHz captures enum value "60 (5300/20 MHz)" + InterfaceRfChannelLabelNr60530020MHz string = "60 (5300/20 MHz)" + + // InterfaceRfChannelLabelNr62531040MHz captures enum value "62 (5310/40 MHz)" + InterfaceRfChannelLabelNr62531040MHz string = "62 (5310/40 MHz)" + + // InterfaceRfChannelLabelNr64532020MHz captures enum value "64 (5320/20 MHz)" + InterfaceRfChannelLabelNr64532020MHz string = "64 (5320/20 MHz)" + + // InterfaceRfChannelLabelNr100550020MHz captures enum value "100 (5500/20 MHz)" + InterfaceRfChannelLabelNr100550020MHz string = "100 (5500/20 MHz)" + + // InterfaceRfChannelLabelNr102551040MHz captures enum value "102 (5510/40 MHz)" + InterfaceRfChannelLabelNr102551040MHz string = "102 (5510/40 MHz)" + + // InterfaceRfChannelLabelNr104552020MHz captures enum value "104 (5520/20 MHz)" + InterfaceRfChannelLabelNr104552020MHz string = "104 (5520/20 MHz)" + + // InterfaceRfChannelLabelNr106553080MHz captures enum value "106 (5530/80 MHz)" + InterfaceRfChannelLabelNr106553080MHz string = "106 (5530/80 MHz)" + + // InterfaceRfChannelLabelNr108554020MHz captures enum value "108 (5540/20 MHz)" + InterfaceRfChannelLabelNr108554020MHz string = "108 (5540/20 MHz)" + + // InterfaceRfChannelLabelNr110555040MHz captures enum value "110 (5550/40 MHz)" + InterfaceRfChannelLabelNr110555040MHz string = "110 (5550/40 MHz)" + + // InterfaceRfChannelLabelNr112556020MHz captures enum value "112 (5560/20 MHz)" + InterfaceRfChannelLabelNr112556020MHz string = "112 (5560/20 MHz)" + + // InterfaceRfChannelLabelNr1145570160MHz captures enum value "114 (5570/160 MHz)" + InterfaceRfChannelLabelNr1145570160MHz string = "114 (5570/160 MHz)" + + // InterfaceRfChannelLabelNr116558020MHz captures enum value "116 (5580/20 MHz)" + InterfaceRfChannelLabelNr116558020MHz string = "116 (5580/20 MHz)" + + // InterfaceRfChannelLabelNr118559040MHz captures enum value "118 (5590/40 MHz)" + InterfaceRfChannelLabelNr118559040MHz string = "118 (5590/40 MHz)" + + // InterfaceRfChannelLabelNr120560020MHz captures enum value "120 (5600/20 MHz)" + InterfaceRfChannelLabelNr120560020MHz string = "120 (5600/20 MHz)" + + // InterfaceRfChannelLabelNr122561080MHz captures enum value "122 (5610/80 MHz)" + InterfaceRfChannelLabelNr122561080MHz string = "122 (5610/80 MHz)" + + // InterfaceRfChannelLabelNr124562020MHz captures enum value "124 (5620/20 MHz)" + InterfaceRfChannelLabelNr124562020MHz string = "124 (5620/20 MHz)" + + // InterfaceRfChannelLabelNr126563040MHz captures enum value "126 (5630/40 MHz)" + InterfaceRfChannelLabelNr126563040MHz string = "126 (5630/40 MHz)" + + // InterfaceRfChannelLabelNr128564020MHz captures enum value "128 (5640/20 MHz)" + InterfaceRfChannelLabelNr128564020MHz string = "128 (5640/20 MHz)" + + // InterfaceRfChannelLabelNr132566020MHz captures enum value "132 (5660/20 MHz)" + InterfaceRfChannelLabelNr132566020MHz string = "132 (5660/20 MHz)" + + // InterfaceRfChannelLabelNr134567040MHz captures enum value "134 (5670/40 MHz)" + InterfaceRfChannelLabelNr134567040MHz string = "134 (5670/40 MHz)" + + // InterfaceRfChannelLabelNr136568020MHz captures enum value "136 (5680/20 MHz)" + InterfaceRfChannelLabelNr136568020MHz string = "136 (5680/20 MHz)" + + // InterfaceRfChannelLabelNr138569080MHz captures enum value "138 (5690/80 MHz)" + InterfaceRfChannelLabelNr138569080MHz string = "138 (5690/80 MHz)" + + // InterfaceRfChannelLabelNr140570020MHz captures enum value "140 (5700/20 MHz)" + InterfaceRfChannelLabelNr140570020MHz string = "140 (5700/20 MHz)" + + // InterfaceRfChannelLabelNr142571040MHz captures enum value "142 (5710/40 MHz)" + InterfaceRfChannelLabelNr142571040MHz string = "142 (5710/40 MHz)" + + // InterfaceRfChannelLabelNr144572020MHz captures enum value "144 (5720/20 MHz)" + InterfaceRfChannelLabelNr144572020MHz string = "144 (5720/20 MHz)" + + // InterfaceRfChannelLabelNr149574520MHz captures enum value "149 (5745/20 MHz)" + InterfaceRfChannelLabelNr149574520MHz string = "149 (5745/20 MHz)" + + // InterfaceRfChannelLabelNr151575540MHz captures enum value "151 (5755/40 MHz)" + InterfaceRfChannelLabelNr151575540MHz string = "151 (5755/40 MHz)" + + // InterfaceRfChannelLabelNr153576520MHz captures enum value "153 (5765/20 MHz)" + InterfaceRfChannelLabelNr153576520MHz string = "153 (5765/20 MHz)" + + // InterfaceRfChannelLabelNr155577580MHz captures enum value "155 (5775/80 MHz)" + InterfaceRfChannelLabelNr155577580MHz string = "155 (5775/80 MHz)" + + // InterfaceRfChannelLabelNr157578520MHz captures enum value "157 (5785/20 MHz)" + InterfaceRfChannelLabelNr157578520MHz string = "157 (5785/20 MHz)" + + // InterfaceRfChannelLabelNr159579540MHz captures enum value "159 (5795/40 MHz)" + InterfaceRfChannelLabelNr159579540MHz string = "159 (5795/40 MHz)" + + // InterfaceRfChannelLabelNr161580520MHz captures enum value "161 (5805/20 MHz)" + InterfaceRfChannelLabelNr161580520MHz string = "161 (5805/20 MHz)" + + // InterfaceRfChannelLabelNr1635815160MHz captures enum value "163 (5815/160 MHz)" + InterfaceRfChannelLabelNr1635815160MHz string = "163 (5815/160 MHz)" + + // InterfaceRfChannelLabelNr165582520MHz captures enum value "165 (5825/20 MHz)" + InterfaceRfChannelLabelNr165582520MHz string = "165 (5825/20 MHz)" + + // InterfaceRfChannelLabelNr167583540MHz captures enum value "167 (5835/40 MHz)" + InterfaceRfChannelLabelNr167583540MHz string = "167 (5835/40 MHz)" + + // InterfaceRfChannelLabelNr169584520MHz captures enum value "169 (5845/20 MHz)" + InterfaceRfChannelLabelNr169584520MHz string = "169 (5845/20 MHz)" + + // InterfaceRfChannelLabelNr171585580MHz captures enum value "171 (5855/80 MHz)" + InterfaceRfChannelLabelNr171585580MHz string = "171 (5855/80 MHz)" + + // InterfaceRfChannelLabelNr173586520MHz captures enum value "173 (5865/20 MHz)" + InterfaceRfChannelLabelNr173586520MHz string = "173 (5865/20 MHz)" + + // InterfaceRfChannelLabelNr175587540MHz captures enum value "175 (5875/40 MHz)" + InterfaceRfChannelLabelNr175587540MHz string = "175 (5875/40 MHz)" + + // InterfaceRfChannelLabelNr177588520MHz captures enum value "177 (5885/20 MHz)" + InterfaceRfChannelLabelNr177588520MHz string = "177 (5885/20 MHz)" + + // InterfaceRfChannelLabelNr1595520MHz captures enum value "1 (5955/20 MHz)" + InterfaceRfChannelLabelNr1595520MHz string = "1 (5955/20 MHz)" + + // InterfaceRfChannelLabelNr3596540MHz captures enum value "3 (5965/40 MHz)" + InterfaceRfChannelLabelNr3596540MHz string = "3 (5965/40 MHz)" + + // InterfaceRfChannelLabelNr5597520MHz captures enum value "5 (5975/20 MHz)" + InterfaceRfChannelLabelNr5597520MHz string = "5 (5975/20 MHz)" + + // InterfaceRfChannelLabelNr7598580MHz captures enum value "7 (5985/80 MHz)" + InterfaceRfChannelLabelNr7598580MHz string = "7 (5985/80 MHz)" + + // InterfaceRfChannelLabelNr9599520MHz captures enum value "9 (5995/20 MHz)" + InterfaceRfChannelLabelNr9599520MHz string = "9 (5995/20 MHz)" + + // InterfaceRfChannelLabelNr11600540MHz captures enum value "11 (6005/40 MHz)" + InterfaceRfChannelLabelNr11600540MHz string = "11 (6005/40 MHz)" + + // InterfaceRfChannelLabelNr13601520MHz captures enum value "13 (6015/20 MHz)" + InterfaceRfChannelLabelNr13601520MHz string = "13 (6015/20 MHz)" + + // InterfaceRfChannelLabelNr156025160MHz captures enum value "15 (6025/160 MHz)" + InterfaceRfChannelLabelNr156025160MHz string = "15 (6025/160 MHz)" + + // InterfaceRfChannelLabelNr17603520MHz captures enum value "17 (6035/20 MHz)" + InterfaceRfChannelLabelNr17603520MHz string = "17 (6035/20 MHz)" + + // InterfaceRfChannelLabelNr19604540MHz captures enum value "19 (6045/40 MHz)" + InterfaceRfChannelLabelNr19604540MHz string = "19 (6045/40 MHz)" + + // InterfaceRfChannelLabelNr21605520MHz captures enum value "21 (6055/20 MHz)" + InterfaceRfChannelLabelNr21605520MHz string = "21 (6055/20 MHz)" + + // InterfaceRfChannelLabelNr23606580MHz captures enum value "23 (6065/80 MHz)" + InterfaceRfChannelLabelNr23606580MHz string = "23 (6065/80 MHz)" + + // InterfaceRfChannelLabelNr25607520MHz captures enum value "25 (6075/20 MHz)" + InterfaceRfChannelLabelNr25607520MHz string = "25 (6075/20 MHz)" + + // InterfaceRfChannelLabelNr27608540MHz captures enum value "27 (6085/40 MHz)" + InterfaceRfChannelLabelNr27608540MHz string = "27 (6085/40 MHz)" + + // InterfaceRfChannelLabelNr29609520MHz captures enum value "29 (6095/20 MHz)" + InterfaceRfChannelLabelNr29609520MHz string = "29 (6095/20 MHz)" + + // InterfaceRfChannelLabelNr316105320MHz captures enum value "31 (6105/320 MHz)" + InterfaceRfChannelLabelNr316105320MHz string = "31 (6105/320 MHz)" + + // InterfaceRfChannelLabelNr33611520MHz captures enum value "33 (6115/20 MHz)" + InterfaceRfChannelLabelNr33611520MHz string = "33 (6115/20 MHz)" + + // InterfaceRfChannelLabelNr35612540MHz captures enum value "35 (6125/40 MHz)" + InterfaceRfChannelLabelNr35612540MHz string = "35 (6125/40 MHz)" + + // InterfaceRfChannelLabelNr37613520MHz captures enum value "37 (6135/20 MHz)" + InterfaceRfChannelLabelNr37613520MHz string = "37 (6135/20 MHz)" + + // InterfaceRfChannelLabelNr39614580MHz captures enum value "39 (6145/80 MHz)" + InterfaceRfChannelLabelNr39614580MHz string = "39 (6145/80 MHz)" + + // InterfaceRfChannelLabelNr41615520MHz captures enum value "41 (6155/20 MHz)" + InterfaceRfChannelLabelNr41615520MHz string = "41 (6155/20 MHz)" + + // InterfaceRfChannelLabelNr43616540MHz captures enum value "43 (6165/40 MHz)" + InterfaceRfChannelLabelNr43616540MHz string = "43 (6165/40 MHz)" + + // InterfaceRfChannelLabelNr45617520MHz captures enum value "45 (6175/20 MHz)" + InterfaceRfChannelLabelNr45617520MHz string = "45 (6175/20 MHz)" + + // InterfaceRfChannelLabelNr476185160MHz captures enum value "47 (6185/160 MHz)" + InterfaceRfChannelLabelNr476185160MHz string = "47 (6185/160 MHz)" + + // InterfaceRfChannelLabelNr49619520MHz captures enum value "49 (6195/20 MHz)" + InterfaceRfChannelLabelNr49619520MHz string = "49 (6195/20 MHz)" + + // InterfaceRfChannelLabelNr51620540MHz captures enum value "51 (6205/40 MHz)" + InterfaceRfChannelLabelNr51620540MHz string = "51 (6205/40 MHz)" + + // InterfaceRfChannelLabelNr53621520MHz captures enum value "53 (6215/20 MHz)" + InterfaceRfChannelLabelNr53621520MHz string = "53 (6215/20 MHz)" + + // InterfaceRfChannelLabelNr55622580MHz captures enum value "55 (6225/80 MHz)" + InterfaceRfChannelLabelNr55622580MHz string = "55 (6225/80 MHz)" + + // InterfaceRfChannelLabelNr57623520MHz captures enum value "57 (6235/20 MHz)" + InterfaceRfChannelLabelNr57623520MHz string = "57 (6235/20 MHz)" + + // InterfaceRfChannelLabelNr59624540MHz captures enum value "59 (6245/40 MHz)" + InterfaceRfChannelLabelNr59624540MHz string = "59 (6245/40 MHz)" + + // InterfaceRfChannelLabelNr61625520MHz captures enum value "61 (6255/20 MHz)" + InterfaceRfChannelLabelNr61625520MHz string = "61 (6255/20 MHz)" + + // InterfaceRfChannelLabelNr65627520MHz captures enum value "65 (6275/20 MHz)" + InterfaceRfChannelLabelNr65627520MHz string = "65 (6275/20 MHz)" + + // InterfaceRfChannelLabelNr67628540MHz captures enum value "67 (6285/40 MHz)" + InterfaceRfChannelLabelNr67628540MHz string = "67 (6285/40 MHz)" + + // InterfaceRfChannelLabelNr69629520MHz captures enum value "69 (6295/20 MHz)" + InterfaceRfChannelLabelNr69629520MHz string = "69 (6295/20 MHz)" + + // InterfaceRfChannelLabelNr71630580MHz captures enum value "71 (6305/80 MHz)" + InterfaceRfChannelLabelNr71630580MHz string = "71 (6305/80 MHz)" + + // InterfaceRfChannelLabelNr73631520MHz captures enum value "73 (6315/20 MHz)" + InterfaceRfChannelLabelNr73631520MHz string = "73 (6315/20 MHz)" + + // InterfaceRfChannelLabelNr75632540MHz captures enum value "75 (6325/40 MHz)" + InterfaceRfChannelLabelNr75632540MHz string = "75 (6325/40 MHz)" + + // InterfaceRfChannelLabelNr77633520MHz captures enum value "77 (6335/20 MHz)" + InterfaceRfChannelLabelNr77633520MHz string = "77 (6335/20 MHz)" + + // InterfaceRfChannelLabelNr796345160MHz captures enum value "79 (6345/160 MHz)" + InterfaceRfChannelLabelNr796345160MHz string = "79 (6345/160 MHz)" + + // InterfaceRfChannelLabelNr81635520MHz captures enum value "81 (6355/20 MHz)" + InterfaceRfChannelLabelNr81635520MHz string = "81 (6355/20 MHz)" + + // InterfaceRfChannelLabelNr83636540MHz captures enum value "83 (6365/40 MHz)" + InterfaceRfChannelLabelNr83636540MHz string = "83 (6365/40 MHz)" + + // InterfaceRfChannelLabelNr85637520MHz captures enum value "85 (6375/20 MHz)" + InterfaceRfChannelLabelNr85637520MHz string = "85 (6375/20 MHz)" + + // InterfaceRfChannelLabelNr87638580MHz captures enum value "87 (6385/80 MHz)" + InterfaceRfChannelLabelNr87638580MHz string = "87 (6385/80 MHz)" + + // InterfaceRfChannelLabelNr89639520MHz captures enum value "89 (6395/20 MHz)" + InterfaceRfChannelLabelNr89639520MHz string = "89 (6395/20 MHz)" + + // InterfaceRfChannelLabelNr91640540MHz captures enum value "91 (6405/40 MHz)" + InterfaceRfChannelLabelNr91640540MHz string = "91 (6405/40 MHz)" + + // InterfaceRfChannelLabelNr93641520MHz captures enum value "93 (6415/20 MHz)" + InterfaceRfChannelLabelNr93641520MHz string = "93 (6415/20 MHz)" + + // InterfaceRfChannelLabelNr956425320MHz captures enum value "95 (6425/320 MHz)" + InterfaceRfChannelLabelNr956425320MHz string = "95 (6425/320 MHz)" + + // InterfaceRfChannelLabelNr97643520MHz captures enum value "97 (6435/20 MHz)" + InterfaceRfChannelLabelNr97643520MHz string = "97 (6435/20 MHz)" + + // InterfaceRfChannelLabelNr99644540MHz captures enum value "99 (6445/40 MHz)" + InterfaceRfChannelLabelNr99644540MHz string = "99 (6445/40 MHz)" + + // InterfaceRfChannelLabelNr101645520MHz captures enum value "101 (6455/20 MHz)" + InterfaceRfChannelLabelNr101645520MHz string = "101 (6455/20 MHz)" + + // InterfaceRfChannelLabelNr103646580MHz captures enum value "103 (6465/80 MHz)" + InterfaceRfChannelLabelNr103646580MHz string = "103 (6465/80 MHz)" + + // InterfaceRfChannelLabelNr105647520MHz captures enum value "105 (6475/20 MHz)" + InterfaceRfChannelLabelNr105647520MHz string = "105 (6475/20 MHz)" + + // InterfaceRfChannelLabelNr107648540MHz captures enum value "107 (6485/40 MHz)" + InterfaceRfChannelLabelNr107648540MHz string = "107 (6485/40 MHz)" + + // InterfaceRfChannelLabelNr109649520MHz captures enum value "109 (6495/20 MHz)" + InterfaceRfChannelLabelNr109649520MHz string = "109 (6495/20 MHz)" + + // InterfaceRfChannelLabelNr1116505160MHz captures enum value "111 (6505/160 MHz)" + InterfaceRfChannelLabelNr1116505160MHz string = "111 (6505/160 MHz)" + + // InterfaceRfChannelLabelNr113651520MHz captures enum value "113 (6515/20 MHz)" + InterfaceRfChannelLabelNr113651520MHz string = "113 (6515/20 MHz)" + + // InterfaceRfChannelLabelNr115652540MHz captures enum value "115 (6525/40 MHz)" + InterfaceRfChannelLabelNr115652540MHz string = "115 (6525/40 MHz)" + + // InterfaceRfChannelLabelNr117653520MHz captures enum value "117 (6535/20 MHz)" + InterfaceRfChannelLabelNr117653520MHz string = "117 (6535/20 MHz)" + + // InterfaceRfChannelLabelNr119654580MHz captures enum value "119 (6545/80 MHz)" + InterfaceRfChannelLabelNr119654580MHz string = "119 (6545/80 MHz)" + + // InterfaceRfChannelLabelNr121655520MHz captures enum value "121 (6555/20 MHz)" + InterfaceRfChannelLabelNr121655520MHz string = "121 (6555/20 MHz)" + + // InterfaceRfChannelLabelNr123656540MHz captures enum value "123 (6565/40 MHz)" + InterfaceRfChannelLabelNr123656540MHz string = "123 (6565/40 MHz)" + + // InterfaceRfChannelLabelNr125657520MHz captures enum value "125 (6575/20 MHz)" + InterfaceRfChannelLabelNr125657520MHz string = "125 (6575/20 MHz)" + + // InterfaceRfChannelLabelNr129659520MHz captures enum value "129 (6595/20 MHz)" + InterfaceRfChannelLabelNr129659520MHz string = "129 (6595/20 MHz)" + + // InterfaceRfChannelLabelNr131660540MHz captures enum value "131 (6605/40 MHz)" + InterfaceRfChannelLabelNr131660540MHz string = "131 (6605/40 MHz)" + + // InterfaceRfChannelLabelNr133661520MHz captures enum value "133 (6615/20 MHz)" + InterfaceRfChannelLabelNr133661520MHz string = "133 (6615/20 MHz)" + + // InterfaceRfChannelLabelNr135662580MHz captures enum value "135 (6625/80 MHz)" + InterfaceRfChannelLabelNr135662580MHz string = "135 (6625/80 MHz)" + + // InterfaceRfChannelLabelNr137663520MHz captures enum value "137 (6635/20 MHz)" + InterfaceRfChannelLabelNr137663520MHz string = "137 (6635/20 MHz)" + + // InterfaceRfChannelLabelNr139664540MHz captures enum value "139 (6645/40 MHz)" + InterfaceRfChannelLabelNr139664540MHz string = "139 (6645/40 MHz)" + + // InterfaceRfChannelLabelNr141665520MHz captures enum value "141 (6655/20 MHz)" + InterfaceRfChannelLabelNr141665520MHz string = "141 (6655/20 MHz)" + + // InterfaceRfChannelLabelNr1436665160MHz captures enum value "143 (6665/160 MHz)" + InterfaceRfChannelLabelNr1436665160MHz string = "143 (6665/160 MHz)" + + // InterfaceRfChannelLabelNr145667520MHz captures enum value "145 (6675/20 MHz)" + InterfaceRfChannelLabelNr145667520MHz string = "145 (6675/20 MHz)" + + // InterfaceRfChannelLabelNr147668540MHz captures enum value "147 (6685/40 MHz)" + InterfaceRfChannelLabelNr147668540MHz string = "147 (6685/40 MHz)" + + // InterfaceRfChannelLabelNr149669520MHz captures enum value "149 (6695/20 MHz)" + InterfaceRfChannelLabelNr149669520MHz string = "149 (6695/20 MHz)" + + // InterfaceRfChannelLabelNr151670580MHz captures enum value "151 (6705/80 MHz)" + InterfaceRfChannelLabelNr151670580MHz string = "151 (6705/80 MHz)" + + // InterfaceRfChannelLabelNr153671520MHz captures enum value "153 (6715/20 MHz)" + InterfaceRfChannelLabelNr153671520MHz string = "153 (6715/20 MHz)" + + // InterfaceRfChannelLabelNr155672540MHz captures enum value "155 (6725/40 MHz)" + InterfaceRfChannelLabelNr155672540MHz string = "155 (6725/40 MHz)" + + // InterfaceRfChannelLabelNr157673520MHz captures enum value "157 (6735/20 MHz)" + InterfaceRfChannelLabelNr157673520MHz string = "157 (6735/20 MHz)" + + // InterfaceRfChannelLabelNr1596745320MHz captures enum value "159 (6745/320 MHz)" + InterfaceRfChannelLabelNr1596745320MHz string = "159 (6745/320 MHz)" + + // InterfaceRfChannelLabelNr161675520MHz captures enum value "161 (6755/20 MHz)" + InterfaceRfChannelLabelNr161675520MHz string = "161 (6755/20 MHz)" + + // InterfaceRfChannelLabelNr163676540MHz captures enum value "163 (6765/40 MHz)" + InterfaceRfChannelLabelNr163676540MHz string = "163 (6765/40 MHz)" + + // InterfaceRfChannelLabelNr165677520MHz captures enum value "165 (6775/20 MHz)" + InterfaceRfChannelLabelNr165677520MHz string = "165 (6775/20 MHz)" + + // InterfaceRfChannelLabelNr167678580MHz captures enum value "167 (6785/80 MHz)" + InterfaceRfChannelLabelNr167678580MHz string = "167 (6785/80 MHz)" + + // InterfaceRfChannelLabelNr169679520MHz captures enum value "169 (6795/20 MHz)" + InterfaceRfChannelLabelNr169679520MHz string = "169 (6795/20 MHz)" + + // InterfaceRfChannelLabelNr171680540MHz captures enum value "171 (6805/40 MHz)" + InterfaceRfChannelLabelNr171680540MHz string = "171 (6805/40 MHz)" + + // InterfaceRfChannelLabelNr173681520MHz captures enum value "173 (6815/20 MHz)" + InterfaceRfChannelLabelNr173681520MHz string = "173 (6815/20 MHz)" + + // InterfaceRfChannelLabelNr1756825160MHz captures enum value "175 (6825/160 MHz)" + InterfaceRfChannelLabelNr1756825160MHz string = "175 (6825/160 MHz)" + + // InterfaceRfChannelLabelNr177683520MHz captures enum value "177 (6835/20 MHz)" + InterfaceRfChannelLabelNr177683520MHz string = "177 (6835/20 MHz)" + + // InterfaceRfChannelLabelNr179684540MHz captures enum value "179 (6845/40 MHz)" + InterfaceRfChannelLabelNr179684540MHz string = "179 (6845/40 MHz)" + + // InterfaceRfChannelLabelNr181685520MHz captures enum value "181 (6855/20 MHz)" + InterfaceRfChannelLabelNr181685520MHz string = "181 (6855/20 MHz)" + + // InterfaceRfChannelLabelNr183686580MHz captures enum value "183 (6865/80 MHz)" + InterfaceRfChannelLabelNr183686580MHz string = "183 (6865/80 MHz)" + + // InterfaceRfChannelLabelNr185687520MHz captures enum value "185 (6875/20 MHz)" + InterfaceRfChannelLabelNr185687520MHz string = "185 (6875/20 MHz)" + + // InterfaceRfChannelLabelNr187688540MHz captures enum value "187 (6885/40 MHz)" + InterfaceRfChannelLabelNr187688540MHz string = "187 (6885/40 MHz)" + + // InterfaceRfChannelLabelNr189689520MHz captures enum value "189 (6895/20 MHz)" + InterfaceRfChannelLabelNr189689520MHz string = "189 (6895/20 MHz)" + + // InterfaceRfChannelLabelNr193691520MHz captures enum value "193 (6915/20 MHz)" + InterfaceRfChannelLabelNr193691520MHz string = "193 (6915/20 MHz)" + + // InterfaceRfChannelLabelNr195692540MHz captures enum value "195 (6925/40 MHz)" + InterfaceRfChannelLabelNr195692540MHz string = "195 (6925/40 MHz)" + + // InterfaceRfChannelLabelNr197693520MHz captures enum value "197 (6935/20 MHz)" + InterfaceRfChannelLabelNr197693520MHz string = "197 (6935/20 MHz)" + + // InterfaceRfChannelLabelNr199694580MHz captures enum value "199 (6945/80 MHz)" + InterfaceRfChannelLabelNr199694580MHz string = "199 (6945/80 MHz)" + + // InterfaceRfChannelLabelNr201695520MHz captures enum value "201 (6955/20 MHz)" + InterfaceRfChannelLabelNr201695520MHz string = "201 (6955/20 MHz)" + + // InterfaceRfChannelLabelNr203696540MHz captures enum value "203 (6965/40 MHz)" + InterfaceRfChannelLabelNr203696540MHz string = "203 (6965/40 MHz)" + + // InterfaceRfChannelLabelNr205697520MHz captures enum value "205 (6975/20 MHz)" + InterfaceRfChannelLabelNr205697520MHz string = "205 (6975/20 MHz)" + + // InterfaceRfChannelLabelNr2076985160MHz captures enum value "207 (6985/160 MHz)" + InterfaceRfChannelLabelNr2076985160MHz string = "207 (6985/160 MHz)" + + // InterfaceRfChannelLabelNr209699520MHz captures enum value "209 (6995/20 MHz)" + InterfaceRfChannelLabelNr209699520MHz string = "209 (6995/20 MHz)" + + // InterfaceRfChannelLabelNr211700540MHz captures enum value "211 (7005/40 MHz)" + InterfaceRfChannelLabelNr211700540MHz string = "211 (7005/40 MHz)" + + // InterfaceRfChannelLabelNr213701520MHz captures enum value "213 (7015/20 MHz)" + InterfaceRfChannelLabelNr213701520MHz string = "213 (7015/20 MHz)" + + // InterfaceRfChannelLabelNr215702580MHz captures enum value "215 (7025/80 MHz)" + InterfaceRfChannelLabelNr215702580MHz string = "215 (7025/80 MHz)" + + // InterfaceRfChannelLabelNr217703520MHz captures enum value "217 (7035/20 MHz)" + InterfaceRfChannelLabelNr217703520MHz string = "217 (7035/20 MHz)" + + // InterfaceRfChannelLabelNr219704540MHz captures enum value "219 (7045/40 MHz)" + InterfaceRfChannelLabelNr219704540MHz string = "219 (7045/40 MHz)" + + // InterfaceRfChannelLabelNr221705520MHz captures enum value "221 (7055/20 MHz)" + InterfaceRfChannelLabelNr221705520MHz string = "221 (7055/20 MHz)" + + // InterfaceRfChannelLabelNr225707520MHz captures enum value "225 (7075/20 MHz)" + InterfaceRfChannelLabelNr225707520MHz string = "225 (7075/20 MHz)" + + // InterfaceRfChannelLabelNr227708540MHz captures enum value "227 (7085/40 MHz)" + InterfaceRfChannelLabelNr227708540MHz string = "227 (7085/40 MHz)" + + // InterfaceRfChannelLabelNr229709520MHz captures enum value "229 (7095/20 MHz)" + InterfaceRfChannelLabelNr229709520MHz string = "229 (7095/20 MHz)" + + // InterfaceRfChannelLabelNr233711520MHz captures enum value "233 (7115/20 MHz)" + InterfaceRfChannelLabelNr233711520MHz string = "233 (7115/20 MHz)" + + // InterfaceRfChannelLabelNr158Dot322Dot16GHz captures enum value "1 (58.32/2.16 GHz)" + InterfaceRfChannelLabelNr158Dot322Dot16GHz string = "1 (58.32/2.16 GHz)" + + // InterfaceRfChannelLabelNr260Dot482Dot16GHz captures enum value "2 (60.48/2.16 GHz)" + InterfaceRfChannelLabelNr260Dot482Dot16GHz string = "2 (60.48/2.16 GHz)" + + // InterfaceRfChannelLabelNr362Dot642Dot16GHz captures enum value "3 (62.64/2.16 GHz)" + InterfaceRfChannelLabelNr362Dot642Dot16GHz string = "3 (62.64/2.16 GHz)" + + // InterfaceRfChannelLabelNr464Dot802Dot16GHz captures enum value "4 (64.80/2.16 GHz)" + InterfaceRfChannelLabelNr464Dot802Dot16GHz string = "4 (64.80/2.16 GHz)" + + // InterfaceRfChannelLabelNr566Dot962Dot16GHz captures enum value "5 (66.96/2.16 GHz)" + InterfaceRfChannelLabelNr566Dot962Dot16GHz string = "5 (66.96/2.16 GHz)" + + // InterfaceRfChannelLabelNr669Dot122Dot16GHz captures enum value "6 (69.12/2.16 GHz)" + InterfaceRfChannelLabelNr669Dot122Dot16GHz string = "6 (69.12/2.16 GHz)" + + // InterfaceRfChannelLabelNr959Dot404Dot32GHz captures enum value "9 (59.40/4.32 GHz)" + InterfaceRfChannelLabelNr959Dot404Dot32GHz string = "9 (59.40/4.32 GHz)" + + // InterfaceRfChannelLabelNr1061Dot564Dot32GHz captures enum value "10 (61.56/4.32 GHz)" + InterfaceRfChannelLabelNr1061Dot564Dot32GHz string = "10 (61.56/4.32 GHz)" + + // InterfaceRfChannelLabelNr1163Dot724Dot32GHz captures enum value "11 (63.72/4.32 GHz)" + InterfaceRfChannelLabelNr1163Dot724Dot32GHz string = "11 (63.72/4.32 GHz)" + + // InterfaceRfChannelLabelNr1265Dot884Dot32GHz captures enum value "12 (65.88/4.32 GHz)" + InterfaceRfChannelLabelNr1265Dot884Dot32GHz string = "12 (65.88/4.32 GHz)" + + // InterfaceRfChannelLabelNr1368Dot044Dot32GHz captures enum value "13 (68.04/4.32 GHz)" + InterfaceRfChannelLabelNr1368Dot044Dot32GHz string = "13 (68.04/4.32 GHz)" + + // InterfaceRfChannelLabelNr1760Dot486Dot48GHz captures enum value "17 (60.48/6.48 GHz)" + InterfaceRfChannelLabelNr1760Dot486Dot48GHz string = "17 (60.48/6.48 GHz)" + + // InterfaceRfChannelLabelNr1862Dot646Dot48GHz captures enum value "18 (62.64/6.48 GHz)" + InterfaceRfChannelLabelNr1862Dot646Dot48GHz string = "18 (62.64/6.48 GHz)" + + // InterfaceRfChannelLabelNr1964Dot806Dot48GHz captures enum value "19 (64.80/6.48 GHz)" + InterfaceRfChannelLabelNr1964Dot806Dot48GHz string = "19 (64.80/6.48 GHz)" + + // InterfaceRfChannelLabelNr2066Dot966Dot48GHz captures enum value "20 (66.96/6.48 GHz)" + InterfaceRfChannelLabelNr2066Dot966Dot48GHz string = "20 (66.96/6.48 GHz)" + + // InterfaceRfChannelLabelNr2561Dot568Dot64GHz captures enum value "25 (61.56/8.64 GHz)" + InterfaceRfChannelLabelNr2561Dot568Dot64GHz string = "25 (61.56/8.64 GHz)" + + // InterfaceRfChannelLabelNr2663Dot728Dot64GHz captures enum value "26 (63.72/8.64 GHz)" + InterfaceRfChannelLabelNr2663Dot728Dot64GHz string = "26 (63.72/8.64 GHz)" + + // InterfaceRfChannelLabelNr2765Dot888Dot64GHz captures enum value "27 (65.88/8.64 GHz)" + InterfaceRfChannelLabelNr2765Dot888Dot64GHz string = "27 (65.88/8.64 GHz)" +) + +// prop value enum +func (m *InterfaceRfChannel) validateLabelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, interfaceRfChannelTypeLabelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *InterfaceRfChannel) validateLabel(formats strfmt.Registry) error { + + if err := validate.Required("rf_channel"+"."+"label", "body", m.Label); err != nil { + return err + } + + // value enum + if err := m.validateLabelEnum("rf_channel"+"."+"label", "body", *m.Label); err != nil { + return err + } + + return nil +} + +var interfaceRfChannelTypeValuePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["2.4g-1-2412-22","2.4g-2-2417-22","2.4g-3-2422-22","2.4g-4-2427-22","2.4g-5-2432-22","2.4g-6-2437-22","2.4g-7-2442-22","2.4g-8-2447-22","2.4g-9-2452-22","2.4g-10-2457-22","2.4g-11-2462-22","2.4g-12-2467-22","2.4g-13-2472-22","5g-32-5160-20","5g-34-5170-40","5g-36-5180-20","5g-38-5190-40","5g-40-5200-20","5g-42-5210-80","5g-44-5220-20","5g-46-5230-40","5g-48-5240-20","5g-50-5250-160","5g-52-5260-20","5g-54-5270-40","5g-56-5280-20","5g-58-5290-80","5g-60-5300-20","5g-62-5310-40","5g-64-5320-20","5g-100-5500-20","5g-102-5510-40","5g-104-5520-20","5g-106-5530-80","5g-108-5540-20","5g-110-5550-40","5g-112-5560-20","5g-114-5570-160","5g-116-5580-20","5g-118-5590-40","5g-120-5600-20","5g-122-5610-80","5g-124-5620-20","5g-126-5630-40","5g-128-5640-20","5g-132-5660-20","5g-134-5670-40","5g-136-5680-20","5g-138-5690-80","5g-140-5700-20","5g-142-5710-40","5g-144-5720-20","5g-149-5745-20","5g-151-5755-40","5g-153-5765-20","5g-155-5775-80","5g-157-5785-20","5g-159-5795-40","5g-161-5805-20","5g-163-5815-160","5g-165-5825-20","5g-167-5835-40","5g-169-5845-20","5g-171-5855-80","5g-173-5865-20","5g-175-5875-40","5g-177-5885-20","6g-1-5955-20","6g-3-5965-40","6g-5-5975-20","6g-7-5985-80","6g-9-5995-20","6g-11-6005-40","6g-13-6015-20","6g-15-6025-160","6g-17-6035-20","6g-19-6045-40","6g-21-6055-20","6g-23-6065-80","6g-25-6075-20","6g-27-6085-40","6g-29-6095-20","6g-31-6105-320","6g-33-6115-20","6g-35-6125-40","6g-37-6135-20","6g-39-6145-80","6g-41-6155-20","6g-43-6165-40","6g-45-6175-20","6g-47-6185-160","6g-49-6195-20","6g-51-6205-40","6g-53-6215-20","6g-55-6225-80","6g-57-6235-20","6g-59-6245-40","6g-61-6255-20","6g-65-6275-20","6g-67-6285-40","6g-69-6295-20","6g-71-6305-80","6g-73-6315-20","6g-75-6325-40","6g-77-6335-20","6g-79-6345-160","6g-81-6355-20","6g-83-6365-40","6g-85-6375-20","6g-87-6385-80","6g-89-6395-20","6g-91-6405-40","6g-93-6415-20","6g-95-6425-320","6g-97-6435-20","6g-99-6445-40","6g-101-6455-20","6g-103-6465-80","6g-105-6475-20","6g-107-6485-40","6g-109-6495-20","6g-111-6505-160","6g-113-6515-20","6g-115-6525-40","6g-117-6535-20","6g-119-6545-80","6g-121-6555-20","6g-123-6565-40","6g-125-6575-20","6g-129-6595-20","6g-131-6605-40","6g-133-6615-20","6g-135-6625-80","6g-137-6635-20","6g-139-6645-40","6g-141-6655-20","6g-143-6665-160","6g-145-6675-20","6g-147-6685-40","6g-149-6695-20","6g-151-6705-80","6g-153-6715-20","6g-155-6725-40","6g-157-6735-20","6g-159-6745-320","6g-161-6755-20","6g-163-6765-40","6g-165-6775-20","6g-167-6785-80","6g-169-6795-20","6g-171-6805-40","6g-173-6815-20","6g-175-6825-160","6g-177-6835-20","6g-179-6845-40","6g-181-6855-20","6g-183-6865-80","6g-185-6875-20","6g-187-6885-40","6g-189-6895-20","6g-193-6915-20","6g-195-6925-40","6g-197-6935-20","6g-199-6945-80","6g-201-6955-20","6g-203-6965-40","6g-205-6975-20","6g-207-6985-160","6g-209-6995-20","6g-211-7005-40","6g-213-7015-20","6g-215-7025-80","6g-217-7035-20","6g-219-7045-40","6g-221-7055-20","6g-225-7075-20","6g-227-7085-40","6g-229-7095-20","6g-233-7115-20","60g-1-58320-2160","60g-2-60480-2160","60g-3-62640-2160","60g-4-64800-2160","60g-5-66960-2160","60g-6-69120-2160","60g-9-59400-4320","60g-10-61560-4320","60g-11-63720-4320","60g-12-65880-4320","60g-13-68040-4320","60g-17-60480-6480","60g-18-62640-6480","60g-19-64800-6480","60g-20-66960-6480","60g-25-61560-6480","60g-26-63720-6480","60g-27-65880-6480"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + interfaceRfChannelTypeValuePropEnum = append(interfaceRfChannelTypeValuePropEnum, v) + } +} + +const ( + + // InterfaceRfChannelValueNr2Dot4gDash1Dash2412Dash22 captures enum value "2.4g-1-2412-22" + InterfaceRfChannelValueNr2Dot4gDash1Dash2412Dash22 string = "2.4g-1-2412-22" + + // InterfaceRfChannelValueNr2Dot4gDash2Dash2417Dash22 captures enum value "2.4g-2-2417-22" + InterfaceRfChannelValueNr2Dot4gDash2Dash2417Dash22 string = "2.4g-2-2417-22" + + // InterfaceRfChannelValueNr2Dot4gDash3Dash2422Dash22 captures enum value "2.4g-3-2422-22" + InterfaceRfChannelValueNr2Dot4gDash3Dash2422Dash22 string = "2.4g-3-2422-22" + + // InterfaceRfChannelValueNr2Dot4gDash4Dash2427Dash22 captures enum value "2.4g-4-2427-22" + InterfaceRfChannelValueNr2Dot4gDash4Dash2427Dash22 string = "2.4g-4-2427-22" + + // InterfaceRfChannelValueNr2Dot4gDash5Dash2432Dash22 captures enum value "2.4g-5-2432-22" + InterfaceRfChannelValueNr2Dot4gDash5Dash2432Dash22 string = "2.4g-5-2432-22" + + // InterfaceRfChannelValueNr2Dot4gDash6Dash2437Dash22 captures enum value "2.4g-6-2437-22" + InterfaceRfChannelValueNr2Dot4gDash6Dash2437Dash22 string = "2.4g-6-2437-22" + + // InterfaceRfChannelValueNr2Dot4gDash7Dash2442Dash22 captures enum value "2.4g-7-2442-22" + InterfaceRfChannelValueNr2Dot4gDash7Dash2442Dash22 string = "2.4g-7-2442-22" + + // InterfaceRfChannelValueNr2Dot4gDash8Dash2447Dash22 captures enum value "2.4g-8-2447-22" + InterfaceRfChannelValueNr2Dot4gDash8Dash2447Dash22 string = "2.4g-8-2447-22" + + // InterfaceRfChannelValueNr2Dot4gDash9Dash2452Dash22 captures enum value "2.4g-9-2452-22" + InterfaceRfChannelValueNr2Dot4gDash9Dash2452Dash22 string = "2.4g-9-2452-22" + + // InterfaceRfChannelValueNr2Dot4gDash10Dash2457Dash22 captures enum value "2.4g-10-2457-22" + InterfaceRfChannelValueNr2Dot4gDash10Dash2457Dash22 string = "2.4g-10-2457-22" + + // InterfaceRfChannelValueNr2Dot4gDash11Dash2462Dash22 captures enum value "2.4g-11-2462-22" + InterfaceRfChannelValueNr2Dot4gDash11Dash2462Dash22 string = "2.4g-11-2462-22" + + // InterfaceRfChannelValueNr2Dot4gDash12Dash2467Dash22 captures enum value "2.4g-12-2467-22" + InterfaceRfChannelValueNr2Dot4gDash12Dash2467Dash22 string = "2.4g-12-2467-22" + + // InterfaceRfChannelValueNr2Dot4gDash13Dash2472Dash22 captures enum value "2.4g-13-2472-22" + InterfaceRfChannelValueNr2Dot4gDash13Dash2472Dash22 string = "2.4g-13-2472-22" + + // InterfaceRfChannelValueNr5gDash32Dash5160Dash20 captures enum value "5g-32-5160-20" + InterfaceRfChannelValueNr5gDash32Dash5160Dash20 string = "5g-32-5160-20" + + // InterfaceRfChannelValueNr5gDash34Dash5170Dash40 captures enum value "5g-34-5170-40" + InterfaceRfChannelValueNr5gDash34Dash5170Dash40 string = "5g-34-5170-40" + + // InterfaceRfChannelValueNr5gDash36Dash5180Dash20 captures enum value "5g-36-5180-20" + InterfaceRfChannelValueNr5gDash36Dash5180Dash20 string = "5g-36-5180-20" + + // InterfaceRfChannelValueNr5gDash38Dash5190Dash40 captures enum value "5g-38-5190-40" + InterfaceRfChannelValueNr5gDash38Dash5190Dash40 string = "5g-38-5190-40" + + // InterfaceRfChannelValueNr5gDash40Dash5200Dash20 captures enum value "5g-40-5200-20" + InterfaceRfChannelValueNr5gDash40Dash5200Dash20 string = "5g-40-5200-20" + + // InterfaceRfChannelValueNr5gDash42Dash5210Dash80 captures enum value "5g-42-5210-80" + InterfaceRfChannelValueNr5gDash42Dash5210Dash80 string = "5g-42-5210-80" + + // InterfaceRfChannelValueNr5gDash44Dash5220Dash20 captures enum value "5g-44-5220-20" + InterfaceRfChannelValueNr5gDash44Dash5220Dash20 string = "5g-44-5220-20" + + // InterfaceRfChannelValueNr5gDash46Dash5230Dash40 captures enum value "5g-46-5230-40" + InterfaceRfChannelValueNr5gDash46Dash5230Dash40 string = "5g-46-5230-40" + + // InterfaceRfChannelValueNr5gDash48Dash5240Dash20 captures enum value "5g-48-5240-20" + InterfaceRfChannelValueNr5gDash48Dash5240Dash20 string = "5g-48-5240-20" + + // InterfaceRfChannelValueNr5gDash50Dash5250Dash160 captures enum value "5g-50-5250-160" + InterfaceRfChannelValueNr5gDash50Dash5250Dash160 string = "5g-50-5250-160" + + // InterfaceRfChannelValueNr5gDash52Dash5260Dash20 captures enum value "5g-52-5260-20" + InterfaceRfChannelValueNr5gDash52Dash5260Dash20 string = "5g-52-5260-20" + + // InterfaceRfChannelValueNr5gDash54Dash5270Dash40 captures enum value "5g-54-5270-40" + InterfaceRfChannelValueNr5gDash54Dash5270Dash40 string = "5g-54-5270-40" + + // InterfaceRfChannelValueNr5gDash56Dash5280Dash20 captures enum value "5g-56-5280-20" + InterfaceRfChannelValueNr5gDash56Dash5280Dash20 string = "5g-56-5280-20" + + // InterfaceRfChannelValueNr5gDash58Dash5290Dash80 captures enum value "5g-58-5290-80" + InterfaceRfChannelValueNr5gDash58Dash5290Dash80 string = "5g-58-5290-80" + + // InterfaceRfChannelValueNr5gDash60Dash5300Dash20 captures enum value "5g-60-5300-20" + InterfaceRfChannelValueNr5gDash60Dash5300Dash20 string = "5g-60-5300-20" + + // InterfaceRfChannelValueNr5gDash62Dash5310Dash40 captures enum value "5g-62-5310-40" + InterfaceRfChannelValueNr5gDash62Dash5310Dash40 string = "5g-62-5310-40" + + // InterfaceRfChannelValueNr5gDash64Dash5320Dash20 captures enum value "5g-64-5320-20" + InterfaceRfChannelValueNr5gDash64Dash5320Dash20 string = "5g-64-5320-20" + + // InterfaceRfChannelValueNr5gDash100Dash5500Dash20 captures enum value "5g-100-5500-20" + InterfaceRfChannelValueNr5gDash100Dash5500Dash20 string = "5g-100-5500-20" + + // InterfaceRfChannelValueNr5gDash102Dash5510Dash40 captures enum value "5g-102-5510-40" + InterfaceRfChannelValueNr5gDash102Dash5510Dash40 string = "5g-102-5510-40" + + // InterfaceRfChannelValueNr5gDash104Dash5520Dash20 captures enum value "5g-104-5520-20" + InterfaceRfChannelValueNr5gDash104Dash5520Dash20 string = "5g-104-5520-20" + + // InterfaceRfChannelValueNr5gDash106Dash5530Dash80 captures enum value "5g-106-5530-80" + InterfaceRfChannelValueNr5gDash106Dash5530Dash80 string = "5g-106-5530-80" + + // InterfaceRfChannelValueNr5gDash108Dash5540Dash20 captures enum value "5g-108-5540-20" + InterfaceRfChannelValueNr5gDash108Dash5540Dash20 string = "5g-108-5540-20" + + // InterfaceRfChannelValueNr5gDash110Dash5550Dash40 captures enum value "5g-110-5550-40" + InterfaceRfChannelValueNr5gDash110Dash5550Dash40 string = "5g-110-5550-40" + + // InterfaceRfChannelValueNr5gDash112Dash5560Dash20 captures enum value "5g-112-5560-20" + InterfaceRfChannelValueNr5gDash112Dash5560Dash20 string = "5g-112-5560-20" + + // InterfaceRfChannelValueNr5gDash114Dash5570Dash160 captures enum value "5g-114-5570-160" + InterfaceRfChannelValueNr5gDash114Dash5570Dash160 string = "5g-114-5570-160" + + // InterfaceRfChannelValueNr5gDash116Dash5580Dash20 captures enum value "5g-116-5580-20" + InterfaceRfChannelValueNr5gDash116Dash5580Dash20 string = "5g-116-5580-20" + + // InterfaceRfChannelValueNr5gDash118Dash5590Dash40 captures enum value "5g-118-5590-40" + InterfaceRfChannelValueNr5gDash118Dash5590Dash40 string = "5g-118-5590-40" + + // InterfaceRfChannelValueNr5gDash120Dash5600Dash20 captures enum value "5g-120-5600-20" + InterfaceRfChannelValueNr5gDash120Dash5600Dash20 string = "5g-120-5600-20" + + // InterfaceRfChannelValueNr5gDash122Dash5610Dash80 captures enum value "5g-122-5610-80" + InterfaceRfChannelValueNr5gDash122Dash5610Dash80 string = "5g-122-5610-80" + + // InterfaceRfChannelValueNr5gDash124Dash5620Dash20 captures enum value "5g-124-5620-20" + InterfaceRfChannelValueNr5gDash124Dash5620Dash20 string = "5g-124-5620-20" + + // InterfaceRfChannelValueNr5gDash126Dash5630Dash40 captures enum value "5g-126-5630-40" + InterfaceRfChannelValueNr5gDash126Dash5630Dash40 string = "5g-126-5630-40" + + // InterfaceRfChannelValueNr5gDash128Dash5640Dash20 captures enum value "5g-128-5640-20" + InterfaceRfChannelValueNr5gDash128Dash5640Dash20 string = "5g-128-5640-20" + + // InterfaceRfChannelValueNr5gDash132Dash5660Dash20 captures enum value "5g-132-5660-20" + InterfaceRfChannelValueNr5gDash132Dash5660Dash20 string = "5g-132-5660-20" + + // InterfaceRfChannelValueNr5gDash134Dash5670Dash40 captures enum value "5g-134-5670-40" + InterfaceRfChannelValueNr5gDash134Dash5670Dash40 string = "5g-134-5670-40" + + // InterfaceRfChannelValueNr5gDash136Dash5680Dash20 captures enum value "5g-136-5680-20" + InterfaceRfChannelValueNr5gDash136Dash5680Dash20 string = "5g-136-5680-20" + + // InterfaceRfChannelValueNr5gDash138Dash5690Dash80 captures enum value "5g-138-5690-80" + InterfaceRfChannelValueNr5gDash138Dash5690Dash80 string = "5g-138-5690-80" + + // InterfaceRfChannelValueNr5gDash140Dash5700Dash20 captures enum value "5g-140-5700-20" + InterfaceRfChannelValueNr5gDash140Dash5700Dash20 string = "5g-140-5700-20" + + // InterfaceRfChannelValueNr5gDash142Dash5710Dash40 captures enum value "5g-142-5710-40" + InterfaceRfChannelValueNr5gDash142Dash5710Dash40 string = "5g-142-5710-40" + + // InterfaceRfChannelValueNr5gDash144Dash5720Dash20 captures enum value "5g-144-5720-20" + InterfaceRfChannelValueNr5gDash144Dash5720Dash20 string = "5g-144-5720-20" + + // InterfaceRfChannelValueNr5gDash149Dash5745Dash20 captures enum value "5g-149-5745-20" + InterfaceRfChannelValueNr5gDash149Dash5745Dash20 string = "5g-149-5745-20" + + // InterfaceRfChannelValueNr5gDash151Dash5755Dash40 captures enum value "5g-151-5755-40" + InterfaceRfChannelValueNr5gDash151Dash5755Dash40 string = "5g-151-5755-40" + + // InterfaceRfChannelValueNr5gDash153Dash5765Dash20 captures enum value "5g-153-5765-20" + InterfaceRfChannelValueNr5gDash153Dash5765Dash20 string = "5g-153-5765-20" + + // InterfaceRfChannelValueNr5gDash155Dash5775Dash80 captures enum value "5g-155-5775-80" + InterfaceRfChannelValueNr5gDash155Dash5775Dash80 string = "5g-155-5775-80" + + // InterfaceRfChannelValueNr5gDash157Dash5785Dash20 captures enum value "5g-157-5785-20" + InterfaceRfChannelValueNr5gDash157Dash5785Dash20 string = "5g-157-5785-20" + + // InterfaceRfChannelValueNr5gDash159Dash5795Dash40 captures enum value "5g-159-5795-40" + InterfaceRfChannelValueNr5gDash159Dash5795Dash40 string = "5g-159-5795-40" + + // InterfaceRfChannelValueNr5gDash161Dash5805Dash20 captures enum value "5g-161-5805-20" + InterfaceRfChannelValueNr5gDash161Dash5805Dash20 string = "5g-161-5805-20" + + // InterfaceRfChannelValueNr5gDash163Dash5815Dash160 captures enum value "5g-163-5815-160" + InterfaceRfChannelValueNr5gDash163Dash5815Dash160 string = "5g-163-5815-160" + + // InterfaceRfChannelValueNr5gDash165Dash5825Dash20 captures enum value "5g-165-5825-20" + InterfaceRfChannelValueNr5gDash165Dash5825Dash20 string = "5g-165-5825-20" + + // InterfaceRfChannelValueNr5gDash167Dash5835Dash40 captures enum value "5g-167-5835-40" + InterfaceRfChannelValueNr5gDash167Dash5835Dash40 string = "5g-167-5835-40" + + // InterfaceRfChannelValueNr5gDash169Dash5845Dash20 captures enum value "5g-169-5845-20" + InterfaceRfChannelValueNr5gDash169Dash5845Dash20 string = "5g-169-5845-20" + + // InterfaceRfChannelValueNr5gDash171Dash5855Dash80 captures enum value "5g-171-5855-80" + InterfaceRfChannelValueNr5gDash171Dash5855Dash80 string = "5g-171-5855-80" + + // InterfaceRfChannelValueNr5gDash173Dash5865Dash20 captures enum value "5g-173-5865-20" + InterfaceRfChannelValueNr5gDash173Dash5865Dash20 string = "5g-173-5865-20" + + // InterfaceRfChannelValueNr5gDash175Dash5875Dash40 captures enum value "5g-175-5875-40" + InterfaceRfChannelValueNr5gDash175Dash5875Dash40 string = "5g-175-5875-40" + + // InterfaceRfChannelValueNr5gDash177Dash5885Dash20 captures enum value "5g-177-5885-20" + InterfaceRfChannelValueNr5gDash177Dash5885Dash20 string = "5g-177-5885-20" + + // InterfaceRfChannelValueNr6gDash1Dash5955Dash20 captures enum value "6g-1-5955-20" + InterfaceRfChannelValueNr6gDash1Dash5955Dash20 string = "6g-1-5955-20" + + // InterfaceRfChannelValueNr6gDash3Dash5965Dash40 captures enum value "6g-3-5965-40" + InterfaceRfChannelValueNr6gDash3Dash5965Dash40 string = "6g-3-5965-40" + + // InterfaceRfChannelValueNr6gDash5Dash5975Dash20 captures enum value "6g-5-5975-20" + InterfaceRfChannelValueNr6gDash5Dash5975Dash20 string = "6g-5-5975-20" + + // InterfaceRfChannelValueNr6gDash7Dash5985Dash80 captures enum value "6g-7-5985-80" + InterfaceRfChannelValueNr6gDash7Dash5985Dash80 string = "6g-7-5985-80" + + // InterfaceRfChannelValueNr6gDash9Dash5995Dash20 captures enum value "6g-9-5995-20" + InterfaceRfChannelValueNr6gDash9Dash5995Dash20 string = "6g-9-5995-20" + + // InterfaceRfChannelValueNr6gDash11Dash6005Dash40 captures enum value "6g-11-6005-40" + InterfaceRfChannelValueNr6gDash11Dash6005Dash40 string = "6g-11-6005-40" + + // InterfaceRfChannelValueNr6gDash13Dash6015Dash20 captures enum value "6g-13-6015-20" + InterfaceRfChannelValueNr6gDash13Dash6015Dash20 string = "6g-13-6015-20" + + // InterfaceRfChannelValueNr6gDash15Dash6025Dash160 captures enum value "6g-15-6025-160" + InterfaceRfChannelValueNr6gDash15Dash6025Dash160 string = "6g-15-6025-160" + + // InterfaceRfChannelValueNr6gDash17Dash6035Dash20 captures enum value "6g-17-6035-20" + InterfaceRfChannelValueNr6gDash17Dash6035Dash20 string = "6g-17-6035-20" + + // InterfaceRfChannelValueNr6gDash19Dash6045Dash40 captures enum value "6g-19-6045-40" + InterfaceRfChannelValueNr6gDash19Dash6045Dash40 string = "6g-19-6045-40" + + // InterfaceRfChannelValueNr6gDash21Dash6055Dash20 captures enum value "6g-21-6055-20" + InterfaceRfChannelValueNr6gDash21Dash6055Dash20 string = "6g-21-6055-20" + + // InterfaceRfChannelValueNr6gDash23Dash6065Dash80 captures enum value "6g-23-6065-80" + InterfaceRfChannelValueNr6gDash23Dash6065Dash80 string = "6g-23-6065-80" + + // InterfaceRfChannelValueNr6gDash25Dash6075Dash20 captures enum value "6g-25-6075-20" + InterfaceRfChannelValueNr6gDash25Dash6075Dash20 string = "6g-25-6075-20" + + // InterfaceRfChannelValueNr6gDash27Dash6085Dash40 captures enum value "6g-27-6085-40" + InterfaceRfChannelValueNr6gDash27Dash6085Dash40 string = "6g-27-6085-40" + + // InterfaceRfChannelValueNr6gDash29Dash6095Dash20 captures enum value "6g-29-6095-20" + InterfaceRfChannelValueNr6gDash29Dash6095Dash20 string = "6g-29-6095-20" + + // InterfaceRfChannelValueNr6gDash31Dash6105Dash320 captures enum value "6g-31-6105-320" + InterfaceRfChannelValueNr6gDash31Dash6105Dash320 string = "6g-31-6105-320" + + // InterfaceRfChannelValueNr6gDash33Dash6115Dash20 captures enum value "6g-33-6115-20" + InterfaceRfChannelValueNr6gDash33Dash6115Dash20 string = "6g-33-6115-20" + + // InterfaceRfChannelValueNr6gDash35Dash6125Dash40 captures enum value "6g-35-6125-40" + InterfaceRfChannelValueNr6gDash35Dash6125Dash40 string = "6g-35-6125-40" + + // InterfaceRfChannelValueNr6gDash37Dash6135Dash20 captures enum value "6g-37-6135-20" + InterfaceRfChannelValueNr6gDash37Dash6135Dash20 string = "6g-37-6135-20" + + // InterfaceRfChannelValueNr6gDash39Dash6145Dash80 captures enum value "6g-39-6145-80" + InterfaceRfChannelValueNr6gDash39Dash6145Dash80 string = "6g-39-6145-80" + + // InterfaceRfChannelValueNr6gDash41Dash6155Dash20 captures enum value "6g-41-6155-20" + InterfaceRfChannelValueNr6gDash41Dash6155Dash20 string = "6g-41-6155-20" + + // InterfaceRfChannelValueNr6gDash43Dash6165Dash40 captures enum value "6g-43-6165-40" + InterfaceRfChannelValueNr6gDash43Dash6165Dash40 string = "6g-43-6165-40" + + // InterfaceRfChannelValueNr6gDash45Dash6175Dash20 captures enum value "6g-45-6175-20" + InterfaceRfChannelValueNr6gDash45Dash6175Dash20 string = "6g-45-6175-20" + + // InterfaceRfChannelValueNr6gDash47Dash6185Dash160 captures enum value "6g-47-6185-160" + InterfaceRfChannelValueNr6gDash47Dash6185Dash160 string = "6g-47-6185-160" + + // InterfaceRfChannelValueNr6gDash49Dash6195Dash20 captures enum value "6g-49-6195-20" + InterfaceRfChannelValueNr6gDash49Dash6195Dash20 string = "6g-49-6195-20" + + // InterfaceRfChannelValueNr6gDash51Dash6205Dash40 captures enum value "6g-51-6205-40" + InterfaceRfChannelValueNr6gDash51Dash6205Dash40 string = "6g-51-6205-40" + + // InterfaceRfChannelValueNr6gDash53Dash6215Dash20 captures enum value "6g-53-6215-20" + InterfaceRfChannelValueNr6gDash53Dash6215Dash20 string = "6g-53-6215-20" + + // InterfaceRfChannelValueNr6gDash55Dash6225Dash80 captures enum value "6g-55-6225-80" + InterfaceRfChannelValueNr6gDash55Dash6225Dash80 string = "6g-55-6225-80" + + // InterfaceRfChannelValueNr6gDash57Dash6235Dash20 captures enum value "6g-57-6235-20" + InterfaceRfChannelValueNr6gDash57Dash6235Dash20 string = "6g-57-6235-20" + + // InterfaceRfChannelValueNr6gDash59Dash6245Dash40 captures enum value "6g-59-6245-40" + InterfaceRfChannelValueNr6gDash59Dash6245Dash40 string = "6g-59-6245-40" + + // InterfaceRfChannelValueNr6gDash61Dash6255Dash20 captures enum value "6g-61-6255-20" + InterfaceRfChannelValueNr6gDash61Dash6255Dash20 string = "6g-61-6255-20" + + // InterfaceRfChannelValueNr6gDash65Dash6275Dash20 captures enum value "6g-65-6275-20" + InterfaceRfChannelValueNr6gDash65Dash6275Dash20 string = "6g-65-6275-20" + + // InterfaceRfChannelValueNr6gDash67Dash6285Dash40 captures enum value "6g-67-6285-40" + InterfaceRfChannelValueNr6gDash67Dash6285Dash40 string = "6g-67-6285-40" + + // InterfaceRfChannelValueNr6gDash69Dash6295Dash20 captures enum value "6g-69-6295-20" + InterfaceRfChannelValueNr6gDash69Dash6295Dash20 string = "6g-69-6295-20" + + // InterfaceRfChannelValueNr6gDash71Dash6305Dash80 captures enum value "6g-71-6305-80" + InterfaceRfChannelValueNr6gDash71Dash6305Dash80 string = "6g-71-6305-80" + + // InterfaceRfChannelValueNr6gDash73Dash6315Dash20 captures enum value "6g-73-6315-20" + InterfaceRfChannelValueNr6gDash73Dash6315Dash20 string = "6g-73-6315-20" + + // InterfaceRfChannelValueNr6gDash75Dash6325Dash40 captures enum value "6g-75-6325-40" + InterfaceRfChannelValueNr6gDash75Dash6325Dash40 string = "6g-75-6325-40" + + // InterfaceRfChannelValueNr6gDash77Dash6335Dash20 captures enum value "6g-77-6335-20" + InterfaceRfChannelValueNr6gDash77Dash6335Dash20 string = "6g-77-6335-20" + + // InterfaceRfChannelValueNr6gDash79Dash6345Dash160 captures enum value "6g-79-6345-160" + InterfaceRfChannelValueNr6gDash79Dash6345Dash160 string = "6g-79-6345-160" + + // InterfaceRfChannelValueNr6gDash81Dash6355Dash20 captures enum value "6g-81-6355-20" + InterfaceRfChannelValueNr6gDash81Dash6355Dash20 string = "6g-81-6355-20" + + // InterfaceRfChannelValueNr6gDash83Dash6365Dash40 captures enum value "6g-83-6365-40" + InterfaceRfChannelValueNr6gDash83Dash6365Dash40 string = "6g-83-6365-40" + + // InterfaceRfChannelValueNr6gDash85Dash6375Dash20 captures enum value "6g-85-6375-20" + InterfaceRfChannelValueNr6gDash85Dash6375Dash20 string = "6g-85-6375-20" + + // InterfaceRfChannelValueNr6gDash87Dash6385Dash80 captures enum value "6g-87-6385-80" + InterfaceRfChannelValueNr6gDash87Dash6385Dash80 string = "6g-87-6385-80" + + // InterfaceRfChannelValueNr6gDash89Dash6395Dash20 captures enum value "6g-89-6395-20" + InterfaceRfChannelValueNr6gDash89Dash6395Dash20 string = "6g-89-6395-20" + + // InterfaceRfChannelValueNr6gDash91Dash6405Dash40 captures enum value "6g-91-6405-40" + InterfaceRfChannelValueNr6gDash91Dash6405Dash40 string = "6g-91-6405-40" + + // InterfaceRfChannelValueNr6gDash93Dash6415Dash20 captures enum value "6g-93-6415-20" + InterfaceRfChannelValueNr6gDash93Dash6415Dash20 string = "6g-93-6415-20" + + // InterfaceRfChannelValueNr6gDash95Dash6425Dash320 captures enum value "6g-95-6425-320" + InterfaceRfChannelValueNr6gDash95Dash6425Dash320 string = "6g-95-6425-320" + + // InterfaceRfChannelValueNr6gDash97Dash6435Dash20 captures enum value "6g-97-6435-20" + InterfaceRfChannelValueNr6gDash97Dash6435Dash20 string = "6g-97-6435-20" + + // InterfaceRfChannelValueNr6gDash99Dash6445Dash40 captures enum value "6g-99-6445-40" + InterfaceRfChannelValueNr6gDash99Dash6445Dash40 string = "6g-99-6445-40" + + // InterfaceRfChannelValueNr6gDash101Dash6455Dash20 captures enum value "6g-101-6455-20" + InterfaceRfChannelValueNr6gDash101Dash6455Dash20 string = "6g-101-6455-20" + + // InterfaceRfChannelValueNr6gDash103Dash6465Dash80 captures enum value "6g-103-6465-80" + InterfaceRfChannelValueNr6gDash103Dash6465Dash80 string = "6g-103-6465-80" + + // InterfaceRfChannelValueNr6gDash105Dash6475Dash20 captures enum value "6g-105-6475-20" + InterfaceRfChannelValueNr6gDash105Dash6475Dash20 string = "6g-105-6475-20" + + // InterfaceRfChannelValueNr6gDash107Dash6485Dash40 captures enum value "6g-107-6485-40" + InterfaceRfChannelValueNr6gDash107Dash6485Dash40 string = "6g-107-6485-40" + + // InterfaceRfChannelValueNr6gDash109Dash6495Dash20 captures enum value "6g-109-6495-20" + InterfaceRfChannelValueNr6gDash109Dash6495Dash20 string = "6g-109-6495-20" + + // InterfaceRfChannelValueNr6gDash111Dash6505Dash160 captures enum value "6g-111-6505-160" + InterfaceRfChannelValueNr6gDash111Dash6505Dash160 string = "6g-111-6505-160" + + // InterfaceRfChannelValueNr6gDash113Dash6515Dash20 captures enum value "6g-113-6515-20" + InterfaceRfChannelValueNr6gDash113Dash6515Dash20 string = "6g-113-6515-20" + + // InterfaceRfChannelValueNr6gDash115Dash6525Dash40 captures enum value "6g-115-6525-40" + InterfaceRfChannelValueNr6gDash115Dash6525Dash40 string = "6g-115-6525-40" + + // InterfaceRfChannelValueNr6gDash117Dash6535Dash20 captures enum value "6g-117-6535-20" + InterfaceRfChannelValueNr6gDash117Dash6535Dash20 string = "6g-117-6535-20" + + // InterfaceRfChannelValueNr6gDash119Dash6545Dash80 captures enum value "6g-119-6545-80" + InterfaceRfChannelValueNr6gDash119Dash6545Dash80 string = "6g-119-6545-80" + + // InterfaceRfChannelValueNr6gDash121Dash6555Dash20 captures enum value "6g-121-6555-20" + InterfaceRfChannelValueNr6gDash121Dash6555Dash20 string = "6g-121-6555-20" + + // InterfaceRfChannelValueNr6gDash123Dash6565Dash40 captures enum value "6g-123-6565-40" + InterfaceRfChannelValueNr6gDash123Dash6565Dash40 string = "6g-123-6565-40" + + // InterfaceRfChannelValueNr6gDash125Dash6575Dash20 captures enum value "6g-125-6575-20" + InterfaceRfChannelValueNr6gDash125Dash6575Dash20 string = "6g-125-6575-20" + + // InterfaceRfChannelValueNr6gDash129Dash6595Dash20 captures enum value "6g-129-6595-20" + InterfaceRfChannelValueNr6gDash129Dash6595Dash20 string = "6g-129-6595-20" + + // InterfaceRfChannelValueNr6gDash131Dash6605Dash40 captures enum value "6g-131-6605-40" + InterfaceRfChannelValueNr6gDash131Dash6605Dash40 string = "6g-131-6605-40" + + // InterfaceRfChannelValueNr6gDash133Dash6615Dash20 captures enum value "6g-133-6615-20" + InterfaceRfChannelValueNr6gDash133Dash6615Dash20 string = "6g-133-6615-20" + + // InterfaceRfChannelValueNr6gDash135Dash6625Dash80 captures enum value "6g-135-6625-80" + InterfaceRfChannelValueNr6gDash135Dash6625Dash80 string = "6g-135-6625-80" + + // InterfaceRfChannelValueNr6gDash137Dash6635Dash20 captures enum value "6g-137-6635-20" + InterfaceRfChannelValueNr6gDash137Dash6635Dash20 string = "6g-137-6635-20" + + // InterfaceRfChannelValueNr6gDash139Dash6645Dash40 captures enum value "6g-139-6645-40" + InterfaceRfChannelValueNr6gDash139Dash6645Dash40 string = "6g-139-6645-40" + + // InterfaceRfChannelValueNr6gDash141Dash6655Dash20 captures enum value "6g-141-6655-20" + InterfaceRfChannelValueNr6gDash141Dash6655Dash20 string = "6g-141-6655-20" + + // InterfaceRfChannelValueNr6gDash143Dash6665Dash160 captures enum value "6g-143-6665-160" + InterfaceRfChannelValueNr6gDash143Dash6665Dash160 string = "6g-143-6665-160" + + // InterfaceRfChannelValueNr6gDash145Dash6675Dash20 captures enum value "6g-145-6675-20" + InterfaceRfChannelValueNr6gDash145Dash6675Dash20 string = "6g-145-6675-20" + + // InterfaceRfChannelValueNr6gDash147Dash6685Dash40 captures enum value "6g-147-6685-40" + InterfaceRfChannelValueNr6gDash147Dash6685Dash40 string = "6g-147-6685-40" + + // InterfaceRfChannelValueNr6gDash149Dash6695Dash20 captures enum value "6g-149-6695-20" + InterfaceRfChannelValueNr6gDash149Dash6695Dash20 string = "6g-149-6695-20" + + // InterfaceRfChannelValueNr6gDash151Dash6705Dash80 captures enum value "6g-151-6705-80" + InterfaceRfChannelValueNr6gDash151Dash6705Dash80 string = "6g-151-6705-80" + + // InterfaceRfChannelValueNr6gDash153Dash6715Dash20 captures enum value "6g-153-6715-20" + InterfaceRfChannelValueNr6gDash153Dash6715Dash20 string = "6g-153-6715-20" + + // InterfaceRfChannelValueNr6gDash155Dash6725Dash40 captures enum value "6g-155-6725-40" + InterfaceRfChannelValueNr6gDash155Dash6725Dash40 string = "6g-155-6725-40" + + // InterfaceRfChannelValueNr6gDash157Dash6735Dash20 captures enum value "6g-157-6735-20" + InterfaceRfChannelValueNr6gDash157Dash6735Dash20 string = "6g-157-6735-20" + + // InterfaceRfChannelValueNr6gDash159Dash6745Dash320 captures enum value "6g-159-6745-320" + InterfaceRfChannelValueNr6gDash159Dash6745Dash320 string = "6g-159-6745-320" + + // InterfaceRfChannelValueNr6gDash161Dash6755Dash20 captures enum value "6g-161-6755-20" + InterfaceRfChannelValueNr6gDash161Dash6755Dash20 string = "6g-161-6755-20" + + // InterfaceRfChannelValueNr6gDash163Dash6765Dash40 captures enum value "6g-163-6765-40" + InterfaceRfChannelValueNr6gDash163Dash6765Dash40 string = "6g-163-6765-40" + + // InterfaceRfChannelValueNr6gDash165Dash6775Dash20 captures enum value "6g-165-6775-20" + InterfaceRfChannelValueNr6gDash165Dash6775Dash20 string = "6g-165-6775-20" + + // InterfaceRfChannelValueNr6gDash167Dash6785Dash80 captures enum value "6g-167-6785-80" + InterfaceRfChannelValueNr6gDash167Dash6785Dash80 string = "6g-167-6785-80" + + // InterfaceRfChannelValueNr6gDash169Dash6795Dash20 captures enum value "6g-169-6795-20" + InterfaceRfChannelValueNr6gDash169Dash6795Dash20 string = "6g-169-6795-20" + + // InterfaceRfChannelValueNr6gDash171Dash6805Dash40 captures enum value "6g-171-6805-40" + InterfaceRfChannelValueNr6gDash171Dash6805Dash40 string = "6g-171-6805-40" + + // InterfaceRfChannelValueNr6gDash173Dash6815Dash20 captures enum value "6g-173-6815-20" + InterfaceRfChannelValueNr6gDash173Dash6815Dash20 string = "6g-173-6815-20" + + // InterfaceRfChannelValueNr6gDash175Dash6825Dash160 captures enum value "6g-175-6825-160" + InterfaceRfChannelValueNr6gDash175Dash6825Dash160 string = "6g-175-6825-160" + + // InterfaceRfChannelValueNr6gDash177Dash6835Dash20 captures enum value "6g-177-6835-20" + InterfaceRfChannelValueNr6gDash177Dash6835Dash20 string = "6g-177-6835-20" + + // InterfaceRfChannelValueNr6gDash179Dash6845Dash40 captures enum value "6g-179-6845-40" + InterfaceRfChannelValueNr6gDash179Dash6845Dash40 string = "6g-179-6845-40" + + // InterfaceRfChannelValueNr6gDash181Dash6855Dash20 captures enum value "6g-181-6855-20" + InterfaceRfChannelValueNr6gDash181Dash6855Dash20 string = "6g-181-6855-20" + + // InterfaceRfChannelValueNr6gDash183Dash6865Dash80 captures enum value "6g-183-6865-80" + InterfaceRfChannelValueNr6gDash183Dash6865Dash80 string = "6g-183-6865-80" + + // InterfaceRfChannelValueNr6gDash185Dash6875Dash20 captures enum value "6g-185-6875-20" + InterfaceRfChannelValueNr6gDash185Dash6875Dash20 string = "6g-185-6875-20" + + // InterfaceRfChannelValueNr6gDash187Dash6885Dash40 captures enum value "6g-187-6885-40" + InterfaceRfChannelValueNr6gDash187Dash6885Dash40 string = "6g-187-6885-40" + + // InterfaceRfChannelValueNr6gDash189Dash6895Dash20 captures enum value "6g-189-6895-20" + InterfaceRfChannelValueNr6gDash189Dash6895Dash20 string = "6g-189-6895-20" + + // InterfaceRfChannelValueNr6gDash193Dash6915Dash20 captures enum value "6g-193-6915-20" + InterfaceRfChannelValueNr6gDash193Dash6915Dash20 string = "6g-193-6915-20" + + // InterfaceRfChannelValueNr6gDash195Dash6925Dash40 captures enum value "6g-195-6925-40" + InterfaceRfChannelValueNr6gDash195Dash6925Dash40 string = "6g-195-6925-40" + + // InterfaceRfChannelValueNr6gDash197Dash6935Dash20 captures enum value "6g-197-6935-20" + InterfaceRfChannelValueNr6gDash197Dash6935Dash20 string = "6g-197-6935-20" + + // InterfaceRfChannelValueNr6gDash199Dash6945Dash80 captures enum value "6g-199-6945-80" + InterfaceRfChannelValueNr6gDash199Dash6945Dash80 string = "6g-199-6945-80" + + // InterfaceRfChannelValueNr6gDash201Dash6955Dash20 captures enum value "6g-201-6955-20" + InterfaceRfChannelValueNr6gDash201Dash6955Dash20 string = "6g-201-6955-20" + + // InterfaceRfChannelValueNr6gDash203Dash6965Dash40 captures enum value "6g-203-6965-40" + InterfaceRfChannelValueNr6gDash203Dash6965Dash40 string = "6g-203-6965-40" + + // InterfaceRfChannelValueNr6gDash205Dash6975Dash20 captures enum value "6g-205-6975-20" + InterfaceRfChannelValueNr6gDash205Dash6975Dash20 string = "6g-205-6975-20" + + // InterfaceRfChannelValueNr6gDash207Dash6985Dash160 captures enum value "6g-207-6985-160" + InterfaceRfChannelValueNr6gDash207Dash6985Dash160 string = "6g-207-6985-160" + + // InterfaceRfChannelValueNr6gDash209Dash6995Dash20 captures enum value "6g-209-6995-20" + InterfaceRfChannelValueNr6gDash209Dash6995Dash20 string = "6g-209-6995-20" + + // InterfaceRfChannelValueNr6gDash211Dash7005Dash40 captures enum value "6g-211-7005-40" + InterfaceRfChannelValueNr6gDash211Dash7005Dash40 string = "6g-211-7005-40" + + // InterfaceRfChannelValueNr6gDash213Dash7015Dash20 captures enum value "6g-213-7015-20" + InterfaceRfChannelValueNr6gDash213Dash7015Dash20 string = "6g-213-7015-20" + + // InterfaceRfChannelValueNr6gDash215Dash7025Dash80 captures enum value "6g-215-7025-80" + InterfaceRfChannelValueNr6gDash215Dash7025Dash80 string = "6g-215-7025-80" + + // InterfaceRfChannelValueNr6gDash217Dash7035Dash20 captures enum value "6g-217-7035-20" + InterfaceRfChannelValueNr6gDash217Dash7035Dash20 string = "6g-217-7035-20" + + // InterfaceRfChannelValueNr6gDash219Dash7045Dash40 captures enum value "6g-219-7045-40" + InterfaceRfChannelValueNr6gDash219Dash7045Dash40 string = "6g-219-7045-40" + + // InterfaceRfChannelValueNr6gDash221Dash7055Dash20 captures enum value "6g-221-7055-20" + InterfaceRfChannelValueNr6gDash221Dash7055Dash20 string = "6g-221-7055-20" + + // InterfaceRfChannelValueNr6gDash225Dash7075Dash20 captures enum value "6g-225-7075-20" + InterfaceRfChannelValueNr6gDash225Dash7075Dash20 string = "6g-225-7075-20" + + // InterfaceRfChannelValueNr6gDash227Dash7085Dash40 captures enum value "6g-227-7085-40" + InterfaceRfChannelValueNr6gDash227Dash7085Dash40 string = "6g-227-7085-40" + + // InterfaceRfChannelValueNr6gDash229Dash7095Dash20 captures enum value "6g-229-7095-20" + InterfaceRfChannelValueNr6gDash229Dash7095Dash20 string = "6g-229-7095-20" + + // InterfaceRfChannelValueNr6gDash233Dash7115Dash20 captures enum value "6g-233-7115-20" + InterfaceRfChannelValueNr6gDash233Dash7115Dash20 string = "6g-233-7115-20" + + // InterfaceRfChannelValueNr60gDash1Dash58320Dash2160 captures enum value "60g-1-58320-2160" + InterfaceRfChannelValueNr60gDash1Dash58320Dash2160 string = "60g-1-58320-2160" + + // InterfaceRfChannelValueNr60gDash2Dash60480Dash2160 captures enum value "60g-2-60480-2160" + InterfaceRfChannelValueNr60gDash2Dash60480Dash2160 string = "60g-2-60480-2160" + + // InterfaceRfChannelValueNr60gDash3Dash62640Dash2160 captures enum value "60g-3-62640-2160" + InterfaceRfChannelValueNr60gDash3Dash62640Dash2160 string = "60g-3-62640-2160" + + // InterfaceRfChannelValueNr60gDash4Dash64800Dash2160 captures enum value "60g-4-64800-2160" + InterfaceRfChannelValueNr60gDash4Dash64800Dash2160 string = "60g-4-64800-2160" + + // InterfaceRfChannelValueNr60gDash5Dash66960Dash2160 captures enum value "60g-5-66960-2160" + InterfaceRfChannelValueNr60gDash5Dash66960Dash2160 string = "60g-5-66960-2160" + + // InterfaceRfChannelValueNr60gDash6Dash69120Dash2160 captures enum value "60g-6-69120-2160" + InterfaceRfChannelValueNr60gDash6Dash69120Dash2160 string = "60g-6-69120-2160" + + // InterfaceRfChannelValueNr60gDash9Dash59400Dash4320 captures enum value "60g-9-59400-4320" + InterfaceRfChannelValueNr60gDash9Dash59400Dash4320 string = "60g-9-59400-4320" + + // InterfaceRfChannelValueNr60gDash10Dash61560Dash4320 captures enum value "60g-10-61560-4320" + InterfaceRfChannelValueNr60gDash10Dash61560Dash4320 string = "60g-10-61560-4320" + + // InterfaceRfChannelValueNr60gDash11Dash63720Dash4320 captures enum value "60g-11-63720-4320" + InterfaceRfChannelValueNr60gDash11Dash63720Dash4320 string = "60g-11-63720-4320" + + // InterfaceRfChannelValueNr60gDash12Dash65880Dash4320 captures enum value "60g-12-65880-4320" + InterfaceRfChannelValueNr60gDash12Dash65880Dash4320 string = "60g-12-65880-4320" + + // InterfaceRfChannelValueNr60gDash13Dash68040Dash4320 captures enum value "60g-13-68040-4320" + InterfaceRfChannelValueNr60gDash13Dash68040Dash4320 string = "60g-13-68040-4320" + + // InterfaceRfChannelValueNr60gDash17Dash60480Dash6480 captures enum value "60g-17-60480-6480" + InterfaceRfChannelValueNr60gDash17Dash60480Dash6480 string = "60g-17-60480-6480" + + // InterfaceRfChannelValueNr60gDash18Dash62640Dash6480 captures enum value "60g-18-62640-6480" + InterfaceRfChannelValueNr60gDash18Dash62640Dash6480 string = "60g-18-62640-6480" + + // InterfaceRfChannelValueNr60gDash19Dash64800Dash6480 captures enum value "60g-19-64800-6480" + InterfaceRfChannelValueNr60gDash19Dash64800Dash6480 string = "60g-19-64800-6480" + + // InterfaceRfChannelValueNr60gDash20Dash66960Dash6480 captures enum value "60g-20-66960-6480" + InterfaceRfChannelValueNr60gDash20Dash66960Dash6480 string = "60g-20-66960-6480" + + // InterfaceRfChannelValueNr60gDash25Dash61560Dash6480 captures enum value "60g-25-61560-6480" + InterfaceRfChannelValueNr60gDash25Dash61560Dash6480 string = "60g-25-61560-6480" + + // InterfaceRfChannelValueNr60gDash26Dash63720Dash6480 captures enum value "60g-26-63720-6480" + InterfaceRfChannelValueNr60gDash26Dash63720Dash6480 string = "60g-26-63720-6480" + + // InterfaceRfChannelValueNr60gDash27Dash65880Dash6480 captures enum value "60g-27-65880-6480" + InterfaceRfChannelValueNr60gDash27Dash65880Dash6480 string = "60g-27-65880-6480" +) + +// prop value enum +func (m *InterfaceRfChannel) validateValueEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, interfaceRfChannelTypeValuePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *InterfaceRfChannel) validateValue(formats strfmt.Registry) error { + + if err := validate.Required("rf_channel"+"."+"value", "body", m.Value); err != nil { + return err + } + + // value enum + if err := m.validateValueEnum("rf_channel"+"."+"value", "body", *m.Value); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this interface rf channel based on context it is used +func (m *InterfaceRfChannel) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *InterfaceRfChannel) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *InterfaceRfChannel) UnmarshalBinary(b []byte) error { + var res InterfaceRfChannel + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + +// InterfaceRfRole Rf role +// +// swagger:model InterfaceRfRole +type InterfaceRfRole struct { + + // label + // Required: true + // Enum: [Access point Station] + Label *string `json:"label"` + + // value + // Required: true + // Enum: [ap station] + Value *string `json:"value"` +} + +// Validate validates this interface rf role +func (m *InterfaceRfRole) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateLabel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateValue(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var interfaceRfRoleTypeLabelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["Access point","Station"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + interfaceRfRoleTypeLabelPropEnum = append(interfaceRfRoleTypeLabelPropEnum, v) + } +} + +const ( + + // InterfaceRfRoleLabelAccessPoint captures enum value "Access point" + InterfaceRfRoleLabelAccessPoint string = "Access point" + + // InterfaceRfRoleLabelStation captures enum value "Station" + InterfaceRfRoleLabelStation string = "Station" +) + +// prop value enum +func (m *InterfaceRfRole) validateLabelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, interfaceRfRoleTypeLabelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *InterfaceRfRole) validateLabel(formats strfmt.Registry) error { + + if err := validate.Required("rf_role"+"."+"label", "body", m.Label); err != nil { + return err + } + + // value enum + if err := m.validateLabelEnum("rf_role"+"."+"label", "body", *m.Label); err != nil { + return err + } + + return nil +} + +var interfaceRfRoleTypeValuePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["ap","station"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + interfaceRfRoleTypeValuePropEnum = append(interfaceRfRoleTypeValuePropEnum, v) + } +} + +const ( + + // InterfaceRfRoleValueAp captures enum value "ap" + InterfaceRfRoleValueAp string = "ap" + + // InterfaceRfRoleValueStation captures enum value "station" + InterfaceRfRoleValueStation string = "station" +) + +// prop value enum +func (m *InterfaceRfRole) validateValueEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, interfaceRfRoleTypeValuePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *InterfaceRfRole) validateValue(formats strfmt.Registry) error { + + if err := validate.Required("rf_role"+"."+"value", "body", m.Value); err != nil { + return err + } + + // value enum + if err := m.validateValueEnum("rf_role"+"."+"value", "body", *m.Value); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this interface rf role based on context it is used +func (m *InterfaceRfRole) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *InterfaceRfRole) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *InterfaceRfRole) UnmarshalBinary(b []byte) error { + var res InterfaceRfRole + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + +// InterfaceType Type +// +// swagger:model InterfaceType +type InterfaceType struct { + + // label + // Required: true + // Enum: [Virtual Bridge Link Aggregation Group (LAG) 100BASE-TX (10/100ME) 1000BASE-T (1GE) 2.5GBASE-T (2.5GE) 5GBASE-T (5GE) 10GBASE-T (10GE) 10GBASE-CX4 (10GE) GBIC (1GE) SFP (1GE) SFP+ (10GE) XFP (10GE) XENPAK (10GE) X2 (10GE) SFP28 (25GE) SFP56 (50GE) QSFP+ (40GE) QSFP28 (50GE) CFP (100GE) CFP2 (100GE) CFP2 (200GE) CFP4 (100GE) Cisco CPAK (100GE) QSFP28 (100GE) QSFP56 (200GE) QSFP-DD (400GE) OSFP (400GE) IEEE 802.11a IEEE 802.11b/g IEEE 802.11n IEEE 802.11ac IEEE 802.11ad IEEE 802.11ax IEEE 802.15.1 (Bluetooth) GSM CDMA LTE OC-3/STM-1 OC-12/STM-4 OC-48/STM-16 OC-192/STM-64 OC-768/STM-256 OC-1920/STM-640 OC-3840/STM-1234 SFP (1GFC) SFP (2GFC) SFP (4GFC) SFP+ (8GFC) SFP+ (16GFC) SFP28 (32GFC) QSFP+ (64GFC) QSFP28 (128GFC) SDR (2 Gbps) DDR (4 Gbps) QDR (8 Gbps) FDR10 (10 Gbps) FDR (13.5 Gbps) EDR (25 Gbps) HDR (50 Gbps) NDR (100 Gbps) XDR (250 Gbps) T1 (1.544 Mbps) E1 (2.048 Mbps) T3 (45 Mbps) E3 (34 Mbps) xDSL Cisco StackWise Cisco StackWise Plus Cisco FlexStack Cisco FlexStack Plus Cisco StackWise-80 Cisco StackWise-160 Cisco StackWise-320 Cisco StackWise-480 Juniper VCP Extreme SummitStack Extreme SummitStack-128 Extreme SummitStack-256 Extreme SummitStack-512 Other] + Label *string `json:"label"` + + // value + // Required: true + // Enum: [virtual bridge lag 100base-tx 1000base-t 2.5gbase-t 5gbase-t 10gbase-t 10gbase-cx4 1000base-x-gbic 1000base-x-sfp 10gbase-x-sfpp 10gbase-x-xfp 10gbase-x-xenpak 10gbase-x-x2 25gbase-x-sfp28 50gbase-x-sfp56 40gbase-x-qsfpp 50gbase-x-sfp28 100gbase-x-cfp 100gbase-x-cfp2 200gbase-x-cfp2 100gbase-x-cfp4 100gbase-x-cpak 100gbase-x-qsfp28 200gbase-x-qsfp56 400gbase-x-qsfpdd 400gbase-x-osfp ieee802.11a ieee802.11g ieee802.11n ieee802.11ac ieee802.11ad ieee802.11ax ieee802.15.1 gsm cdma lte sonet-oc3 sonet-oc12 sonet-oc48 sonet-oc192 sonet-oc768 sonet-oc1920 sonet-oc3840 1gfc-sfp 2gfc-sfp 4gfc-sfp 8gfc-sfpp 16gfc-sfpp 32gfc-sfp28 64gfc-qsfpp 128gfc-qsfp28 infiniband-sdr infiniband-ddr infiniband-qdr infiniband-fdr10 infiniband-fdr infiniband-edr infiniband-hdr infiniband-ndr infiniband-xdr t1 e1 t3 e3 xdsl cisco-stackwise cisco-stackwise-plus cisco-flexstack cisco-flexstack-plus cisco-stackwise-80 cisco-stackwise-160 cisco-stackwise-320 cisco-stackwise-480 juniper-vcp extreme-summitstack extreme-summitstack-128 extreme-summitstack-256 extreme-summitstack-512 other] + Value *string `json:"value"` +} + +// Validate validates this interface type +func (m *InterfaceType) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateLabel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateValue(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var interfaceTypeTypeLabelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["Virtual","Bridge","Link Aggregation Group (LAG)","100BASE-TX (10/100ME)","1000BASE-T (1GE)","2.5GBASE-T (2.5GE)","5GBASE-T (5GE)","10GBASE-T (10GE)","10GBASE-CX4 (10GE)","GBIC (1GE)","SFP (1GE)","SFP+ (10GE)","XFP (10GE)","XENPAK (10GE)","X2 (10GE)","SFP28 (25GE)","SFP56 (50GE)","QSFP+ (40GE)","QSFP28 (50GE)","CFP (100GE)","CFP2 (100GE)","CFP2 (200GE)","CFP4 (100GE)","Cisco CPAK (100GE)","QSFP28 (100GE)","QSFP56 (200GE)","QSFP-DD (400GE)","OSFP (400GE)","IEEE 802.11a","IEEE 802.11b/g","IEEE 802.11n","IEEE 802.11ac","IEEE 802.11ad","IEEE 802.11ax","IEEE 802.15.1 (Bluetooth)","GSM","CDMA","LTE","OC-3/STM-1","OC-12/STM-4","OC-48/STM-16","OC-192/STM-64","OC-768/STM-256","OC-1920/STM-640","OC-3840/STM-1234","SFP (1GFC)","SFP (2GFC)","SFP (4GFC)","SFP+ (8GFC)","SFP+ (16GFC)","SFP28 (32GFC)","QSFP+ (64GFC)","QSFP28 (128GFC)","SDR (2 Gbps)","DDR (4 Gbps)","QDR (8 Gbps)","FDR10 (10 Gbps)","FDR (13.5 Gbps)","EDR (25 Gbps)","HDR (50 Gbps)","NDR (100 Gbps)","XDR (250 Gbps)","T1 (1.544 Mbps)","E1 (2.048 Mbps)","T3 (45 Mbps)","E3 (34 Mbps)","xDSL","Cisco StackWise","Cisco StackWise Plus","Cisco FlexStack","Cisco FlexStack Plus","Cisco StackWise-80","Cisco StackWise-160","Cisco StackWise-320","Cisco StackWise-480","Juniper VCP","Extreme SummitStack","Extreme SummitStack-128","Extreme SummitStack-256","Extreme SummitStack-512","Other"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + interfaceTypeTypeLabelPropEnum = append(interfaceTypeTypeLabelPropEnum, v) + } +} + +const ( + + // InterfaceTypeLabelVirtual captures enum value "Virtual" + InterfaceTypeLabelVirtual string = "Virtual" + + // InterfaceTypeLabelBridge captures enum value "Bridge" + InterfaceTypeLabelBridge string = "Bridge" + + // InterfaceTypeLabelLinkAggregationGroupLAG captures enum value "Link Aggregation Group (LAG)" + InterfaceTypeLabelLinkAggregationGroupLAG string = "Link Aggregation Group (LAG)" + + // InterfaceTypeLabelNr100BASEDashTX10100ME captures enum value "100BASE-TX (10/100ME)" + InterfaceTypeLabelNr100BASEDashTX10100ME string = "100BASE-TX (10/100ME)" + + // InterfaceTypeLabelNr1000BASEDashT1GE captures enum value "1000BASE-T (1GE)" + InterfaceTypeLabelNr1000BASEDashT1GE string = "1000BASE-T (1GE)" + + // InterfaceTypeLabelNr2Dot5GBASEDashT2Dot5GE captures enum value "2.5GBASE-T (2.5GE)" + InterfaceTypeLabelNr2Dot5GBASEDashT2Dot5GE string = "2.5GBASE-T (2.5GE)" // InterfaceTypeLabelNr5GBASEDashT5GE captures enum value "5GBASE-T (5GE)" InterfaceTypeLabelNr5GBASEDashT5GE string = "5GBASE-T (5GE)" @@ -1295,6 +3053,18 @@ const ( // InterfaceTypeLabelCiscoFlexStackPlus captures enum value "Cisco FlexStack Plus" InterfaceTypeLabelCiscoFlexStackPlus string = "Cisco FlexStack Plus" + // InterfaceTypeLabelCiscoStackWiseDash80 captures enum value "Cisco StackWise-80" + InterfaceTypeLabelCiscoStackWiseDash80 string = "Cisco StackWise-80" + + // InterfaceTypeLabelCiscoStackWiseDash160 captures enum value "Cisco StackWise-160" + InterfaceTypeLabelCiscoStackWiseDash160 string = "Cisco StackWise-160" + + // InterfaceTypeLabelCiscoStackWiseDash320 captures enum value "Cisco StackWise-320" + InterfaceTypeLabelCiscoStackWiseDash320 string = "Cisco StackWise-320" + + // InterfaceTypeLabelCiscoStackWiseDash480 captures enum value "Cisco StackWise-480" + InterfaceTypeLabelCiscoStackWiseDash480 string = "Cisco StackWise-480" + // InterfaceTypeLabelJuniperVCP captures enum value "Juniper VCP" InterfaceTypeLabelJuniperVCP string = "Juniper VCP" @@ -1340,7 +3110,7 @@ var interfaceTypeTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["virtual","lag","100base-tx","1000base-t","2.5gbase-t","5gbase-t","10gbase-t","10gbase-cx4","1000base-x-gbic","1000base-x-sfp","10gbase-x-sfpp","10gbase-x-xfp","10gbase-x-xenpak","10gbase-x-x2","25gbase-x-sfp28","50gbase-x-sfp56","40gbase-x-qsfpp","50gbase-x-sfp28","100gbase-x-cfp","100gbase-x-cfp2","200gbase-x-cfp2","100gbase-x-cfp4","100gbase-x-cpak","100gbase-x-qsfp28","200gbase-x-qsfp56","400gbase-x-qsfpdd","400gbase-x-osfp","ieee802.11a","ieee802.11g","ieee802.11n","ieee802.11ac","ieee802.11ad","ieee802.11ax","ieee802.15.1","gsm","cdma","lte","sonet-oc3","sonet-oc12","sonet-oc48","sonet-oc192","sonet-oc768","sonet-oc1920","sonet-oc3840","1gfc-sfp","2gfc-sfp","4gfc-sfp","8gfc-sfpp","16gfc-sfpp","32gfc-sfp28","64gfc-qsfpp","128gfc-sfp28","infiniband-sdr","infiniband-ddr","infiniband-qdr","infiniband-fdr10","infiniband-fdr","infiniband-edr","infiniband-hdr","infiniband-ndr","infiniband-xdr","t1","e1","t3","e3","xdsl","cisco-stackwise","cisco-stackwise-plus","cisco-flexstack","cisco-flexstack-plus","juniper-vcp","extreme-summitstack","extreme-summitstack-128","extreme-summitstack-256","extreme-summitstack-512","other"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["virtual","bridge","lag","100base-tx","1000base-t","2.5gbase-t","5gbase-t","10gbase-t","10gbase-cx4","1000base-x-gbic","1000base-x-sfp","10gbase-x-sfpp","10gbase-x-xfp","10gbase-x-xenpak","10gbase-x-x2","25gbase-x-sfp28","50gbase-x-sfp56","40gbase-x-qsfpp","50gbase-x-sfp28","100gbase-x-cfp","100gbase-x-cfp2","200gbase-x-cfp2","100gbase-x-cfp4","100gbase-x-cpak","100gbase-x-qsfp28","200gbase-x-qsfp56","400gbase-x-qsfpdd","400gbase-x-osfp","ieee802.11a","ieee802.11g","ieee802.11n","ieee802.11ac","ieee802.11ad","ieee802.11ax","ieee802.15.1","gsm","cdma","lte","sonet-oc3","sonet-oc12","sonet-oc48","sonet-oc192","sonet-oc768","sonet-oc1920","sonet-oc3840","1gfc-sfp","2gfc-sfp","4gfc-sfp","8gfc-sfpp","16gfc-sfpp","32gfc-sfp28","64gfc-qsfpp","128gfc-qsfp28","infiniband-sdr","infiniband-ddr","infiniband-qdr","infiniband-fdr10","infiniband-fdr","infiniband-edr","infiniband-hdr","infiniband-ndr","infiniband-xdr","t1","e1","t3","e3","xdsl","cisco-stackwise","cisco-stackwise-plus","cisco-flexstack","cisco-flexstack-plus","cisco-stackwise-80","cisco-stackwise-160","cisco-stackwise-320","cisco-stackwise-480","juniper-vcp","extreme-summitstack","extreme-summitstack-128","extreme-summitstack-256","extreme-summitstack-512","other"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -1353,6 +3123,9 @@ const ( // InterfaceTypeValueVirtual captures enum value "virtual" InterfaceTypeValueVirtual string = "virtual" + // InterfaceTypeValueBridge captures enum value "bridge" + InterfaceTypeValueBridge string = "bridge" + // InterfaceTypeValueLag captures enum value "lag" InterfaceTypeValueLag string = "lag" @@ -1503,8 +3276,8 @@ const ( // InterfaceTypeValueNr64gfcDashQsfpp captures enum value "64gfc-qsfpp" InterfaceTypeValueNr64gfcDashQsfpp string = "64gfc-qsfpp" - // InterfaceTypeValueNr128gfcDashSfp28 captures enum value "128gfc-sfp28" - InterfaceTypeValueNr128gfcDashSfp28 string = "128gfc-sfp28" + // InterfaceTypeValueNr128gfcDashQsfp28 captures enum value "128gfc-qsfp28" + InterfaceTypeValueNr128gfcDashQsfp28 string = "128gfc-qsfp28" // InterfaceTypeValueInfinibandDashSdr captures enum value "infiniband-sdr" InterfaceTypeValueInfinibandDashSdr string = "infiniband-sdr" @@ -1560,6 +3333,18 @@ const ( // InterfaceTypeValueCiscoDashFlexstackDashPlus captures enum value "cisco-flexstack-plus" InterfaceTypeValueCiscoDashFlexstackDashPlus string = "cisco-flexstack-plus" + // InterfaceTypeValueCiscoDashStackwiseDash80 captures enum value "cisco-stackwise-80" + InterfaceTypeValueCiscoDashStackwiseDash80 string = "cisco-stackwise-80" + + // InterfaceTypeValueCiscoDashStackwiseDash160 captures enum value "cisco-stackwise-160" + InterfaceTypeValueCiscoDashStackwiseDash160 string = "cisco-stackwise-160" + + // InterfaceTypeValueCiscoDashStackwiseDash320 captures enum value "cisco-stackwise-320" + InterfaceTypeValueCiscoDashStackwiseDash320 string = "cisco-stackwise-320" + + // InterfaceTypeValueCiscoDashStackwiseDash480 captures enum value "cisco-stackwise-480" + InterfaceTypeValueCiscoDashStackwiseDash480 string = "cisco-stackwise-480" + // InterfaceTypeValueJuniperDashVcp captures enum value "juniper-vcp" InterfaceTypeValueJuniperDashVcp string = "juniper-vcp" diff --git a/netbox/models/interface_template.go b/netbox/models/interface_template.go index 17e7b98c..deb62463 100644 --- a/netbox/models/interface_template.go +++ b/netbox/models/interface_template.go @@ -385,12 +385,12 @@ type InterfaceTemplateType struct { // label // Required: true - // Enum: [Virtual Link Aggregation Group (LAG) 100BASE-TX (10/100ME) 1000BASE-T (1GE) 2.5GBASE-T (2.5GE) 5GBASE-T (5GE) 10GBASE-T (10GE) 10GBASE-CX4 (10GE) GBIC (1GE) SFP (1GE) SFP+ (10GE) XFP (10GE) XENPAK (10GE) X2 (10GE) SFP28 (25GE) SFP56 (50GE) QSFP+ (40GE) QSFP28 (50GE) CFP (100GE) CFP2 (100GE) CFP2 (200GE) CFP4 (100GE) Cisco CPAK (100GE) QSFP28 (100GE) QSFP56 (200GE) QSFP-DD (400GE) OSFP (400GE) IEEE 802.11a IEEE 802.11b/g IEEE 802.11n IEEE 802.11ac IEEE 802.11ad IEEE 802.11ax IEEE 802.15.1 (Bluetooth) GSM CDMA LTE OC-3/STM-1 OC-12/STM-4 OC-48/STM-16 OC-192/STM-64 OC-768/STM-256 OC-1920/STM-640 OC-3840/STM-1234 SFP (1GFC) SFP (2GFC) SFP (4GFC) SFP+ (8GFC) SFP+ (16GFC) SFP28 (32GFC) QSFP+ (64GFC) QSFP28 (128GFC) SDR (2 Gbps) DDR (4 Gbps) QDR (8 Gbps) FDR10 (10 Gbps) FDR (13.5 Gbps) EDR (25 Gbps) HDR (50 Gbps) NDR (100 Gbps) XDR (250 Gbps) T1 (1.544 Mbps) E1 (2.048 Mbps) T3 (45 Mbps) E3 (34 Mbps) xDSL Cisco StackWise Cisco StackWise Plus Cisco FlexStack Cisco FlexStack Plus Juniper VCP Extreme SummitStack Extreme SummitStack-128 Extreme SummitStack-256 Extreme SummitStack-512 Other] + // Enum: [Virtual Bridge Link Aggregation Group (LAG) 100BASE-TX (10/100ME) 1000BASE-T (1GE) 2.5GBASE-T (2.5GE) 5GBASE-T (5GE) 10GBASE-T (10GE) 10GBASE-CX4 (10GE) GBIC (1GE) SFP (1GE) SFP+ (10GE) XFP (10GE) XENPAK (10GE) X2 (10GE) SFP28 (25GE) SFP56 (50GE) QSFP+ (40GE) QSFP28 (50GE) CFP (100GE) CFP2 (100GE) CFP2 (200GE) CFP4 (100GE) Cisco CPAK (100GE) QSFP28 (100GE) QSFP56 (200GE) QSFP-DD (400GE) OSFP (400GE) IEEE 802.11a IEEE 802.11b/g IEEE 802.11n IEEE 802.11ac IEEE 802.11ad IEEE 802.11ax IEEE 802.15.1 (Bluetooth) GSM CDMA LTE OC-3/STM-1 OC-12/STM-4 OC-48/STM-16 OC-192/STM-64 OC-768/STM-256 OC-1920/STM-640 OC-3840/STM-1234 SFP (1GFC) SFP (2GFC) SFP (4GFC) SFP+ (8GFC) SFP+ (16GFC) SFP28 (32GFC) QSFP+ (64GFC) QSFP28 (128GFC) SDR (2 Gbps) DDR (4 Gbps) QDR (8 Gbps) FDR10 (10 Gbps) FDR (13.5 Gbps) EDR (25 Gbps) HDR (50 Gbps) NDR (100 Gbps) XDR (250 Gbps) T1 (1.544 Mbps) E1 (2.048 Mbps) T3 (45 Mbps) E3 (34 Mbps) xDSL Cisco StackWise Cisco StackWise Plus Cisco FlexStack Cisco FlexStack Plus Cisco StackWise-80 Cisco StackWise-160 Cisco StackWise-320 Cisco StackWise-480 Juniper VCP Extreme SummitStack Extreme SummitStack-128 Extreme SummitStack-256 Extreme SummitStack-512 Other] Label *string `json:"label"` // value // Required: true - // Enum: [virtual lag 100base-tx 1000base-t 2.5gbase-t 5gbase-t 10gbase-t 10gbase-cx4 1000base-x-gbic 1000base-x-sfp 10gbase-x-sfpp 10gbase-x-xfp 10gbase-x-xenpak 10gbase-x-x2 25gbase-x-sfp28 50gbase-x-sfp56 40gbase-x-qsfpp 50gbase-x-sfp28 100gbase-x-cfp 100gbase-x-cfp2 200gbase-x-cfp2 100gbase-x-cfp4 100gbase-x-cpak 100gbase-x-qsfp28 200gbase-x-qsfp56 400gbase-x-qsfpdd 400gbase-x-osfp ieee802.11a ieee802.11g ieee802.11n ieee802.11ac ieee802.11ad ieee802.11ax ieee802.15.1 gsm cdma lte sonet-oc3 sonet-oc12 sonet-oc48 sonet-oc192 sonet-oc768 sonet-oc1920 sonet-oc3840 1gfc-sfp 2gfc-sfp 4gfc-sfp 8gfc-sfpp 16gfc-sfpp 32gfc-sfp28 64gfc-qsfpp 128gfc-sfp28 infiniband-sdr infiniband-ddr infiniband-qdr infiniband-fdr10 infiniband-fdr infiniband-edr infiniband-hdr infiniband-ndr infiniband-xdr t1 e1 t3 e3 xdsl cisco-stackwise cisco-stackwise-plus cisco-flexstack cisco-flexstack-plus juniper-vcp extreme-summitstack extreme-summitstack-128 extreme-summitstack-256 extreme-summitstack-512 other] + // Enum: [virtual bridge lag 100base-tx 1000base-t 2.5gbase-t 5gbase-t 10gbase-t 10gbase-cx4 1000base-x-gbic 1000base-x-sfp 10gbase-x-sfpp 10gbase-x-xfp 10gbase-x-xenpak 10gbase-x-x2 25gbase-x-sfp28 50gbase-x-sfp56 40gbase-x-qsfpp 50gbase-x-sfp28 100gbase-x-cfp 100gbase-x-cfp2 200gbase-x-cfp2 100gbase-x-cfp4 100gbase-x-cpak 100gbase-x-qsfp28 200gbase-x-qsfp56 400gbase-x-qsfpdd 400gbase-x-osfp ieee802.11a ieee802.11g ieee802.11n ieee802.11ac ieee802.11ad ieee802.11ax ieee802.15.1 gsm cdma lte sonet-oc3 sonet-oc12 sonet-oc48 sonet-oc192 sonet-oc768 sonet-oc1920 sonet-oc3840 1gfc-sfp 2gfc-sfp 4gfc-sfp 8gfc-sfpp 16gfc-sfpp 32gfc-sfp28 64gfc-qsfpp 128gfc-qsfp28 infiniband-sdr infiniband-ddr infiniband-qdr infiniband-fdr10 infiniband-fdr infiniband-edr infiniband-hdr infiniband-ndr infiniband-xdr t1 e1 t3 e3 xdsl cisco-stackwise cisco-stackwise-plus cisco-flexstack cisco-flexstack-plus cisco-stackwise-80 cisco-stackwise-160 cisco-stackwise-320 cisco-stackwise-480 juniper-vcp extreme-summitstack extreme-summitstack-128 extreme-summitstack-256 extreme-summitstack-512 other] Value *string `json:"value"` } @@ -416,7 +416,7 @@ var interfaceTemplateTypeTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["Virtual","Link Aggregation Group (LAG)","100BASE-TX (10/100ME)","1000BASE-T (1GE)","2.5GBASE-T (2.5GE)","5GBASE-T (5GE)","10GBASE-T (10GE)","10GBASE-CX4 (10GE)","GBIC (1GE)","SFP (1GE)","SFP+ (10GE)","XFP (10GE)","XENPAK (10GE)","X2 (10GE)","SFP28 (25GE)","SFP56 (50GE)","QSFP+ (40GE)","QSFP28 (50GE)","CFP (100GE)","CFP2 (100GE)","CFP2 (200GE)","CFP4 (100GE)","Cisco CPAK (100GE)","QSFP28 (100GE)","QSFP56 (200GE)","QSFP-DD (400GE)","OSFP (400GE)","IEEE 802.11a","IEEE 802.11b/g","IEEE 802.11n","IEEE 802.11ac","IEEE 802.11ad","IEEE 802.11ax","IEEE 802.15.1 (Bluetooth)","GSM","CDMA","LTE","OC-3/STM-1","OC-12/STM-4","OC-48/STM-16","OC-192/STM-64","OC-768/STM-256","OC-1920/STM-640","OC-3840/STM-1234","SFP (1GFC)","SFP (2GFC)","SFP (4GFC)","SFP+ (8GFC)","SFP+ (16GFC)","SFP28 (32GFC)","QSFP+ (64GFC)","QSFP28 (128GFC)","SDR (2 Gbps)","DDR (4 Gbps)","QDR (8 Gbps)","FDR10 (10 Gbps)","FDR (13.5 Gbps)","EDR (25 Gbps)","HDR (50 Gbps)","NDR (100 Gbps)","XDR (250 Gbps)","T1 (1.544 Mbps)","E1 (2.048 Mbps)","T3 (45 Mbps)","E3 (34 Mbps)","xDSL","Cisco StackWise","Cisco StackWise Plus","Cisco FlexStack","Cisco FlexStack Plus","Juniper VCP","Extreme SummitStack","Extreme SummitStack-128","Extreme SummitStack-256","Extreme SummitStack-512","Other"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["Virtual","Bridge","Link Aggregation Group (LAG)","100BASE-TX (10/100ME)","1000BASE-T (1GE)","2.5GBASE-T (2.5GE)","5GBASE-T (5GE)","10GBASE-T (10GE)","10GBASE-CX4 (10GE)","GBIC (1GE)","SFP (1GE)","SFP+ (10GE)","XFP (10GE)","XENPAK (10GE)","X2 (10GE)","SFP28 (25GE)","SFP56 (50GE)","QSFP+ (40GE)","QSFP28 (50GE)","CFP (100GE)","CFP2 (100GE)","CFP2 (200GE)","CFP4 (100GE)","Cisco CPAK (100GE)","QSFP28 (100GE)","QSFP56 (200GE)","QSFP-DD (400GE)","OSFP (400GE)","IEEE 802.11a","IEEE 802.11b/g","IEEE 802.11n","IEEE 802.11ac","IEEE 802.11ad","IEEE 802.11ax","IEEE 802.15.1 (Bluetooth)","GSM","CDMA","LTE","OC-3/STM-1","OC-12/STM-4","OC-48/STM-16","OC-192/STM-64","OC-768/STM-256","OC-1920/STM-640","OC-3840/STM-1234","SFP (1GFC)","SFP (2GFC)","SFP (4GFC)","SFP+ (8GFC)","SFP+ (16GFC)","SFP28 (32GFC)","QSFP+ (64GFC)","QSFP28 (128GFC)","SDR (2 Gbps)","DDR (4 Gbps)","QDR (8 Gbps)","FDR10 (10 Gbps)","FDR (13.5 Gbps)","EDR (25 Gbps)","HDR (50 Gbps)","NDR (100 Gbps)","XDR (250 Gbps)","T1 (1.544 Mbps)","E1 (2.048 Mbps)","T3 (45 Mbps)","E3 (34 Mbps)","xDSL","Cisco StackWise","Cisco StackWise Plus","Cisco FlexStack","Cisco FlexStack Plus","Cisco StackWise-80","Cisco StackWise-160","Cisco StackWise-320","Cisco StackWise-480","Juniper VCP","Extreme SummitStack","Extreme SummitStack-128","Extreme SummitStack-256","Extreme SummitStack-512","Other"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -429,6 +429,9 @@ const ( // InterfaceTemplateTypeLabelVirtual captures enum value "Virtual" InterfaceTemplateTypeLabelVirtual string = "Virtual" + // InterfaceTemplateTypeLabelBridge captures enum value "Bridge" + InterfaceTemplateTypeLabelBridge string = "Bridge" + // InterfaceTemplateTypeLabelLinkAggregationGroupLAG captures enum value "Link Aggregation Group (LAG)" InterfaceTemplateTypeLabelLinkAggregationGroupLAG string = "Link Aggregation Group (LAG)" @@ -636,6 +639,18 @@ const ( // InterfaceTemplateTypeLabelCiscoFlexStackPlus captures enum value "Cisco FlexStack Plus" InterfaceTemplateTypeLabelCiscoFlexStackPlus string = "Cisco FlexStack Plus" + // InterfaceTemplateTypeLabelCiscoStackWiseDash80 captures enum value "Cisco StackWise-80" + InterfaceTemplateTypeLabelCiscoStackWiseDash80 string = "Cisco StackWise-80" + + // InterfaceTemplateTypeLabelCiscoStackWiseDash160 captures enum value "Cisco StackWise-160" + InterfaceTemplateTypeLabelCiscoStackWiseDash160 string = "Cisco StackWise-160" + + // InterfaceTemplateTypeLabelCiscoStackWiseDash320 captures enum value "Cisco StackWise-320" + InterfaceTemplateTypeLabelCiscoStackWiseDash320 string = "Cisco StackWise-320" + + // InterfaceTemplateTypeLabelCiscoStackWiseDash480 captures enum value "Cisco StackWise-480" + InterfaceTemplateTypeLabelCiscoStackWiseDash480 string = "Cisco StackWise-480" + // InterfaceTemplateTypeLabelJuniperVCP captures enum value "Juniper VCP" InterfaceTemplateTypeLabelJuniperVCP string = "Juniper VCP" @@ -681,7 +696,7 @@ var interfaceTemplateTypeTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["virtual","lag","100base-tx","1000base-t","2.5gbase-t","5gbase-t","10gbase-t","10gbase-cx4","1000base-x-gbic","1000base-x-sfp","10gbase-x-sfpp","10gbase-x-xfp","10gbase-x-xenpak","10gbase-x-x2","25gbase-x-sfp28","50gbase-x-sfp56","40gbase-x-qsfpp","50gbase-x-sfp28","100gbase-x-cfp","100gbase-x-cfp2","200gbase-x-cfp2","100gbase-x-cfp4","100gbase-x-cpak","100gbase-x-qsfp28","200gbase-x-qsfp56","400gbase-x-qsfpdd","400gbase-x-osfp","ieee802.11a","ieee802.11g","ieee802.11n","ieee802.11ac","ieee802.11ad","ieee802.11ax","ieee802.15.1","gsm","cdma","lte","sonet-oc3","sonet-oc12","sonet-oc48","sonet-oc192","sonet-oc768","sonet-oc1920","sonet-oc3840","1gfc-sfp","2gfc-sfp","4gfc-sfp","8gfc-sfpp","16gfc-sfpp","32gfc-sfp28","64gfc-qsfpp","128gfc-sfp28","infiniband-sdr","infiniband-ddr","infiniband-qdr","infiniband-fdr10","infiniband-fdr","infiniband-edr","infiniband-hdr","infiniband-ndr","infiniband-xdr","t1","e1","t3","e3","xdsl","cisco-stackwise","cisco-stackwise-plus","cisco-flexstack","cisco-flexstack-plus","juniper-vcp","extreme-summitstack","extreme-summitstack-128","extreme-summitstack-256","extreme-summitstack-512","other"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["virtual","bridge","lag","100base-tx","1000base-t","2.5gbase-t","5gbase-t","10gbase-t","10gbase-cx4","1000base-x-gbic","1000base-x-sfp","10gbase-x-sfpp","10gbase-x-xfp","10gbase-x-xenpak","10gbase-x-x2","25gbase-x-sfp28","50gbase-x-sfp56","40gbase-x-qsfpp","50gbase-x-sfp28","100gbase-x-cfp","100gbase-x-cfp2","200gbase-x-cfp2","100gbase-x-cfp4","100gbase-x-cpak","100gbase-x-qsfp28","200gbase-x-qsfp56","400gbase-x-qsfpdd","400gbase-x-osfp","ieee802.11a","ieee802.11g","ieee802.11n","ieee802.11ac","ieee802.11ad","ieee802.11ax","ieee802.15.1","gsm","cdma","lte","sonet-oc3","sonet-oc12","sonet-oc48","sonet-oc192","sonet-oc768","sonet-oc1920","sonet-oc3840","1gfc-sfp","2gfc-sfp","4gfc-sfp","8gfc-sfpp","16gfc-sfpp","32gfc-sfp28","64gfc-qsfpp","128gfc-qsfp28","infiniband-sdr","infiniband-ddr","infiniband-qdr","infiniband-fdr10","infiniband-fdr","infiniband-edr","infiniband-hdr","infiniband-ndr","infiniband-xdr","t1","e1","t3","e3","xdsl","cisco-stackwise","cisco-stackwise-plus","cisco-flexstack","cisco-flexstack-plus","cisco-stackwise-80","cisco-stackwise-160","cisco-stackwise-320","cisco-stackwise-480","juniper-vcp","extreme-summitstack","extreme-summitstack-128","extreme-summitstack-256","extreme-summitstack-512","other"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -694,6 +709,9 @@ const ( // InterfaceTemplateTypeValueVirtual captures enum value "virtual" InterfaceTemplateTypeValueVirtual string = "virtual" + // InterfaceTemplateTypeValueBridge captures enum value "bridge" + InterfaceTemplateTypeValueBridge string = "bridge" + // InterfaceTemplateTypeValueLag captures enum value "lag" InterfaceTemplateTypeValueLag string = "lag" @@ -844,8 +862,8 @@ const ( // InterfaceTemplateTypeValueNr64gfcDashQsfpp captures enum value "64gfc-qsfpp" InterfaceTemplateTypeValueNr64gfcDashQsfpp string = "64gfc-qsfpp" - // InterfaceTemplateTypeValueNr128gfcDashSfp28 captures enum value "128gfc-sfp28" - InterfaceTemplateTypeValueNr128gfcDashSfp28 string = "128gfc-sfp28" + // InterfaceTemplateTypeValueNr128gfcDashQsfp28 captures enum value "128gfc-qsfp28" + InterfaceTemplateTypeValueNr128gfcDashQsfp28 string = "128gfc-qsfp28" // InterfaceTemplateTypeValueInfinibandDashSdr captures enum value "infiniband-sdr" InterfaceTemplateTypeValueInfinibandDashSdr string = "infiniband-sdr" @@ -901,6 +919,18 @@ const ( // InterfaceTemplateTypeValueCiscoDashFlexstackDashPlus captures enum value "cisco-flexstack-plus" InterfaceTemplateTypeValueCiscoDashFlexstackDashPlus string = "cisco-flexstack-plus" + // InterfaceTemplateTypeValueCiscoDashStackwiseDash80 captures enum value "cisco-stackwise-80" + InterfaceTemplateTypeValueCiscoDashStackwiseDash80 string = "cisco-stackwise-80" + + // InterfaceTemplateTypeValueCiscoDashStackwiseDash160 captures enum value "cisco-stackwise-160" + InterfaceTemplateTypeValueCiscoDashStackwiseDash160 string = "cisco-stackwise-160" + + // InterfaceTemplateTypeValueCiscoDashStackwiseDash320 captures enum value "cisco-stackwise-320" + InterfaceTemplateTypeValueCiscoDashStackwiseDash320 string = "cisco-stackwise-320" + + // InterfaceTemplateTypeValueCiscoDashStackwiseDash480 captures enum value "cisco-stackwise-480" + InterfaceTemplateTypeValueCiscoDashStackwiseDash480 string = "cisco-stackwise-480" + // InterfaceTemplateTypeValueJuniperDashVcp captures enum value "juniper-vcp" InterfaceTemplateTypeValueJuniperDashVcp string = "juniper-vcp" diff --git a/netbox/models/ip_address.go b/netbox/models/ip_address.go index 2a7ca96e..33631934 100644 --- a/netbox/models/ip_address.go +++ b/netbox/models/ip_address.go @@ -74,7 +74,7 @@ type IPAddress struct { // // Hostname or FQDN (not case-sensitive) // Max Length: 255 - // Pattern: ^[0-9A-Za-z._-]+$ + // Pattern: ^([0-9A-Za-z_-]+|\*)(\.[0-9A-Za-z_-]+)*\.?$ DNSName string `json:"dns_name,omitempty"` // family @@ -244,7 +244,7 @@ func (m *IPAddress) validateDNSName(formats strfmt.Registry) error { return err } - if err := validate.Pattern("dns_name", "body", m.DNSName, `^[0-9A-Za-z._-]+$`); err != nil { + if err := validate.Pattern("dns_name", "body", m.DNSName, `^([0-9A-Za-z_-]+|\*)(\.[0-9A-Za-z_-]+)*\.?$`); err != nil { return err } diff --git a/netbox/models/location.go b/netbox/models/location.go index 0fc96848..6495ad2f 100644 --- a/netbox/models/location.go +++ b/netbox/models/location.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -91,6 +92,12 @@ type Location struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + + // tenant + Tenant *NestedTenant `json:"tenant,omitempty"` + // Url // Read Only: true // Format: uri @@ -129,6 +136,14 @@ func (m *Location) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTenant(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -252,6 +267,51 @@ func (m *Location) validateSlug(formats strfmt.Registry) error { return nil } +func (m *Location) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *Location) validateTenant(formats strfmt.Registry) error { + if swag.IsZero(m.Tenant) { // not required + return nil + } + + if m.Tenant != nil { + if err := m.Tenant.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenant") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenant") + } + return err + } + } + + return nil +} + func (m *Location) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -304,6 +364,14 @@ func (m *Location) ContextValidate(ctx context.Context, formats strfmt.Registry) res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTenant(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -409,6 +477,42 @@ func (m *Location) contextValidateSite(ctx context.Context, formats strfmt.Regis return nil } +func (m *Location) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *Location) contextValidateTenant(ctx context.Context, formats strfmt.Registry) error { + + if m.Tenant != nil { + if err := m.Tenant.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tenant") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tenant") + } + return err + } + } + + return nil +} + func (m *Location) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/manufacturer.go b/netbox/models/manufacturer.go index d516bc6c..37c818f5 100644 --- a/netbox/models/manufacturer.go +++ b/netbox/models/manufacturer.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -84,6 +85,9 @@ type Manufacturer struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -114,6 +118,10 @@ func (m *Manufacturer) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -198,6 +206,32 @@ func (m *Manufacturer) validateSlug(formats strfmt.Registry) error { return nil } +func (m *Manufacturer) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *Manufacturer) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -242,6 +276,10 @@ func (m *Manufacturer) ContextValidate(ctx context.Context, formats strfmt.Regis res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -315,6 +353,26 @@ func (m *Manufacturer) contextValidatePlatformCount(ctx context.Context, formats return nil } +func (m *Manufacturer) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *Manufacturer) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/nested_a_s_n.go b/netbox/models/nested_a_s_n.go new file mode 100644 index 00000000..7900493b --- /dev/null +++ b/netbox/models/nested_a_s_n.go @@ -0,0 +1,171 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// NestedASN nested a s n +// +// swagger:model NestedASN +type NestedASN struct { + + // ASN + // + // 32-bit autonomous system number + // Required: true + // Maximum: 4.294967295e+09 + // Minimum: 1 + Asn *int64 `json:"asn"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this nested a s n +func (m *NestedASN) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAsn(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedASN) validateAsn(formats strfmt.Registry) error { + + if err := validate.Required("asn", "body", m.Asn); err != nil { + return err + } + + if err := validate.MinimumInt("asn", "body", *m.Asn, 1, false); err != nil { + return err + } + + if err := validate.MaximumInt("asn", "body", *m.Asn, 4.294967295e+09, false); err != nil { + return err + } + + return nil +} + +func (m *NestedASN) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this nested a s n based on the context it is used +func (m *NestedASN) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedASN) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *NestedASN) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *NestedASN) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *NestedASN) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *NestedASN) UnmarshalBinary(b []byte) error { + var res NestedASN + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/nested_contact.go b/netbox/models/nested_contact.go new file mode 100644 index 00000000..1f6e483a --- /dev/null +++ b/netbox/models/nested_contact.go @@ -0,0 +1,169 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// NestedContact nested contact +// +// swagger:model NestedContact +type NestedContact struct { + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Name + // Required: true + // Max Length: 100 + // Min Length: 1 + Name *string `json:"name"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this nested contact +func (m *NestedContact) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateName(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedContact) validateName(formats strfmt.Registry) error { + + if err := validate.Required("name", "body", m.Name); err != nil { + return err + } + + if err := validate.MinLength("name", "body", *m.Name, 1); err != nil { + return err + } + + if err := validate.MaxLength("name", "body", *m.Name, 100); err != nil { + return err + } + + return nil +} + +func (m *NestedContact) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this nested contact based on the context it is used +func (m *NestedContact) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedContact) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *NestedContact) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *NestedContact) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *NestedContact) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *NestedContact) UnmarshalBinary(b []byte) error { + var res NestedContact + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/nested_contact_group.go b/netbox/models/nested_contact_group.go new file mode 100644 index 00000000..de754c81 --- /dev/null +++ b/netbox/models/nested_contact_group.go @@ -0,0 +1,235 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// NestedContactGroup nested contact group +// +// swagger:model NestedContactGroup +type NestedContactGroup struct { + + // depth + // Read Only: true + Depth int64 `json:"_depth,omitempty"` + + // Contact count + // Read Only: true + ContactCount int64 `json:"contact_count,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Name + // Required: true + // Max Length: 100 + // Min Length: 1 + Name *string `json:"name"` + + // Slug + // Required: true + // Max Length: 100 + // Min Length: 1 + // Pattern: ^[-a-zA-Z0-9_]+$ + Slug *string `json:"slug"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this nested contact group +func (m *NestedContactGroup) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateName(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSlug(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedContactGroup) validateName(formats strfmt.Registry) error { + + if err := validate.Required("name", "body", m.Name); err != nil { + return err + } + + if err := validate.MinLength("name", "body", *m.Name, 1); err != nil { + return err + } + + if err := validate.MaxLength("name", "body", *m.Name, 100); err != nil { + return err + } + + return nil +} + +func (m *NestedContactGroup) validateSlug(formats strfmt.Registry) error { + + if err := validate.Required("slug", "body", m.Slug); err != nil { + return err + } + + if err := validate.MinLength("slug", "body", *m.Slug, 1); err != nil { + return err + } + + if err := validate.MaxLength("slug", "body", *m.Slug, 100); err != nil { + return err + } + + if err := validate.Pattern("slug", "body", *m.Slug, `^[-a-zA-Z0-9_]+$`); err != nil { + return err + } + + return nil +} + +func (m *NestedContactGroup) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this nested contact group based on the context it is used +func (m *NestedContactGroup) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDepth(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateContactCount(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedContactGroup) contextValidateDepth(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "_depth", "body", int64(m.Depth)); err != nil { + return err + } + + return nil +} + +func (m *NestedContactGroup) contextValidateContactCount(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "contact_count", "body", int64(m.ContactCount)); err != nil { + return err + } + + return nil +} + +func (m *NestedContactGroup) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *NestedContactGroup) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *NestedContactGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *NestedContactGroup) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *NestedContactGroup) UnmarshalBinary(b []byte) error { + var res NestedContactGroup + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/nested_contact_role.go b/netbox/models/nested_contact_role.go new file mode 100644 index 00000000..35ce13a5 --- /dev/null +++ b/netbox/models/nested_contact_role.go @@ -0,0 +1,201 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// NestedContactRole nested contact role +// +// swagger:model NestedContactRole +type NestedContactRole struct { + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Name + // Required: true + // Max Length: 100 + // Min Length: 1 + Name *string `json:"name"` + + // Slug + // Required: true + // Max Length: 100 + // Min Length: 1 + // Pattern: ^[-a-zA-Z0-9_]+$ + Slug *string `json:"slug"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this nested contact role +func (m *NestedContactRole) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateName(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSlug(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedContactRole) validateName(formats strfmt.Registry) error { + + if err := validate.Required("name", "body", m.Name); err != nil { + return err + } + + if err := validate.MinLength("name", "body", *m.Name, 1); err != nil { + return err + } + + if err := validate.MaxLength("name", "body", *m.Name, 100); err != nil { + return err + } + + return nil +} + +func (m *NestedContactRole) validateSlug(formats strfmt.Registry) error { + + if err := validate.Required("slug", "body", m.Slug); err != nil { + return err + } + + if err := validate.MinLength("slug", "body", *m.Slug, 1); err != nil { + return err + } + + if err := validate.MaxLength("slug", "body", *m.Slug, 100); err != nil { + return err + } + + if err := validate.Pattern("slug", "body", *m.Slug, `^[-a-zA-Z0-9_]+$`); err != nil { + return err + } + + return nil +} + +func (m *NestedContactRole) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this nested contact role based on the context it is used +func (m *NestedContactRole) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedContactRole) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *NestedContactRole) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *NestedContactRole) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *NestedContactRole) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *NestedContactRole) UnmarshalBinary(b []byte) error { + var res NestedContactRole + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/nested_f_h_r_p_group.go b/netbox/models/nested_f_h_r_p_group.go new file mode 100644 index 00000000..16cbd6bf --- /dev/null +++ b/netbox/models/nested_f_h_r_p_group.go @@ -0,0 +1,237 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "encoding/json" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// NestedFHRPGroup nested f h r p group +// +// swagger:model NestedFHRPGroup +type NestedFHRPGroup struct { + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Group ID + // Required: true + // Maximum: 32767 + // Minimum: 0 + GroupID *int64 `json:"group_id"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Protocol + // Required: true + // Enum: [vrrp2 vrrp3 carp clusterxl hsrp glbp other] + Protocol *string `json:"protocol"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this nested f h r p group +func (m *NestedFHRPGroup) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateGroupID(formats); err != nil { + res = append(res, err) + } + + if err := m.validateProtocol(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedFHRPGroup) validateGroupID(formats strfmt.Registry) error { + + if err := validate.Required("group_id", "body", m.GroupID); err != nil { + return err + } + + if err := validate.MinimumInt("group_id", "body", *m.GroupID, 0, false); err != nil { + return err + } + + if err := validate.MaximumInt("group_id", "body", *m.GroupID, 32767, false); err != nil { + return err + } + + return nil +} + +var nestedFHRPGroupTypeProtocolPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["vrrp2","vrrp3","carp","clusterxl","hsrp","glbp","other"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + nestedFHRPGroupTypeProtocolPropEnum = append(nestedFHRPGroupTypeProtocolPropEnum, v) + } +} + +const ( + + // NestedFHRPGroupProtocolVrrp2 captures enum value "vrrp2" + NestedFHRPGroupProtocolVrrp2 string = "vrrp2" + + // NestedFHRPGroupProtocolVrrp3 captures enum value "vrrp3" + NestedFHRPGroupProtocolVrrp3 string = "vrrp3" + + // NestedFHRPGroupProtocolCarp captures enum value "carp" + NestedFHRPGroupProtocolCarp string = "carp" + + // NestedFHRPGroupProtocolClusterxl captures enum value "clusterxl" + NestedFHRPGroupProtocolClusterxl string = "clusterxl" + + // NestedFHRPGroupProtocolHsrp captures enum value "hsrp" + NestedFHRPGroupProtocolHsrp string = "hsrp" + + // NestedFHRPGroupProtocolGlbp captures enum value "glbp" + NestedFHRPGroupProtocolGlbp string = "glbp" + + // NestedFHRPGroupProtocolOther captures enum value "other" + NestedFHRPGroupProtocolOther string = "other" +) + +// prop value enum +func (m *NestedFHRPGroup) validateProtocolEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, nestedFHRPGroupTypeProtocolPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *NestedFHRPGroup) validateProtocol(formats strfmt.Registry) error { + + if err := validate.Required("protocol", "body", m.Protocol); err != nil { + return err + } + + // value enum + if err := m.validateProtocolEnum("protocol", "body", *m.Protocol); err != nil { + return err + } + + return nil +} + +func (m *NestedFHRPGroup) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this nested f h r p group based on the context it is used +func (m *NestedFHRPGroup) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedFHRPGroup) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *NestedFHRPGroup) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *NestedFHRPGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *NestedFHRPGroup) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *NestedFHRPGroup) UnmarshalBinary(b []byte) error { + var res NestedFHRPGroup + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/nested_wireless_l_a_n.go b/netbox/models/nested_wireless_l_a_n.go new file mode 100644 index 00000000..59117f7f --- /dev/null +++ b/netbox/models/nested_wireless_l_a_n.go @@ -0,0 +1,169 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// NestedWirelessLAN nested wireless l a n +// +// swagger:model NestedWirelessLAN +type NestedWirelessLAN struct { + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // SSID + // Required: true + // Max Length: 32 + // Min Length: 1 + Ssid *string `json:"ssid"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this nested wireless l a n +func (m *NestedWirelessLAN) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateSsid(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedWirelessLAN) validateSsid(formats strfmt.Registry) error { + + if err := validate.Required("ssid", "body", m.Ssid); err != nil { + return err + } + + if err := validate.MinLength("ssid", "body", *m.Ssid, 1); err != nil { + return err + } + + if err := validate.MaxLength("ssid", "body", *m.Ssid, 32); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLAN) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this nested wireless l a n based on the context it is used +func (m *NestedWirelessLAN) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedWirelessLAN) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLAN) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLAN) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *NestedWirelessLAN) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *NestedWirelessLAN) UnmarshalBinary(b []byte) error { + var res NestedWirelessLAN + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/nested_wireless_l_a_n_group.go b/netbox/models/nested_wireless_l_a_n_group.go new file mode 100644 index 00000000..684e8811 --- /dev/null +++ b/netbox/models/nested_wireless_l_a_n_group.go @@ -0,0 +1,235 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// NestedWirelessLANGroup nested wireless l a n group +// +// swagger:model NestedWirelessLANGroup +type NestedWirelessLANGroup struct { + + // depth + // Read Only: true + Depth int64 `json:"_depth,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Name + // Required: true + // Max Length: 100 + // Min Length: 1 + Name *string `json:"name"` + + // Slug + // Required: true + // Max Length: 100 + // Min Length: 1 + // Pattern: ^[-a-zA-Z0-9_]+$ + Slug *string `json:"slug"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` + + // Wirelesslan count + // Read Only: true + WirelesslanCount int64 `json:"wirelesslan_count,omitempty"` +} + +// Validate validates this nested wireless l a n group +func (m *NestedWirelessLANGroup) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateName(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSlug(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedWirelessLANGroup) validateName(formats strfmt.Registry) error { + + if err := validate.Required("name", "body", m.Name); err != nil { + return err + } + + if err := validate.MinLength("name", "body", *m.Name, 1); err != nil { + return err + } + + if err := validate.MaxLength("name", "body", *m.Name, 100); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLANGroup) validateSlug(formats strfmt.Registry) error { + + if err := validate.Required("slug", "body", m.Slug); err != nil { + return err + } + + if err := validate.MinLength("slug", "body", *m.Slug, 1); err != nil { + return err + } + + if err := validate.MaxLength("slug", "body", *m.Slug, 100); err != nil { + return err + } + + if err := validate.Pattern("slug", "body", *m.Slug, `^[-a-zA-Z0-9_]+$`); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLANGroup) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this nested wireless l a n group based on the context it is used +func (m *NestedWirelessLANGroup) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDepth(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateWirelesslanCount(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedWirelessLANGroup) contextValidateDepth(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "_depth", "body", int64(m.Depth)); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLANGroup) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLANGroup) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLANGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLANGroup) contextValidateWirelesslanCount(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "wirelesslan_count", "body", int64(m.WirelesslanCount)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *NestedWirelessLANGroup) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *NestedWirelessLANGroup) UnmarshalBinary(b []byte) error { + var res NestedWirelessLANGroup + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/nested_wireless_link.go b/netbox/models/nested_wireless_link.go new file mode 100644 index 00000000..e5ca305b --- /dev/null +++ b/netbox/models/nested_wireless_link.go @@ -0,0 +1,162 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// NestedWirelessLink nested wireless link +// +// swagger:model NestedWirelessLink +type NestedWirelessLink struct { + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // SSID + // Max Length: 32 + Ssid string `json:"ssid,omitempty"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this nested wireless link +func (m *NestedWirelessLink) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateSsid(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedWirelessLink) validateSsid(formats strfmt.Registry) error { + if swag.IsZero(m.Ssid) { // not required + return nil + } + + if err := validate.MaxLength("ssid", "body", m.Ssid, 32); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLink) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this nested wireless link based on the context it is used +func (m *NestedWirelessLink) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *NestedWirelessLink) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLink) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *NestedWirelessLink) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *NestedWirelessLink) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *NestedWirelessLink) UnmarshalBinary(b []byte) error { + var res NestedWirelessLink + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/platform.go b/netbox/models/platform.go index 4b2960b9..cf023c3a 100644 --- a/netbox/models/platform.go +++ b/netbox/models/platform.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -90,6 +91,9 @@ type Platform struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -132,6 +136,10 @@ func (m *Platform) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -247,6 +255,32 @@ func (m *Platform) validateSlug(formats strfmt.Registry) error { return nil } +func (m *Platform) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *Platform) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -287,6 +321,10 @@ func (m *Platform) ContextValidate(ctx context.Context, formats strfmt.Registry) res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -362,6 +400,26 @@ func (m *Platform) contextValidateManufacturer(ctx context.Context, formats strf return nil } +func (m *Platform) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *Platform) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/power_feed.go b/netbox/models/power_feed.go index 637eae90..bc693a10 100644 --- a/netbox/models/power_feed.go +++ b/netbox/models/power_feed.go @@ -48,18 +48,6 @@ type PowerFeed struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Comments Comments string `json:"comments,omitempty"` @@ -100,6 +88,18 @@ type PowerFeed struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -494,14 +494,6 @@ func (m *PowerFeed) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { - res = append(res, err) - } - if err := m.contextValidateConnectedEndpoint(ctx, formats); err != nil { res = append(res, err) } @@ -530,6 +522,14 @@ func (m *PowerFeed) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidatePhase(ctx, formats); err != nil { res = append(res, err) } @@ -593,20 +593,6 @@ func (m *PowerFeed) contextValidateCable(ctx context.Context, formats strfmt.Reg return nil } -func (m *PowerFeed) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *PowerFeed) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *PowerFeed) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil @@ -666,6 +652,20 @@ func (m *PowerFeed) contextValidateLastUpdated(ctx context.Context, formats strf return nil } +func (m *PowerFeed) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *PowerFeed) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *PowerFeed) contextValidatePhase(ctx context.Context, formats strfmt.Registry) error { if m.Phase != nil { diff --git a/netbox/models/power_outlet.go b/netbox/models/power_outlet.go index f1128cef..16f00211 100644 --- a/netbox/models/power_outlet.go +++ b/netbox/models/power_outlet.go @@ -43,18 +43,6 @@ type PowerOutlet struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Connected endpoint // // @@ -109,6 +97,18 @@ type PowerOutlet struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -404,14 +404,6 @@ func (m *PowerOutlet) ContextValidate(ctx context.Context, formats strfmt.Regist res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { - res = append(res, err) - } - if err := m.contextValidateConnectedEndpoint(ctx, formats); err != nil { res = append(res, err) } @@ -448,6 +440,14 @@ func (m *PowerOutlet) ContextValidate(ctx context.Context, formats strfmt.Regist res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidatePowerPort(ctx, formats); err != nil { res = append(res, err) } @@ -495,20 +495,6 @@ func (m *PowerOutlet) contextValidateCable(ctx context.Context, formats strfmt.R return nil } -func (m *PowerOutlet) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *PowerOutlet) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *PowerOutlet) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil @@ -600,6 +586,20 @@ func (m *PowerOutlet) contextValidateLastUpdated(ctx context.Context, formats st return nil } +func (m *PowerOutlet) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *PowerOutlet) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *PowerOutlet) contextValidatePowerPort(ctx context.Context, formats strfmt.Registry) error { if m.PowerPort != nil { @@ -835,12 +835,12 @@ type PowerOutletType struct { // label // Required: true - // Enum: [C5 C7 C13 C15 C19 C21 P+N+E 4H P+N+E 6H P+N+E 9H 2P+E 4H 2P+E 6H 2P+E 9H 3P+E 4H 3P+E 6H 3P+E 9H 3P+N+E 4H 3P+N+E 6H 3P+N+E 9H NEMA 1-15R NEMA 5-15R NEMA 5-20R NEMA 5-30R NEMA 5-50R NEMA 6-15R NEMA 6-20R NEMA 6-30R NEMA 6-50R NEMA 10-30R NEMA 10-50R NEMA 14-20R NEMA 14-30R NEMA 14-50R NEMA 14-60R NEMA 15-15R NEMA 15-20R NEMA 15-30R NEMA 15-50R NEMA 15-60R NEMA L1-15R NEMA L5-15R NEMA L5-20R NEMA L5-30R NEMA L5-50R NEMA L6-15R NEMA L6-20R NEMA L6-30R NEMA L6-50R NEMA L10-30R NEMA L14-20R NEMA L14-30R NEMA L14-50R NEMA L14-60R NEMA L15-20R NEMA L15-30R NEMA L15-50R NEMA L15-60R NEMA L21-20R NEMA L21-30R CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ITA Type E (CEE 7/5) ITA Type F (CEE 7/3) ITA Type G (BS 1363) ITA Type H ITA Type I ITA Type J ITA Type K ITA Type L (CEI 23-50) ITA Type M (BS 546) ITA Type N ITA Type O USB Type A USB Micro B USB Type C DC Terminal HDOT Cx Saf-D-Grid Hardwired] + // Enum: [C5 C7 C13 C15 C19 C21 P+N+E 4H P+N+E 6H P+N+E 9H 2P+E 4H 2P+E 6H 2P+E 9H 3P+E 4H 3P+E 6H 3P+E 9H 3P+N+E 4H 3P+N+E 6H 3P+N+E 9H NEMA 1-15R NEMA 5-15R NEMA 5-20R NEMA 5-30R NEMA 5-50R NEMA 6-15R NEMA 6-20R NEMA 6-30R NEMA 6-50R NEMA 10-30R NEMA 10-50R NEMA 14-20R NEMA 14-30R NEMA 14-50R NEMA 14-60R NEMA 15-15R NEMA 15-20R NEMA 15-30R NEMA 15-50R NEMA 15-60R NEMA L1-15R NEMA L5-15R NEMA L5-20R NEMA L5-30R NEMA L5-50R NEMA L6-15R NEMA L6-20R NEMA L6-30R NEMA L6-50R NEMA L10-30R NEMA L14-20R NEMA L14-30R NEMA L14-50R NEMA L14-60R NEMA L15-20R NEMA L15-30R NEMA L15-50R NEMA L15-60R NEMA L21-20R NEMA L21-30R NEMA L22-30R CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ITA Type E (CEE 7/5) ITA Type F (CEE 7/3) ITA Type G (BS 1363) ITA Type H ITA Type I ITA Type J ITA Type K ITA Type L (CEI 23-50) ITA Type M (BS 546) ITA Type N ITA Type O ITA Multistandard USB Type A USB Micro B USB Type C DC Terminal HDOT Cx Saf-D-Grid Hardwired] Label *string `json:"label"` // value // Required: true - // Enum: [iec-60320-c5 iec-60320-c7 iec-60320-c13 iec-60320-c15 iec-60320-c19 iec-60320-c21 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15r nema-5-15r nema-5-20r nema-5-30r nema-5-50r nema-6-15r nema-6-20r nema-6-30r nema-6-50r nema-10-30r nema-10-50r nema-14-20r nema-14-30r nema-14-50r nema-14-60r nema-15-15r nema-15-20r nema-15-30r nema-15-50r nema-15-60r nema-l1-15r nema-l5-15r nema-l5-20r nema-l5-30r nema-l5-50r nema-l6-15r nema-l6-20r nema-l6-30r nema-l6-50r nema-l10-30r nema-l14-20r nema-l14-30r nema-l14-50r nema-l14-60r nema-l15-20r nema-l15-30r nema-l15-50r nema-l15-60r nema-l21-20r nema-l21-30r CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ita-e ita-f ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-micro-b usb-c dc-terminal hdot-cx saf-d-grid hardwired] + // Enum: [iec-60320-c5 iec-60320-c7 iec-60320-c13 iec-60320-c15 iec-60320-c19 iec-60320-c21 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15r nema-5-15r nema-5-20r nema-5-30r nema-5-50r nema-6-15r nema-6-20r nema-6-30r nema-6-50r nema-10-30r nema-10-50r nema-14-20r nema-14-30r nema-14-50r nema-14-60r nema-15-15r nema-15-20r nema-15-30r nema-15-50r nema-15-60r nema-l1-15r nema-l5-15r nema-l5-20r nema-l5-30r nema-l5-50r nema-l6-15r nema-l6-20r nema-l6-30r nema-l6-50r nema-l10-30r nema-l14-20r nema-l14-30r nema-l14-50r nema-l14-60r nema-l15-20r nema-l15-30r nema-l15-50r nema-l15-60r nema-l21-20r nema-l21-30r nema-l22-30r CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ita-e ita-f ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o ita-multistandard usb-a usb-micro-b usb-c dc-terminal hdot-cx saf-d-grid hardwired] Value *string `json:"value"` } @@ -866,7 +866,7 @@ var powerOutletTypeTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["C5","C7","C13","C15","C19","C21","P+N+E 4H","P+N+E 6H","P+N+E 9H","2P+E 4H","2P+E 6H","2P+E 9H","3P+E 4H","3P+E 6H","3P+E 9H","3P+N+E 4H","3P+N+E 6H","3P+N+E 9H","NEMA 1-15R","NEMA 5-15R","NEMA 5-20R","NEMA 5-30R","NEMA 5-50R","NEMA 6-15R","NEMA 6-20R","NEMA 6-30R","NEMA 6-50R","NEMA 10-30R","NEMA 10-50R","NEMA 14-20R","NEMA 14-30R","NEMA 14-50R","NEMA 14-60R","NEMA 15-15R","NEMA 15-20R","NEMA 15-30R","NEMA 15-50R","NEMA 15-60R","NEMA L1-15R","NEMA L5-15R","NEMA L5-20R","NEMA L5-30R","NEMA L5-50R","NEMA L6-15R","NEMA L6-20R","NEMA L6-30R","NEMA L6-50R","NEMA L10-30R","NEMA L14-20R","NEMA L14-30R","NEMA L14-50R","NEMA L14-60R","NEMA L15-20R","NEMA L15-30R","NEMA L15-50R","NEMA L15-60R","NEMA L21-20R","NEMA L21-30R","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ITA Type E (CEE 7/5)","ITA Type F (CEE 7/3)","ITA Type G (BS 1363)","ITA Type H","ITA Type I","ITA Type J","ITA Type K","ITA Type L (CEI 23-50)","ITA Type M (BS 546)","ITA Type N","ITA Type O","USB Type A","USB Micro B","USB Type C","DC Terminal","HDOT Cx","Saf-D-Grid","Hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["C5","C7","C13","C15","C19","C21","P+N+E 4H","P+N+E 6H","P+N+E 9H","2P+E 4H","2P+E 6H","2P+E 9H","3P+E 4H","3P+E 6H","3P+E 9H","3P+N+E 4H","3P+N+E 6H","3P+N+E 9H","NEMA 1-15R","NEMA 5-15R","NEMA 5-20R","NEMA 5-30R","NEMA 5-50R","NEMA 6-15R","NEMA 6-20R","NEMA 6-30R","NEMA 6-50R","NEMA 10-30R","NEMA 10-50R","NEMA 14-20R","NEMA 14-30R","NEMA 14-50R","NEMA 14-60R","NEMA 15-15R","NEMA 15-20R","NEMA 15-30R","NEMA 15-50R","NEMA 15-60R","NEMA L1-15R","NEMA L5-15R","NEMA L5-20R","NEMA L5-30R","NEMA L5-50R","NEMA L6-15R","NEMA L6-20R","NEMA L6-30R","NEMA L6-50R","NEMA L10-30R","NEMA L14-20R","NEMA L14-30R","NEMA L14-50R","NEMA L14-60R","NEMA L15-20R","NEMA L15-30R","NEMA L15-50R","NEMA L15-60R","NEMA L21-20R","NEMA L21-30R","NEMA L22-30R","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ITA Type E (CEE 7/5)","ITA Type F (CEE 7/3)","ITA Type G (BS 1363)","ITA Type H","ITA Type I","ITA Type J","ITA Type K","ITA Type L (CEI 23-50)","ITA Type M (BS 546)","ITA Type N","ITA Type O","ITA Multistandard","USB Type A","USB Micro B","USB Type C","DC Terminal","HDOT Cx","Saf-D-Grid","Hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -1050,6 +1050,9 @@ const ( // PowerOutletTypeLabelNEMAL21Dash30R captures enum value "NEMA L21-30R" PowerOutletTypeLabelNEMAL21Dash30R string = "NEMA L21-30R" + // PowerOutletTypeLabelNEMAL22Dash30R captures enum value "NEMA L22-30R" + PowerOutletTypeLabelNEMAL22Dash30R string = "NEMA L22-30R" + // PowerOutletTypeLabelCS6360C captures enum value "CS6360C" PowerOutletTypeLabelCS6360C string = "CS6360C" @@ -1101,6 +1104,9 @@ const ( // PowerOutletTypeLabelITATypeO captures enum value "ITA Type O" PowerOutletTypeLabelITATypeO string = "ITA Type O" + // PowerOutletTypeLabelITAMultistandard captures enum value "ITA Multistandard" + PowerOutletTypeLabelITAMultistandard string = "ITA Multistandard" + // PowerOutletTypeLabelUSBTypeA captures enum value "USB Type A" PowerOutletTypeLabelUSBTypeA string = "USB Type A" @@ -1149,7 +1155,7 @@ var powerOutletTypeTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["iec-60320-c5","iec-60320-c7","iec-60320-c13","iec-60320-c15","iec-60320-c19","iec-60320-c21","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15r","nema-5-15r","nema-5-20r","nema-5-30r","nema-5-50r","nema-6-15r","nema-6-20r","nema-6-30r","nema-6-50r","nema-10-30r","nema-10-50r","nema-14-20r","nema-14-30r","nema-14-50r","nema-14-60r","nema-15-15r","nema-15-20r","nema-15-30r","nema-15-50r","nema-15-60r","nema-l1-15r","nema-l5-15r","nema-l5-20r","nema-l5-30r","nema-l5-50r","nema-l6-15r","nema-l6-20r","nema-l6-30r","nema-l6-50r","nema-l10-30r","nema-l14-20r","nema-l14-30r","nema-l14-50r","nema-l14-60r","nema-l15-20r","nema-l15-30r","nema-l15-50r","nema-l15-60r","nema-l21-20r","nema-l21-30r","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ita-e","ita-f","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-micro-b","usb-c","dc-terminal","hdot-cx","saf-d-grid","hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["iec-60320-c5","iec-60320-c7","iec-60320-c13","iec-60320-c15","iec-60320-c19","iec-60320-c21","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15r","nema-5-15r","nema-5-20r","nema-5-30r","nema-5-50r","nema-6-15r","nema-6-20r","nema-6-30r","nema-6-50r","nema-10-30r","nema-10-50r","nema-14-20r","nema-14-30r","nema-14-50r","nema-14-60r","nema-15-15r","nema-15-20r","nema-15-30r","nema-15-50r","nema-15-60r","nema-l1-15r","nema-l5-15r","nema-l5-20r","nema-l5-30r","nema-l5-50r","nema-l6-15r","nema-l6-20r","nema-l6-30r","nema-l6-50r","nema-l10-30r","nema-l14-20r","nema-l14-30r","nema-l14-50r","nema-l14-60r","nema-l15-20r","nema-l15-30r","nema-l15-50r","nema-l15-60r","nema-l21-20r","nema-l21-30r","nema-l22-30r","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ita-e","ita-f","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","ita-multistandard","usb-a","usb-micro-b","usb-c","dc-terminal","hdot-cx","saf-d-grid","hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -1333,6 +1339,9 @@ const ( // PowerOutletTypeValueNemaDashL21Dash30r captures enum value "nema-l21-30r" PowerOutletTypeValueNemaDashL21Dash30r string = "nema-l21-30r" + // PowerOutletTypeValueNemaDashL22Dash30r captures enum value "nema-l22-30r" + PowerOutletTypeValueNemaDashL22Dash30r string = "nema-l22-30r" + // PowerOutletTypeValueCS6360C captures enum value "CS6360C" PowerOutletTypeValueCS6360C string = "CS6360C" @@ -1384,6 +1393,9 @@ const ( // PowerOutletTypeValueItaDasho captures enum value "ita-o" PowerOutletTypeValueItaDasho string = "ita-o" + // PowerOutletTypeValueItaDashMultistandard captures enum value "ita-multistandard" + PowerOutletTypeValueItaDashMultistandard string = "ita-multistandard" + // PowerOutletTypeValueUsbDasha captures enum value "usb-a" PowerOutletTypeValueUsbDasha string = "usb-a" diff --git a/netbox/models/power_outlet_template.go b/netbox/models/power_outlet_template.go index 69cd2b02..58e61395 100644 --- a/netbox/models/power_outlet_template.go +++ b/netbox/models/power_outlet_template.go @@ -621,12 +621,12 @@ type PowerOutletTemplateType struct { // label // Required: true - // Enum: [C5 C7 C13 C15 C19 C21 P+N+E 4H P+N+E 6H P+N+E 9H 2P+E 4H 2P+E 6H 2P+E 9H 3P+E 4H 3P+E 6H 3P+E 9H 3P+N+E 4H 3P+N+E 6H 3P+N+E 9H NEMA 1-15R NEMA 5-15R NEMA 5-20R NEMA 5-30R NEMA 5-50R NEMA 6-15R NEMA 6-20R NEMA 6-30R NEMA 6-50R NEMA 10-30R NEMA 10-50R NEMA 14-20R NEMA 14-30R NEMA 14-50R NEMA 14-60R NEMA 15-15R NEMA 15-20R NEMA 15-30R NEMA 15-50R NEMA 15-60R NEMA L1-15R NEMA L5-15R NEMA L5-20R NEMA L5-30R NEMA L5-50R NEMA L6-15R NEMA L6-20R NEMA L6-30R NEMA L6-50R NEMA L10-30R NEMA L14-20R NEMA L14-30R NEMA L14-50R NEMA L14-60R NEMA L15-20R NEMA L15-30R NEMA L15-50R NEMA L15-60R NEMA L21-20R NEMA L21-30R CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ITA Type E (CEE 7/5) ITA Type F (CEE 7/3) ITA Type G (BS 1363) ITA Type H ITA Type I ITA Type J ITA Type K ITA Type L (CEI 23-50) ITA Type M (BS 546) ITA Type N ITA Type O USB Type A USB Micro B USB Type C DC Terminal HDOT Cx Saf-D-Grid Hardwired] + // Enum: [C5 C7 C13 C15 C19 C21 P+N+E 4H P+N+E 6H P+N+E 9H 2P+E 4H 2P+E 6H 2P+E 9H 3P+E 4H 3P+E 6H 3P+E 9H 3P+N+E 4H 3P+N+E 6H 3P+N+E 9H NEMA 1-15R NEMA 5-15R NEMA 5-20R NEMA 5-30R NEMA 5-50R NEMA 6-15R NEMA 6-20R NEMA 6-30R NEMA 6-50R NEMA 10-30R NEMA 10-50R NEMA 14-20R NEMA 14-30R NEMA 14-50R NEMA 14-60R NEMA 15-15R NEMA 15-20R NEMA 15-30R NEMA 15-50R NEMA 15-60R NEMA L1-15R NEMA L5-15R NEMA L5-20R NEMA L5-30R NEMA L5-50R NEMA L6-15R NEMA L6-20R NEMA L6-30R NEMA L6-50R NEMA L10-30R NEMA L14-20R NEMA L14-30R NEMA L14-50R NEMA L14-60R NEMA L15-20R NEMA L15-30R NEMA L15-50R NEMA L15-60R NEMA L21-20R NEMA L21-30R NEMA L22-30R CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ITA Type E (CEE 7/5) ITA Type F (CEE 7/3) ITA Type G (BS 1363) ITA Type H ITA Type I ITA Type J ITA Type K ITA Type L (CEI 23-50) ITA Type M (BS 546) ITA Type N ITA Type O ITA Multistandard USB Type A USB Micro B USB Type C DC Terminal HDOT Cx Saf-D-Grid Hardwired] Label *string `json:"label"` // value // Required: true - // Enum: [iec-60320-c5 iec-60320-c7 iec-60320-c13 iec-60320-c15 iec-60320-c19 iec-60320-c21 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15r nema-5-15r nema-5-20r nema-5-30r nema-5-50r nema-6-15r nema-6-20r nema-6-30r nema-6-50r nema-10-30r nema-10-50r nema-14-20r nema-14-30r nema-14-50r nema-14-60r nema-15-15r nema-15-20r nema-15-30r nema-15-50r nema-15-60r nema-l1-15r nema-l5-15r nema-l5-20r nema-l5-30r nema-l5-50r nema-l6-15r nema-l6-20r nema-l6-30r nema-l6-50r nema-l10-30r nema-l14-20r nema-l14-30r nema-l14-50r nema-l14-60r nema-l15-20r nema-l15-30r nema-l15-50r nema-l15-60r nema-l21-20r nema-l21-30r CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ita-e ita-f ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-micro-b usb-c dc-terminal hdot-cx saf-d-grid hardwired] + // Enum: [iec-60320-c5 iec-60320-c7 iec-60320-c13 iec-60320-c15 iec-60320-c19 iec-60320-c21 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15r nema-5-15r nema-5-20r nema-5-30r nema-5-50r nema-6-15r nema-6-20r nema-6-30r nema-6-50r nema-10-30r nema-10-50r nema-14-20r nema-14-30r nema-14-50r nema-14-60r nema-15-15r nema-15-20r nema-15-30r nema-15-50r nema-15-60r nema-l1-15r nema-l5-15r nema-l5-20r nema-l5-30r nema-l5-50r nema-l6-15r nema-l6-20r nema-l6-30r nema-l6-50r nema-l10-30r nema-l14-20r nema-l14-30r nema-l14-50r nema-l14-60r nema-l15-20r nema-l15-30r nema-l15-50r nema-l15-60r nema-l21-20r nema-l21-30r nema-l22-30r CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ita-e ita-f ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o ita-multistandard usb-a usb-micro-b usb-c dc-terminal hdot-cx saf-d-grid hardwired] Value *string `json:"value"` } @@ -652,7 +652,7 @@ var powerOutletTemplateTypeTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["C5","C7","C13","C15","C19","C21","P+N+E 4H","P+N+E 6H","P+N+E 9H","2P+E 4H","2P+E 6H","2P+E 9H","3P+E 4H","3P+E 6H","3P+E 9H","3P+N+E 4H","3P+N+E 6H","3P+N+E 9H","NEMA 1-15R","NEMA 5-15R","NEMA 5-20R","NEMA 5-30R","NEMA 5-50R","NEMA 6-15R","NEMA 6-20R","NEMA 6-30R","NEMA 6-50R","NEMA 10-30R","NEMA 10-50R","NEMA 14-20R","NEMA 14-30R","NEMA 14-50R","NEMA 14-60R","NEMA 15-15R","NEMA 15-20R","NEMA 15-30R","NEMA 15-50R","NEMA 15-60R","NEMA L1-15R","NEMA L5-15R","NEMA L5-20R","NEMA L5-30R","NEMA L5-50R","NEMA L6-15R","NEMA L6-20R","NEMA L6-30R","NEMA L6-50R","NEMA L10-30R","NEMA L14-20R","NEMA L14-30R","NEMA L14-50R","NEMA L14-60R","NEMA L15-20R","NEMA L15-30R","NEMA L15-50R","NEMA L15-60R","NEMA L21-20R","NEMA L21-30R","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ITA Type E (CEE 7/5)","ITA Type F (CEE 7/3)","ITA Type G (BS 1363)","ITA Type H","ITA Type I","ITA Type J","ITA Type K","ITA Type L (CEI 23-50)","ITA Type M (BS 546)","ITA Type N","ITA Type O","USB Type A","USB Micro B","USB Type C","DC Terminal","HDOT Cx","Saf-D-Grid","Hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["C5","C7","C13","C15","C19","C21","P+N+E 4H","P+N+E 6H","P+N+E 9H","2P+E 4H","2P+E 6H","2P+E 9H","3P+E 4H","3P+E 6H","3P+E 9H","3P+N+E 4H","3P+N+E 6H","3P+N+E 9H","NEMA 1-15R","NEMA 5-15R","NEMA 5-20R","NEMA 5-30R","NEMA 5-50R","NEMA 6-15R","NEMA 6-20R","NEMA 6-30R","NEMA 6-50R","NEMA 10-30R","NEMA 10-50R","NEMA 14-20R","NEMA 14-30R","NEMA 14-50R","NEMA 14-60R","NEMA 15-15R","NEMA 15-20R","NEMA 15-30R","NEMA 15-50R","NEMA 15-60R","NEMA L1-15R","NEMA L5-15R","NEMA L5-20R","NEMA L5-30R","NEMA L5-50R","NEMA L6-15R","NEMA L6-20R","NEMA L6-30R","NEMA L6-50R","NEMA L10-30R","NEMA L14-20R","NEMA L14-30R","NEMA L14-50R","NEMA L14-60R","NEMA L15-20R","NEMA L15-30R","NEMA L15-50R","NEMA L15-60R","NEMA L21-20R","NEMA L21-30R","NEMA L22-30R","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ITA Type E (CEE 7/5)","ITA Type F (CEE 7/3)","ITA Type G (BS 1363)","ITA Type H","ITA Type I","ITA Type J","ITA Type K","ITA Type L (CEI 23-50)","ITA Type M (BS 546)","ITA Type N","ITA Type O","ITA Multistandard","USB Type A","USB Micro B","USB Type C","DC Terminal","HDOT Cx","Saf-D-Grid","Hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -836,6 +836,9 @@ const ( // PowerOutletTemplateTypeLabelNEMAL21Dash30R captures enum value "NEMA L21-30R" PowerOutletTemplateTypeLabelNEMAL21Dash30R string = "NEMA L21-30R" + // PowerOutletTemplateTypeLabelNEMAL22Dash30R captures enum value "NEMA L22-30R" + PowerOutletTemplateTypeLabelNEMAL22Dash30R string = "NEMA L22-30R" + // PowerOutletTemplateTypeLabelCS6360C captures enum value "CS6360C" PowerOutletTemplateTypeLabelCS6360C string = "CS6360C" @@ -887,6 +890,9 @@ const ( // PowerOutletTemplateTypeLabelITATypeO captures enum value "ITA Type O" PowerOutletTemplateTypeLabelITATypeO string = "ITA Type O" + // PowerOutletTemplateTypeLabelITAMultistandard captures enum value "ITA Multistandard" + PowerOutletTemplateTypeLabelITAMultistandard string = "ITA Multistandard" + // PowerOutletTemplateTypeLabelUSBTypeA captures enum value "USB Type A" PowerOutletTemplateTypeLabelUSBTypeA string = "USB Type A" @@ -935,7 +941,7 @@ var powerOutletTemplateTypeTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["iec-60320-c5","iec-60320-c7","iec-60320-c13","iec-60320-c15","iec-60320-c19","iec-60320-c21","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15r","nema-5-15r","nema-5-20r","nema-5-30r","nema-5-50r","nema-6-15r","nema-6-20r","nema-6-30r","nema-6-50r","nema-10-30r","nema-10-50r","nema-14-20r","nema-14-30r","nema-14-50r","nema-14-60r","nema-15-15r","nema-15-20r","nema-15-30r","nema-15-50r","nema-15-60r","nema-l1-15r","nema-l5-15r","nema-l5-20r","nema-l5-30r","nema-l5-50r","nema-l6-15r","nema-l6-20r","nema-l6-30r","nema-l6-50r","nema-l10-30r","nema-l14-20r","nema-l14-30r","nema-l14-50r","nema-l14-60r","nema-l15-20r","nema-l15-30r","nema-l15-50r","nema-l15-60r","nema-l21-20r","nema-l21-30r","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ita-e","ita-f","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-micro-b","usb-c","dc-terminal","hdot-cx","saf-d-grid","hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["iec-60320-c5","iec-60320-c7","iec-60320-c13","iec-60320-c15","iec-60320-c19","iec-60320-c21","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15r","nema-5-15r","nema-5-20r","nema-5-30r","nema-5-50r","nema-6-15r","nema-6-20r","nema-6-30r","nema-6-50r","nema-10-30r","nema-10-50r","nema-14-20r","nema-14-30r","nema-14-50r","nema-14-60r","nema-15-15r","nema-15-20r","nema-15-30r","nema-15-50r","nema-15-60r","nema-l1-15r","nema-l5-15r","nema-l5-20r","nema-l5-30r","nema-l5-50r","nema-l6-15r","nema-l6-20r","nema-l6-30r","nema-l6-50r","nema-l10-30r","nema-l14-20r","nema-l14-30r","nema-l14-50r","nema-l14-60r","nema-l15-20r","nema-l15-30r","nema-l15-50r","nema-l15-60r","nema-l21-20r","nema-l21-30r","nema-l22-30r","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ita-e","ita-f","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","ita-multistandard","usb-a","usb-micro-b","usb-c","dc-terminal","hdot-cx","saf-d-grid","hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -1119,6 +1125,9 @@ const ( // PowerOutletTemplateTypeValueNemaDashL21Dash30r captures enum value "nema-l21-30r" PowerOutletTemplateTypeValueNemaDashL21Dash30r string = "nema-l21-30r" + // PowerOutletTemplateTypeValueNemaDashL22Dash30r captures enum value "nema-l22-30r" + PowerOutletTemplateTypeValueNemaDashL22Dash30r string = "nema-l22-30r" + // PowerOutletTemplateTypeValueCS6360C captures enum value "CS6360C" PowerOutletTemplateTypeValueCS6360C string = "CS6360C" @@ -1170,6 +1179,9 @@ const ( // PowerOutletTemplateTypeValueItaDasho captures enum value "ita-o" PowerOutletTemplateTypeValueItaDasho string = "ita-o" + // PowerOutletTemplateTypeValueItaDashMultistandard captures enum value "ita-multistandard" + PowerOutletTemplateTypeValueItaDashMultistandard string = "ita-multistandard" + // PowerOutletTemplateTypeValueUsbDasha captures enum value "usb-a" PowerOutletTemplateTypeValueUsbDasha string = "usb-a" diff --git a/netbox/models/power_panel.go b/netbox/models/power_panel.go index 2e153162..bca01588 100644 --- a/netbox/models/power_panel.go +++ b/netbox/models/power_panel.go @@ -35,6 +35,11 @@ import ( // swagger:model PowerPanel type PowerPanel struct { + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Custom fields CustomFields interface{} `json:"custom_fields,omitempty"` @@ -46,6 +51,11 @@ type PowerPanel struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // location Location *NestedLocation `json:"location,omitempty"` @@ -76,6 +86,14 @@ type PowerPanel struct { func (m *PowerPanel) Validate(formats strfmt.Registry) error { var res []error + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateLocation(formats); err != nil { res = append(res, err) } @@ -102,6 +120,30 @@ func (m *PowerPanel) Validate(formats strfmt.Registry) error { return nil } +func (m *PowerPanel) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *PowerPanel) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *PowerPanel) validateLocation(formats strfmt.Registry) error { if swag.IsZero(m.Location) { // not required return nil @@ -200,6 +242,10 @@ func (m *PowerPanel) validateURL(formats strfmt.Registry) error { func (m *PowerPanel) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -208,6 +254,10 @@ func (m *PowerPanel) ContextValidate(ctx context.Context, formats strfmt.Registr res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateLocation(ctx, formats); err != nil { res = append(res, err) } @@ -234,6 +284,15 @@ func (m *PowerPanel) ContextValidate(ctx context.Context, formats strfmt.Registr return nil } +func (m *PowerPanel) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *PowerPanel) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -252,6 +311,15 @@ func (m *PowerPanel) contextValidateID(ctx context.Context, formats strfmt.Regis return nil } +func (m *PowerPanel) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *PowerPanel) contextValidateLocation(ctx context.Context, formats strfmt.Registry) error { if m.Location != nil { diff --git a/netbox/models/power_port.go b/netbox/models/power_port.go index 084c4495..11bcc373 100644 --- a/netbox/models/power_port.go +++ b/netbox/models/power_port.go @@ -50,18 +50,6 @@ type PowerPort struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Connected endpoint // // @@ -113,6 +101,18 @@ type PowerPort struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -406,14 +406,6 @@ func (m *PowerPort) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { - res = append(res, err) - } - if err := m.contextValidateConnectedEndpoint(ctx, formats); err != nil { res = append(res, err) } @@ -446,6 +438,14 @@ func (m *PowerPort) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTags(ctx, formats); err != nil { res = append(res, err) } @@ -489,20 +489,6 @@ func (m *PowerPort) contextValidateCable(ctx context.Context, formats strfmt.Reg return nil } -func (m *PowerPort) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *PowerPort) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *PowerPort) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil @@ -578,6 +564,20 @@ func (m *PowerPort) contextValidateLastUpdated(ctx context.Context, formats strf return nil } +func (m *PowerPort) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *PowerPort) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *PowerPort) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { @@ -648,12 +648,12 @@ type PowerPortType struct { // label // Required: true - // Enum: [C6 C8 C14 C16 C20 C22 P+N+E 4H P+N+E 6H P+N+E 9H 2P+E 4H 2P+E 6H 2P+E 9H 3P+E 4H 3P+E 6H 3P+E 9H 3P+N+E 4H 3P+N+E 6H 3P+N+E 9H NEMA 1-15P NEMA 5-15P NEMA 5-20P NEMA 5-30P NEMA 5-50P NEMA 6-15P NEMA 6-20P NEMA 6-30P NEMA 6-50P NEMA 10-30P NEMA 10-50P NEMA 14-20P NEMA 14-30P NEMA 14-50P NEMA 14-60P NEMA 15-15P NEMA 15-20P NEMA 15-30P NEMA 15-50P NEMA 15-60P NEMA L1-15P NEMA L5-15P NEMA L5-20P NEMA L5-30P NEMA L5-50P NEMA L6-15P NEMA L6-20P NEMA L6-30P NEMA L6-50P NEMA L10-30P NEMA L14-20P NEMA L14-30P NEMA L14-50P NEMA L14-60P NEMA L15-20P NEMA L15-30P NEMA L15-50P NEMA L15-60P NEMA L21-20P NEMA L21-30P CS6361C CS6365C CS8165C CS8265C CS8365C CS8465C ITA Type C (CEE 7/16) ITA Type E (CEE 7/6) ITA Type F (CEE 7/4) ITA Type E/F (CEE 7/7) ITA Type G (BS 1363) ITA Type H ITA Type I ITA Type J ITA Type K ITA Type L (CEI 23-50) ITA Type M (BS 546) ITA Type N ITA Type O USB Type A USB Type B USB Type C USB Mini A USB Mini B USB Micro A USB Micro B USB Micro AB USB 3.0 Type B USB 3.0 Micro B DC Terminal Saf-D-Grid Hardwired] + // Enum: [C6 C8 C14 C16 C20 C22 P+N+E 4H P+N+E 6H P+N+E 9H 2P+E 4H 2P+E 6H 2P+E 9H 3P+E 4H 3P+E 6H 3P+E 9H 3P+N+E 4H 3P+N+E 6H 3P+N+E 9H NEMA 1-15P NEMA 5-15P NEMA 5-20P NEMA 5-30P NEMA 5-50P NEMA 6-15P NEMA 6-20P NEMA 6-30P NEMA 6-50P NEMA 10-30P NEMA 10-50P NEMA 14-20P NEMA 14-30P NEMA 14-50P NEMA 14-60P NEMA 15-15P NEMA 15-20P NEMA 15-30P NEMA 15-50P NEMA 15-60P NEMA L1-15P NEMA L5-15P NEMA L5-20P NEMA L5-30P NEMA L5-50P NEMA L6-15P NEMA L6-20P NEMA L6-30P NEMA L6-50P NEMA L10-30P NEMA L14-20P NEMA L14-30P NEMA L14-50P NEMA L14-60P NEMA L15-20P NEMA L15-30P NEMA L15-50P NEMA L15-60P NEMA L21-20P NEMA L21-30P NEMA L22-30P CS6361C CS6365C CS8165C CS8265C CS8365C CS8465C ITA Type C (CEE 7/16) ITA Type E (CEE 7/6) ITA Type F (CEE 7/4) ITA Type E/F (CEE 7/7) ITA Type G (BS 1363) ITA Type H ITA Type I ITA Type J ITA Type K ITA Type L (CEI 23-50) ITA Type M (BS 546) ITA Type N ITA Type O USB Type A USB Type B USB Type C USB Mini A USB Mini B USB Micro A USB Micro B USB Micro AB USB 3.0 Type B USB 3.0 Micro B DC Terminal Saf-D-Grid Hardwired] Label *string `json:"label"` // value // Required: true - // Enum: [iec-60320-c6 iec-60320-c8 iec-60320-c14 iec-60320-c16 iec-60320-c20 iec-60320-c22 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15p nema-5-15p nema-5-20p nema-5-30p nema-5-50p nema-6-15p nema-6-20p nema-6-30p nema-6-50p nema-10-30p nema-10-50p nema-14-20p nema-14-30p nema-14-50p nema-14-60p nema-15-15p nema-15-20p nema-15-30p nema-15-50p nema-15-60p nema-l1-15p nema-l5-15p nema-l5-20p nema-l5-30p nema-l5-50p nema-l6-15p nema-l6-20p nema-l6-30p nema-l6-50p nema-l10-30p nema-l14-20p nema-l14-30p nema-l14-50p nema-l14-60p nema-l15-20p nema-l15-30p nema-l15-50p nema-l15-60p nema-l21-20p nema-l21-30p cs6361c cs6365c cs8165c cs8265c cs8365c cs8465c ita-c ita-e ita-f ita-ef ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-b usb-c usb-mini-a usb-mini-b usb-micro-a usb-micro-b usb-micro-ab usb-3-b usb-3-micro-b dc-terminal saf-d-grid hardwired] + // Enum: [iec-60320-c6 iec-60320-c8 iec-60320-c14 iec-60320-c16 iec-60320-c20 iec-60320-c22 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15p nema-5-15p nema-5-20p nema-5-30p nema-5-50p nema-6-15p nema-6-20p nema-6-30p nema-6-50p nema-10-30p nema-10-50p nema-14-20p nema-14-30p nema-14-50p nema-14-60p nema-15-15p nema-15-20p nema-15-30p nema-15-50p nema-15-60p nema-l1-15p nema-l5-15p nema-l5-20p nema-l5-30p nema-l5-50p nema-l6-15p nema-l6-20p nema-l6-30p nema-l6-50p nema-l10-30p nema-l14-20p nema-l14-30p nema-l14-50p nema-l14-60p nema-l15-20p nema-l15-30p nema-l15-50p nema-l15-60p nema-l21-20p nema-l21-30p nema-l22-30p cs6361c cs6365c cs8165c cs8265c cs8365c cs8465c ita-c ita-e ita-f ita-ef ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-b usb-c usb-mini-a usb-mini-b usb-micro-a usb-micro-b usb-micro-ab usb-3-b usb-3-micro-b dc-terminal saf-d-grid hardwired] Value *string `json:"value"` } @@ -679,7 +679,7 @@ var powerPortTypeTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["C6","C8","C14","C16","C20","C22","P+N+E 4H","P+N+E 6H","P+N+E 9H","2P+E 4H","2P+E 6H","2P+E 9H","3P+E 4H","3P+E 6H","3P+E 9H","3P+N+E 4H","3P+N+E 6H","3P+N+E 9H","NEMA 1-15P","NEMA 5-15P","NEMA 5-20P","NEMA 5-30P","NEMA 5-50P","NEMA 6-15P","NEMA 6-20P","NEMA 6-30P","NEMA 6-50P","NEMA 10-30P","NEMA 10-50P","NEMA 14-20P","NEMA 14-30P","NEMA 14-50P","NEMA 14-60P","NEMA 15-15P","NEMA 15-20P","NEMA 15-30P","NEMA 15-50P","NEMA 15-60P","NEMA L1-15P","NEMA L5-15P","NEMA L5-20P","NEMA L5-30P","NEMA L5-50P","NEMA L6-15P","NEMA L6-20P","NEMA L6-30P","NEMA L6-50P","NEMA L10-30P","NEMA L14-20P","NEMA L14-30P","NEMA L14-50P","NEMA L14-60P","NEMA L15-20P","NEMA L15-30P","NEMA L15-50P","NEMA L15-60P","NEMA L21-20P","NEMA L21-30P","CS6361C","CS6365C","CS8165C","CS8265C","CS8365C","CS8465C","ITA Type C (CEE 7/16)","ITA Type E (CEE 7/6)","ITA Type F (CEE 7/4)","ITA Type E/F (CEE 7/7)","ITA Type G (BS 1363)","ITA Type H","ITA Type I","ITA Type J","ITA Type K","ITA Type L (CEI 23-50)","ITA Type M (BS 546)","ITA Type N","ITA Type O","USB Type A","USB Type B","USB Type C","USB Mini A","USB Mini B","USB Micro A","USB Micro B","USB Micro AB","USB 3.0 Type B","USB 3.0 Micro B","DC Terminal","Saf-D-Grid","Hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["C6","C8","C14","C16","C20","C22","P+N+E 4H","P+N+E 6H","P+N+E 9H","2P+E 4H","2P+E 6H","2P+E 9H","3P+E 4H","3P+E 6H","3P+E 9H","3P+N+E 4H","3P+N+E 6H","3P+N+E 9H","NEMA 1-15P","NEMA 5-15P","NEMA 5-20P","NEMA 5-30P","NEMA 5-50P","NEMA 6-15P","NEMA 6-20P","NEMA 6-30P","NEMA 6-50P","NEMA 10-30P","NEMA 10-50P","NEMA 14-20P","NEMA 14-30P","NEMA 14-50P","NEMA 14-60P","NEMA 15-15P","NEMA 15-20P","NEMA 15-30P","NEMA 15-50P","NEMA 15-60P","NEMA L1-15P","NEMA L5-15P","NEMA L5-20P","NEMA L5-30P","NEMA L5-50P","NEMA L6-15P","NEMA L6-20P","NEMA L6-30P","NEMA L6-50P","NEMA L10-30P","NEMA L14-20P","NEMA L14-30P","NEMA L14-50P","NEMA L14-60P","NEMA L15-20P","NEMA L15-30P","NEMA L15-50P","NEMA L15-60P","NEMA L21-20P","NEMA L21-30P","NEMA L22-30P","CS6361C","CS6365C","CS8165C","CS8265C","CS8365C","CS8465C","ITA Type C (CEE 7/16)","ITA Type E (CEE 7/6)","ITA Type F (CEE 7/4)","ITA Type E/F (CEE 7/7)","ITA Type G (BS 1363)","ITA Type H","ITA Type I","ITA Type J","ITA Type K","ITA Type L (CEI 23-50)","ITA Type M (BS 546)","ITA Type N","ITA Type O","USB Type A","USB Type B","USB Type C","USB Mini A","USB Mini B","USB Micro A","USB Micro B","USB Micro AB","USB 3.0 Type B","USB 3.0 Micro B","DC Terminal","Saf-D-Grid","Hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -863,6 +863,9 @@ const ( // PowerPortTypeLabelNEMAL21Dash30P captures enum value "NEMA L21-30P" PowerPortTypeLabelNEMAL21Dash30P string = "NEMA L21-30P" + // PowerPortTypeLabelNEMAL22Dash30P captures enum value "NEMA L22-30P" + PowerPortTypeLabelNEMAL22Dash30P string = "NEMA L22-30P" + // PowerPortTypeLabelCS6361C captures enum value "CS6361C" PowerPortTypeLabelCS6361C string = "CS6361C" @@ -986,7 +989,7 @@ var powerPortTypeTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["iec-60320-c6","iec-60320-c8","iec-60320-c14","iec-60320-c16","iec-60320-c20","iec-60320-c22","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15p","nema-5-15p","nema-5-20p","nema-5-30p","nema-5-50p","nema-6-15p","nema-6-20p","nema-6-30p","nema-6-50p","nema-10-30p","nema-10-50p","nema-14-20p","nema-14-30p","nema-14-50p","nema-14-60p","nema-15-15p","nema-15-20p","nema-15-30p","nema-15-50p","nema-15-60p","nema-l1-15p","nema-l5-15p","nema-l5-20p","nema-l5-30p","nema-l5-50p","nema-l6-15p","nema-l6-20p","nema-l6-30p","nema-l6-50p","nema-l10-30p","nema-l14-20p","nema-l14-30p","nema-l14-50p","nema-l14-60p","nema-l15-20p","nema-l15-30p","nema-l15-50p","nema-l15-60p","nema-l21-20p","nema-l21-30p","cs6361c","cs6365c","cs8165c","cs8265c","cs8365c","cs8465c","ita-c","ita-e","ita-f","ita-ef","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-b","usb-c","usb-mini-a","usb-mini-b","usb-micro-a","usb-micro-b","usb-micro-ab","usb-3-b","usb-3-micro-b","dc-terminal","saf-d-grid","hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["iec-60320-c6","iec-60320-c8","iec-60320-c14","iec-60320-c16","iec-60320-c20","iec-60320-c22","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15p","nema-5-15p","nema-5-20p","nema-5-30p","nema-5-50p","nema-6-15p","nema-6-20p","nema-6-30p","nema-6-50p","nema-10-30p","nema-10-50p","nema-14-20p","nema-14-30p","nema-14-50p","nema-14-60p","nema-15-15p","nema-15-20p","nema-15-30p","nema-15-50p","nema-15-60p","nema-l1-15p","nema-l5-15p","nema-l5-20p","nema-l5-30p","nema-l5-50p","nema-l6-15p","nema-l6-20p","nema-l6-30p","nema-l6-50p","nema-l10-30p","nema-l14-20p","nema-l14-30p","nema-l14-50p","nema-l14-60p","nema-l15-20p","nema-l15-30p","nema-l15-50p","nema-l15-60p","nema-l21-20p","nema-l21-30p","nema-l22-30p","cs6361c","cs6365c","cs8165c","cs8265c","cs8365c","cs8465c","ita-c","ita-e","ita-f","ita-ef","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-b","usb-c","usb-mini-a","usb-mini-b","usb-micro-a","usb-micro-b","usb-micro-ab","usb-3-b","usb-3-micro-b","dc-terminal","saf-d-grid","hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -1170,6 +1173,9 @@ const ( // PowerPortTypeValueNemaDashL21Dash30p captures enum value "nema-l21-30p" PowerPortTypeValueNemaDashL21Dash30p string = "nema-l21-30p" + // PowerPortTypeValueNemaDashL22Dash30p captures enum value "nema-l22-30p" + PowerPortTypeValueNemaDashL22Dash30p string = "nema-l22-30p" + // PowerPortTypeValueCs6361c captures enum value "cs6361c" PowerPortTypeValueCs6361c string = "cs6361c" diff --git a/netbox/models/power_port_template.go b/netbox/models/power_port_template.go index 71fda205..1fbc58fa 100644 --- a/netbox/models/power_port_template.go +++ b/netbox/models/power_port_template.go @@ -434,12 +434,12 @@ type PowerPortTemplateType struct { // label // Required: true - // Enum: [C6 C8 C14 C16 C20 C22 P+N+E 4H P+N+E 6H P+N+E 9H 2P+E 4H 2P+E 6H 2P+E 9H 3P+E 4H 3P+E 6H 3P+E 9H 3P+N+E 4H 3P+N+E 6H 3P+N+E 9H NEMA 1-15P NEMA 5-15P NEMA 5-20P NEMA 5-30P NEMA 5-50P NEMA 6-15P NEMA 6-20P NEMA 6-30P NEMA 6-50P NEMA 10-30P NEMA 10-50P NEMA 14-20P NEMA 14-30P NEMA 14-50P NEMA 14-60P NEMA 15-15P NEMA 15-20P NEMA 15-30P NEMA 15-50P NEMA 15-60P NEMA L1-15P NEMA L5-15P NEMA L5-20P NEMA L5-30P NEMA L5-50P NEMA L6-15P NEMA L6-20P NEMA L6-30P NEMA L6-50P NEMA L10-30P NEMA L14-20P NEMA L14-30P NEMA L14-50P NEMA L14-60P NEMA L15-20P NEMA L15-30P NEMA L15-50P NEMA L15-60P NEMA L21-20P NEMA L21-30P CS6361C CS6365C CS8165C CS8265C CS8365C CS8465C ITA Type C (CEE 7/16) ITA Type E (CEE 7/6) ITA Type F (CEE 7/4) ITA Type E/F (CEE 7/7) ITA Type G (BS 1363) ITA Type H ITA Type I ITA Type J ITA Type K ITA Type L (CEI 23-50) ITA Type M (BS 546) ITA Type N ITA Type O USB Type A USB Type B USB Type C USB Mini A USB Mini B USB Micro A USB Micro B USB Micro AB USB 3.0 Type B USB 3.0 Micro B DC Terminal Saf-D-Grid Hardwired] + // Enum: [C6 C8 C14 C16 C20 C22 P+N+E 4H P+N+E 6H P+N+E 9H 2P+E 4H 2P+E 6H 2P+E 9H 3P+E 4H 3P+E 6H 3P+E 9H 3P+N+E 4H 3P+N+E 6H 3P+N+E 9H NEMA 1-15P NEMA 5-15P NEMA 5-20P NEMA 5-30P NEMA 5-50P NEMA 6-15P NEMA 6-20P NEMA 6-30P NEMA 6-50P NEMA 10-30P NEMA 10-50P NEMA 14-20P NEMA 14-30P NEMA 14-50P NEMA 14-60P NEMA 15-15P NEMA 15-20P NEMA 15-30P NEMA 15-50P NEMA 15-60P NEMA L1-15P NEMA L5-15P NEMA L5-20P NEMA L5-30P NEMA L5-50P NEMA L6-15P NEMA L6-20P NEMA L6-30P NEMA L6-50P NEMA L10-30P NEMA L14-20P NEMA L14-30P NEMA L14-50P NEMA L14-60P NEMA L15-20P NEMA L15-30P NEMA L15-50P NEMA L15-60P NEMA L21-20P NEMA L21-30P NEMA L22-30P CS6361C CS6365C CS8165C CS8265C CS8365C CS8465C ITA Type C (CEE 7/16) ITA Type E (CEE 7/6) ITA Type F (CEE 7/4) ITA Type E/F (CEE 7/7) ITA Type G (BS 1363) ITA Type H ITA Type I ITA Type J ITA Type K ITA Type L (CEI 23-50) ITA Type M (BS 546) ITA Type N ITA Type O USB Type A USB Type B USB Type C USB Mini A USB Mini B USB Micro A USB Micro B USB Micro AB USB 3.0 Type B USB 3.0 Micro B DC Terminal Saf-D-Grid Hardwired] Label *string `json:"label"` // value // Required: true - // Enum: [iec-60320-c6 iec-60320-c8 iec-60320-c14 iec-60320-c16 iec-60320-c20 iec-60320-c22 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15p nema-5-15p nema-5-20p nema-5-30p nema-5-50p nema-6-15p nema-6-20p nema-6-30p nema-6-50p nema-10-30p nema-10-50p nema-14-20p nema-14-30p nema-14-50p nema-14-60p nema-15-15p nema-15-20p nema-15-30p nema-15-50p nema-15-60p nema-l1-15p nema-l5-15p nema-l5-20p nema-l5-30p nema-l5-50p nema-l6-15p nema-l6-20p nema-l6-30p nema-l6-50p nema-l10-30p nema-l14-20p nema-l14-30p nema-l14-50p nema-l14-60p nema-l15-20p nema-l15-30p nema-l15-50p nema-l15-60p nema-l21-20p nema-l21-30p cs6361c cs6365c cs8165c cs8265c cs8365c cs8465c ita-c ita-e ita-f ita-ef ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-b usb-c usb-mini-a usb-mini-b usb-micro-a usb-micro-b usb-micro-ab usb-3-b usb-3-micro-b dc-terminal saf-d-grid hardwired] + // Enum: [iec-60320-c6 iec-60320-c8 iec-60320-c14 iec-60320-c16 iec-60320-c20 iec-60320-c22 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15p nema-5-15p nema-5-20p nema-5-30p nema-5-50p nema-6-15p nema-6-20p nema-6-30p nema-6-50p nema-10-30p nema-10-50p nema-14-20p nema-14-30p nema-14-50p nema-14-60p nema-15-15p nema-15-20p nema-15-30p nema-15-50p nema-15-60p nema-l1-15p nema-l5-15p nema-l5-20p nema-l5-30p nema-l5-50p nema-l6-15p nema-l6-20p nema-l6-30p nema-l6-50p nema-l10-30p nema-l14-20p nema-l14-30p nema-l14-50p nema-l14-60p nema-l15-20p nema-l15-30p nema-l15-50p nema-l15-60p nema-l21-20p nema-l21-30p nema-l22-30p cs6361c cs6365c cs8165c cs8265c cs8365c cs8465c ita-c ita-e ita-f ita-ef ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-b usb-c usb-mini-a usb-mini-b usb-micro-a usb-micro-b usb-micro-ab usb-3-b usb-3-micro-b dc-terminal saf-d-grid hardwired] Value *string `json:"value"` } @@ -465,7 +465,7 @@ var powerPortTemplateTypeTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["C6","C8","C14","C16","C20","C22","P+N+E 4H","P+N+E 6H","P+N+E 9H","2P+E 4H","2P+E 6H","2P+E 9H","3P+E 4H","3P+E 6H","3P+E 9H","3P+N+E 4H","3P+N+E 6H","3P+N+E 9H","NEMA 1-15P","NEMA 5-15P","NEMA 5-20P","NEMA 5-30P","NEMA 5-50P","NEMA 6-15P","NEMA 6-20P","NEMA 6-30P","NEMA 6-50P","NEMA 10-30P","NEMA 10-50P","NEMA 14-20P","NEMA 14-30P","NEMA 14-50P","NEMA 14-60P","NEMA 15-15P","NEMA 15-20P","NEMA 15-30P","NEMA 15-50P","NEMA 15-60P","NEMA L1-15P","NEMA L5-15P","NEMA L5-20P","NEMA L5-30P","NEMA L5-50P","NEMA L6-15P","NEMA L6-20P","NEMA L6-30P","NEMA L6-50P","NEMA L10-30P","NEMA L14-20P","NEMA L14-30P","NEMA L14-50P","NEMA L14-60P","NEMA L15-20P","NEMA L15-30P","NEMA L15-50P","NEMA L15-60P","NEMA L21-20P","NEMA L21-30P","CS6361C","CS6365C","CS8165C","CS8265C","CS8365C","CS8465C","ITA Type C (CEE 7/16)","ITA Type E (CEE 7/6)","ITA Type F (CEE 7/4)","ITA Type E/F (CEE 7/7)","ITA Type G (BS 1363)","ITA Type H","ITA Type I","ITA Type J","ITA Type K","ITA Type L (CEI 23-50)","ITA Type M (BS 546)","ITA Type N","ITA Type O","USB Type A","USB Type B","USB Type C","USB Mini A","USB Mini B","USB Micro A","USB Micro B","USB Micro AB","USB 3.0 Type B","USB 3.0 Micro B","DC Terminal","Saf-D-Grid","Hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["C6","C8","C14","C16","C20","C22","P+N+E 4H","P+N+E 6H","P+N+E 9H","2P+E 4H","2P+E 6H","2P+E 9H","3P+E 4H","3P+E 6H","3P+E 9H","3P+N+E 4H","3P+N+E 6H","3P+N+E 9H","NEMA 1-15P","NEMA 5-15P","NEMA 5-20P","NEMA 5-30P","NEMA 5-50P","NEMA 6-15P","NEMA 6-20P","NEMA 6-30P","NEMA 6-50P","NEMA 10-30P","NEMA 10-50P","NEMA 14-20P","NEMA 14-30P","NEMA 14-50P","NEMA 14-60P","NEMA 15-15P","NEMA 15-20P","NEMA 15-30P","NEMA 15-50P","NEMA 15-60P","NEMA L1-15P","NEMA L5-15P","NEMA L5-20P","NEMA L5-30P","NEMA L5-50P","NEMA L6-15P","NEMA L6-20P","NEMA L6-30P","NEMA L6-50P","NEMA L10-30P","NEMA L14-20P","NEMA L14-30P","NEMA L14-50P","NEMA L14-60P","NEMA L15-20P","NEMA L15-30P","NEMA L15-50P","NEMA L15-60P","NEMA L21-20P","NEMA L21-30P","NEMA L22-30P","CS6361C","CS6365C","CS8165C","CS8265C","CS8365C","CS8465C","ITA Type C (CEE 7/16)","ITA Type E (CEE 7/6)","ITA Type F (CEE 7/4)","ITA Type E/F (CEE 7/7)","ITA Type G (BS 1363)","ITA Type H","ITA Type I","ITA Type J","ITA Type K","ITA Type L (CEI 23-50)","ITA Type M (BS 546)","ITA Type N","ITA Type O","USB Type A","USB Type B","USB Type C","USB Mini A","USB Mini B","USB Micro A","USB Micro B","USB Micro AB","USB 3.0 Type B","USB 3.0 Micro B","DC Terminal","Saf-D-Grid","Hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -649,6 +649,9 @@ const ( // PowerPortTemplateTypeLabelNEMAL21Dash30P captures enum value "NEMA L21-30P" PowerPortTemplateTypeLabelNEMAL21Dash30P string = "NEMA L21-30P" + // PowerPortTemplateTypeLabelNEMAL22Dash30P captures enum value "NEMA L22-30P" + PowerPortTemplateTypeLabelNEMAL22Dash30P string = "NEMA L22-30P" + // PowerPortTemplateTypeLabelCS6361C captures enum value "CS6361C" PowerPortTemplateTypeLabelCS6361C string = "CS6361C" @@ -772,7 +775,7 @@ var powerPortTemplateTypeTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["iec-60320-c6","iec-60320-c8","iec-60320-c14","iec-60320-c16","iec-60320-c20","iec-60320-c22","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15p","nema-5-15p","nema-5-20p","nema-5-30p","nema-5-50p","nema-6-15p","nema-6-20p","nema-6-30p","nema-6-50p","nema-10-30p","nema-10-50p","nema-14-20p","nema-14-30p","nema-14-50p","nema-14-60p","nema-15-15p","nema-15-20p","nema-15-30p","nema-15-50p","nema-15-60p","nema-l1-15p","nema-l5-15p","nema-l5-20p","nema-l5-30p","nema-l5-50p","nema-l6-15p","nema-l6-20p","nema-l6-30p","nema-l6-50p","nema-l10-30p","nema-l14-20p","nema-l14-30p","nema-l14-50p","nema-l14-60p","nema-l15-20p","nema-l15-30p","nema-l15-50p","nema-l15-60p","nema-l21-20p","nema-l21-30p","cs6361c","cs6365c","cs8165c","cs8265c","cs8365c","cs8465c","ita-c","ita-e","ita-f","ita-ef","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-b","usb-c","usb-mini-a","usb-mini-b","usb-micro-a","usb-micro-b","usb-micro-ab","usb-3-b","usb-3-micro-b","dc-terminal","saf-d-grid","hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["iec-60320-c6","iec-60320-c8","iec-60320-c14","iec-60320-c16","iec-60320-c20","iec-60320-c22","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15p","nema-5-15p","nema-5-20p","nema-5-30p","nema-5-50p","nema-6-15p","nema-6-20p","nema-6-30p","nema-6-50p","nema-10-30p","nema-10-50p","nema-14-20p","nema-14-30p","nema-14-50p","nema-14-60p","nema-15-15p","nema-15-20p","nema-15-30p","nema-15-50p","nema-15-60p","nema-l1-15p","nema-l5-15p","nema-l5-20p","nema-l5-30p","nema-l5-50p","nema-l6-15p","nema-l6-20p","nema-l6-30p","nema-l6-50p","nema-l10-30p","nema-l14-20p","nema-l14-30p","nema-l14-50p","nema-l14-60p","nema-l15-20p","nema-l15-30p","nema-l15-50p","nema-l15-60p","nema-l21-20p","nema-l21-30p","nema-l22-30p","cs6361c","cs6365c","cs8165c","cs8265c","cs8365c","cs8465c","ita-c","ita-e","ita-f","ita-ef","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-b","usb-c","usb-mini-a","usb-mini-b","usb-micro-a","usb-micro-b","usb-micro-ab","usb-3-b","usb-3-micro-b","dc-terminal","saf-d-grid","hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -956,6 +959,9 @@ const ( // PowerPortTemplateTypeValueNemaDashL21Dash30p captures enum value "nema-l21-30p" PowerPortTemplateTypeValueNemaDashL21Dash30p string = "nema-l21-30p" + // PowerPortTemplateTypeValueNemaDashL22Dash30p captures enum value "nema-l22-30p" + PowerPortTemplateTypeValueNemaDashL22Dash30p string = "nema-l22-30p" + // PowerPortTemplateTypeValueCs6361c captures enum value "cs6361c" PowerPortTemplateTypeValueCs6361c string = "cs6361c" diff --git a/netbox/models/r_i_r.go b/netbox/models/r_i_r.go index 06f78dcd..50ff9a8a 100644 --- a/netbox/models/r_i_r.go +++ b/netbox/models/r_i_r.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -81,6 +82,9 @@ type RIR struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -111,6 +115,10 @@ func (m *RIR) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -195,6 +203,32 @@ func (m *RIR) validateSlug(formats strfmt.Registry) error { return nil } +func (m *RIR) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *RIR) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -231,6 +265,10 @@ func (m *RIR) ContextValidate(ctx context.Context, formats strfmt.Registry) erro res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -286,6 +324,26 @@ func (m *RIR) contextValidateLastUpdated(ctx context.Context, formats strfmt.Reg return nil } +func (m *RIR) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *RIR) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/rack.go b/netbox/models/rack.go index 79bdfaa5..f840e573 100644 --- a/netbox/models/rack.go +++ b/netbox/models/rack.go @@ -67,8 +67,6 @@ type Rack struct { Display string `json:"display,omitempty"` // Facility ID - // - // Locally-assigned identifier // Max Length: 50 FacilityID *string `json:"facility_id,omitempty"` diff --git a/netbox/models/rack_reservation.go b/netbox/models/rack_reservation.go index 417436aa..a4ea1813 100644 --- a/netbox/models/rack_reservation.go +++ b/netbox/models/rack_reservation.go @@ -57,6 +57,11 @@ type RackReservation struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // rack // Required: true Rack *NestedRack `json:"rack"` @@ -93,6 +98,10 @@ func (m *RackReservation) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateRack(formats); err != nil { res = append(res, err) } @@ -152,6 +161,18 @@ func (m *RackReservation) validateDescription(formats strfmt.Registry) error { return nil } +func (m *RackReservation) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *RackReservation) validateRack(formats strfmt.Registry) error { if err := validate.Required("rack", "body", m.Rack); err != nil { @@ -289,6 +310,10 @@ func (m *RackReservation) ContextValidate(ctx context.Context, formats strfmt.Re res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateRack(ctx, formats); err != nil { res = append(res, err) } @@ -342,6 +367,15 @@ func (m *RackReservation) contextValidateID(ctx context.Context, formats strfmt. return nil } +func (m *RackReservation) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *RackReservation) contextValidateRack(ctx context.Context, formats strfmt.Registry) error { if m.Rack != nil { diff --git a/netbox/models/rack_role.go b/netbox/models/rack_role.go index fbf9ba6c..f19a25f4 100644 --- a/netbox/models/rack_role.go +++ b/netbox/models/rack_role.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -82,6 +83,9 @@ type RackRole struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -116,6 +120,10 @@ func (m *RackRole) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -220,6 +228,32 @@ func (m *RackRole) validateSlug(formats strfmt.Registry) error { return nil } +func (m *RackRole) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *RackRole) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -256,6 +290,10 @@ func (m *RackRole) ContextValidate(ctx context.Context, formats strfmt.Registry) res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -311,6 +349,26 @@ func (m *RackRole) contextValidateRackCount(ctx context.Context, formats strfmt. return nil } +func (m *RackRole) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *RackRole) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/rear_port.go b/netbox/models/rear_port.go index 5882692b..71382cf4 100644 --- a/netbox/models/rear_port.go +++ b/netbox/models/rear_port.go @@ -43,18 +43,6 @@ type RearPort struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Color // Max Length: 6 // Pattern: ^[0-9a-f]{6}$ @@ -95,6 +83,18 @@ type RearPort struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -388,31 +388,31 @@ func (m *RearPort) ContextValidate(ctx context.Context, formats strfmt.Registry) res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { + if err := m.contextValidateCreated(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { + if err := m.contextValidateDevice(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCreated(ctx, formats); err != nil { + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateDevice(ctx, formats); err != nil { + if err := m.contextValidateID(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateDisplay(ctx, formats); err != nil { + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateID(ctx, formats); err != nil { + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { res = append(res, err) } @@ -459,20 +459,6 @@ func (m *RearPort) contextValidateCable(ctx context.Context, formats strfmt.Regi return nil } -func (m *RearPort) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *RearPort) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *RearPort) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { @@ -525,6 +511,20 @@ func (m *RearPort) contextValidateLastUpdated(ctx context.Context, formats strfm return nil } +func (m *RearPort) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *RearPort) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *RearPort) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { @@ -595,12 +595,12 @@ type RearPortType struct { // label // Required: true - // Enum: [8P8C 8P6C 8P4C 8P2C 6P6C 6P4C 6P2C 4P4C 4P2C GG45 TERA 4P TERA 2P TERA 1P 110 Punch BNC F Connector N Connector MRJ21 FC LC LC/APC LSH LSH/APC MPO MTRJ SC SC/APC ST CS SN SMA 905 SMA 906 URM-P2 URM-P4 URM-P8 Splice] + // Enum: [8P8C 8P6C 8P4C 8P2C 6P6C 6P4C 6P2C 4P4C 4P2C GG45 TERA 4P TERA 2P TERA 1P 110 Punch BNC F Connector N Connector MRJ21 FC LC LC/PC LC/UPC LC/APC LSH LSH/PC LSH/UPC LSH/APC MPO MTRJ SC SC/PC SC/UPC SC/APC ST CS SN SMA 905 SMA 906 URM-P2 URM-P4 URM-P8 Splice] Label *string `json:"label"` // value // Required: true - // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-apc lsh lsh-apc mpo mtrj sc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] + // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-pc lc-upc lc-apc lsh lsh-pc lsh-upc lsh-apc mpo mtrj sc sc-pc sc-upc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] Value *string `json:"value"` } @@ -626,7 +626,7 @@ var rearPortTypeTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8P8C","8P6C","8P4C","8P2C","6P6C","6P4C","6P2C","4P4C","4P2C","GG45","TERA 4P","TERA 2P","TERA 1P","110 Punch","BNC","F Connector","N Connector","MRJ21","FC","LC","LC/APC","LSH","LSH/APC","MPO","MTRJ","SC","SC/APC","ST","CS","SN","SMA 905","SMA 906","URM-P2","URM-P4","URM-P8","Splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8P8C","8P6C","8P4C","8P2C","6P6C","6P4C","6P2C","4P4C","4P2C","GG45","TERA 4P","TERA 2P","TERA 1P","110 Punch","BNC","F Connector","N Connector","MRJ21","FC","LC","LC/PC","LC/UPC","LC/APC","LSH","LSH/PC","LSH/UPC","LSH/APC","MPO","MTRJ","SC","SC/PC","SC/UPC","SC/APC","ST","CS","SN","SMA 905","SMA 906","URM-P2","URM-P4","URM-P8","Splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -696,12 +696,24 @@ const ( // RearPortTypeLabelLC captures enum value "LC" RearPortTypeLabelLC string = "LC" + // RearPortTypeLabelLCPC captures enum value "LC/PC" + RearPortTypeLabelLCPC string = "LC/PC" + + // RearPortTypeLabelLCUPC captures enum value "LC/UPC" + RearPortTypeLabelLCUPC string = "LC/UPC" + // RearPortTypeLabelLCAPC captures enum value "LC/APC" RearPortTypeLabelLCAPC string = "LC/APC" // RearPortTypeLabelLSH captures enum value "LSH" RearPortTypeLabelLSH string = "LSH" + // RearPortTypeLabelLSHPC captures enum value "LSH/PC" + RearPortTypeLabelLSHPC string = "LSH/PC" + + // RearPortTypeLabelLSHUPC captures enum value "LSH/UPC" + RearPortTypeLabelLSHUPC string = "LSH/UPC" + // RearPortTypeLabelLSHAPC captures enum value "LSH/APC" RearPortTypeLabelLSHAPC string = "LSH/APC" @@ -714,6 +726,12 @@ const ( // RearPortTypeLabelSC captures enum value "SC" RearPortTypeLabelSC string = "SC" + // RearPortTypeLabelSCPC captures enum value "SC/PC" + RearPortTypeLabelSCPC string = "SC/PC" + + // RearPortTypeLabelSCUPC captures enum value "SC/UPC" + RearPortTypeLabelSCUPC string = "SC/UPC" + // RearPortTypeLabelSCAPC captures enum value "SC/APC" RearPortTypeLabelSCAPC string = "SC/APC" @@ -771,7 +789,7 @@ var rearPortTypeTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-apc","lsh","lsh-apc","mpo","mtrj","sc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-pc","lc-upc","lc-apc","lsh","lsh-pc","lsh-upc","lsh-apc","mpo","mtrj","sc","sc-pc","sc-upc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -841,12 +859,24 @@ const ( // RearPortTypeValueLc captures enum value "lc" RearPortTypeValueLc string = "lc" + // RearPortTypeValueLcDashPc captures enum value "lc-pc" + RearPortTypeValueLcDashPc string = "lc-pc" + + // RearPortTypeValueLcDashUpc captures enum value "lc-upc" + RearPortTypeValueLcDashUpc string = "lc-upc" + // RearPortTypeValueLcDashApc captures enum value "lc-apc" RearPortTypeValueLcDashApc string = "lc-apc" // RearPortTypeValueLsh captures enum value "lsh" RearPortTypeValueLsh string = "lsh" + // RearPortTypeValueLshDashPc captures enum value "lsh-pc" + RearPortTypeValueLshDashPc string = "lsh-pc" + + // RearPortTypeValueLshDashUpc captures enum value "lsh-upc" + RearPortTypeValueLshDashUpc string = "lsh-upc" + // RearPortTypeValueLshDashApc captures enum value "lsh-apc" RearPortTypeValueLshDashApc string = "lsh-apc" @@ -859,6 +889,12 @@ const ( // RearPortTypeValueSc captures enum value "sc" RearPortTypeValueSc string = "sc" + // RearPortTypeValueScDashPc captures enum value "sc-pc" + RearPortTypeValueScDashPc string = "sc-pc" + + // RearPortTypeValueScDashUpc captures enum value "sc-upc" + RearPortTypeValueScDashUpc string = "sc-upc" + // RearPortTypeValueScDashApc captures enum value "sc-apc" RearPortTypeValueScDashApc string = "sc-apc" diff --git a/netbox/models/rear_port_template.go b/netbox/models/rear_port_template.go index 7760cb1a..c762fcb4 100644 --- a/netbox/models/rear_port_template.go +++ b/netbox/models/rear_port_template.go @@ -432,12 +432,12 @@ type RearPortTemplateType struct { // label // Required: true - // Enum: [8P8C 8P6C 8P4C 8P2C 6P6C 6P4C 6P2C 4P4C 4P2C GG45 TERA 4P TERA 2P TERA 1P 110 Punch BNC F Connector N Connector MRJ21 FC LC LC/APC LSH LSH/APC MPO MTRJ SC SC/APC ST CS SN SMA 905 SMA 906 URM-P2 URM-P4 URM-P8 Splice] + // Enum: [8P8C 8P6C 8P4C 8P2C 6P6C 6P4C 6P2C 4P4C 4P2C GG45 TERA 4P TERA 2P TERA 1P 110 Punch BNC F Connector N Connector MRJ21 FC LC LC/PC LC/UPC LC/APC LSH LSH/PC LSH/UPC LSH/APC MPO MTRJ SC SC/PC SC/UPC SC/APC ST CS SN SMA 905 SMA 906 URM-P2 URM-P4 URM-P8 Splice] Label *string `json:"label"` // value // Required: true - // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-apc lsh lsh-apc mpo mtrj sc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] + // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-pc lc-upc lc-apc lsh lsh-pc lsh-upc lsh-apc mpo mtrj sc sc-pc sc-upc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] Value *string `json:"value"` } @@ -463,7 +463,7 @@ var rearPortTemplateTypeTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8P8C","8P6C","8P4C","8P2C","6P6C","6P4C","6P2C","4P4C","4P2C","GG45","TERA 4P","TERA 2P","TERA 1P","110 Punch","BNC","F Connector","N Connector","MRJ21","FC","LC","LC/APC","LSH","LSH/APC","MPO","MTRJ","SC","SC/APC","ST","CS","SN","SMA 905","SMA 906","URM-P2","URM-P4","URM-P8","Splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8P8C","8P6C","8P4C","8P2C","6P6C","6P4C","6P2C","4P4C","4P2C","GG45","TERA 4P","TERA 2P","TERA 1P","110 Punch","BNC","F Connector","N Connector","MRJ21","FC","LC","LC/PC","LC/UPC","LC/APC","LSH","LSH/PC","LSH/UPC","LSH/APC","MPO","MTRJ","SC","SC/PC","SC/UPC","SC/APC","ST","CS","SN","SMA 905","SMA 906","URM-P2","URM-P4","URM-P8","Splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -533,12 +533,24 @@ const ( // RearPortTemplateTypeLabelLC captures enum value "LC" RearPortTemplateTypeLabelLC string = "LC" + // RearPortTemplateTypeLabelLCPC captures enum value "LC/PC" + RearPortTemplateTypeLabelLCPC string = "LC/PC" + + // RearPortTemplateTypeLabelLCUPC captures enum value "LC/UPC" + RearPortTemplateTypeLabelLCUPC string = "LC/UPC" + // RearPortTemplateTypeLabelLCAPC captures enum value "LC/APC" RearPortTemplateTypeLabelLCAPC string = "LC/APC" // RearPortTemplateTypeLabelLSH captures enum value "LSH" RearPortTemplateTypeLabelLSH string = "LSH" + // RearPortTemplateTypeLabelLSHPC captures enum value "LSH/PC" + RearPortTemplateTypeLabelLSHPC string = "LSH/PC" + + // RearPortTemplateTypeLabelLSHUPC captures enum value "LSH/UPC" + RearPortTemplateTypeLabelLSHUPC string = "LSH/UPC" + // RearPortTemplateTypeLabelLSHAPC captures enum value "LSH/APC" RearPortTemplateTypeLabelLSHAPC string = "LSH/APC" @@ -551,6 +563,12 @@ const ( // RearPortTemplateTypeLabelSC captures enum value "SC" RearPortTemplateTypeLabelSC string = "SC" + // RearPortTemplateTypeLabelSCPC captures enum value "SC/PC" + RearPortTemplateTypeLabelSCPC string = "SC/PC" + + // RearPortTemplateTypeLabelSCUPC captures enum value "SC/UPC" + RearPortTemplateTypeLabelSCUPC string = "SC/UPC" + // RearPortTemplateTypeLabelSCAPC captures enum value "SC/APC" RearPortTemplateTypeLabelSCAPC string = "SC/APC" @@ -608,7 +626,7 @@ var rearPortTemplateTypeTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-apc","lsh","lsh-apc","mpo","mtrj","sc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-pc","lc-upc","lc-apc","lsh","lsh-pc","lsh-upc","lsh-apc","mpo","mtrj","sc","sc-pc","sc-upc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -678,12 +696,24 @@ const ( // RearPortTemplateTypeValueLc captures enum value "lc" RearPortTemplateTypeValueLc string = "lc" + // RearPortTemplateTypeValueLcDashPc captures enum value "lc-pc" + RearPortTemplateTypeValueLcDashPc string = "lc-pc" + + // RearPortTemplateTypeValueLcDashUpc captures enum value "lc-upc" + RearPortTemplateTypeValueLcDashUpc string = "lc-upc" + // RearPortTemplateTypeValueLcDashApc captures enum value "lc-apc" RearPortTemplateTypeValueLcDashApc string = "lc-apc" // RearPortTemplateTypeValueLsh captures enum value "lsh" RearPortTemplateTypeValueLsh string = "lsh" + // RearPortTemplateTypeValueLshDashPc captures enum value "lsh-pc" + RearPortTemplateTypeValueLshDashPc string = "lsh-pc" + + // RearPortTemplateTypeValueLshDashUpc captures enum value "lsh-upc" + RearPortTemplateTypeValueLshDashUpc string = "lsh-upc" + // RearPortTemplateTypeValueLshDashApc captures enum value "lsh-apc" RearPortTemplateTypeValueLshDashApc string = "lsh-apc" @@ -696,6 +726,12 @@ const ( // RearPortTemplateTypeValueSc captures enum value "sc" RearPortTemplateTypeValueSc string = "sc" + // RearPortTemplateTypeValueScDashPc captures enum value "sc-pc" + RearPortTemplateTypeValueScDashPc string = "sc-pc" + + // RearPortTemplateTypeValueScDashUpc captures enum value "sc-upc" + RearPortTemplateTypeValueScDashUpc string = "sc-upc" + // RearPortTemplateTypeValueScDashApc captures enum value "sc-apc" RearPortTemplateTypeValueScDashApc string = "sc-apc" diff --git a/netbox/models/region.go b/netbox/models/region.go index e33106eb..1db39000 100644 --- a/netbox/models/region.go +++ b/netbox/models/region.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -83,6 +84,9 @@ type Region struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -117,6 +121,10 @@ func (m *Region) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -220,6 +228,32 @@ func (m *Region) validateSlug(formats strfmt.Registry) error { return nil } +func (m *Region) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *Region) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -264,6 +298,10 @@ func (m *Region) ContextValidate(ctx context.Context, formats strfmt.Registry) e res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -344,6 +382,26 @@ func (m *Region) contextValidateSiteCount(ctx context.Context, formats strfmt.Re return nil } +func (m *Region) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *Region) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/role.go b/netbox/models/role.go index 6acfdeaf..67ff5f40 100644 --- a/netbox/models/role.go +++ b/netbox/models/role.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -76,6 +77,9 @@ type Role struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -115,6 +119,10 @@ func (m *Role) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -203,6 +211,32 @@ func (m *Role) validateSlug(formats strfmt.Registry) error { return nil } +func (m *Role) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *Role) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -255,6 +289,10 @@ func (m *Role) ContextValidate(ctx context.Context, formats strfmt.Registry) err res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -314,6 +352,26 @@ func (m *Role) contextValidatePrefixCount(ctx context.Context, formats strfmt.Re return nil } +func (m *Role) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *Role) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/service.go b/netbox/models/service.go index 417de087..8b1c5163 100644 --- a/netbox/models/service.go +++ b/netbox/models/service.go @@ -554,12 +554,12 @@ type ServiceProtocol struct { // label // Required: true - // Enum: [TCP UDP] + // Enum: [TCP UDP SCTP] Label *string `json:"label"` // value // Required: true - // Enum: [tcp udp] + // Enum: [tcp udp sctp] Value *string `json:"value"` } @@ -585,7 +585,7 @@ var serviceProtocolTypeLabelPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["TCP","UDP"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["TCP","UDP","SCTP"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -600,6 +600,9 @@ const ( // ServiceProtocolLabelUDP captures enum value "UDP" ServiceProtocolLabelUDP string = "UDP" + + // ServiceProtocolLabelSCTP captures enum value "SCTP" + ServiceProtocolLabelSCTP string = "SCTP" ) // prop value enum @@ -628,7 +631,7 @@ var serviceProtocolTypeValuePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["tcp","udp"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["tcp","udp","sctp"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -643,6 +646,9 @@ const ( // ServiceProtocolValueUDP captures enum value "udp" ServiceProtocolValueUDP string = "udp" + + // ServiceProtocolValueSctp captures enum value "sctp" + ServiceProtocolValueSctp string = "sctp" ) // prop value enum diff --git a/netbox/models/site.go b/netbox/models/site.go index 208627c2..a821ee18 100644 --- a/netbox/models/site.go +++ b/netbox/models/site.go @@ -43,6 +43,10 @@ type Site struct { // Minimum: 1 Asn *int64 `json:"asn,omitempty"` + // asns + // Unique: true + Asns []*NestedASN `json:"asns"` + // Circuit count // Read Only: true CircuitCount int64 `json:"circuit_count,omitempty"` @@ -177,6 +181,10 @@ func (m *Site) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateAsns(formats); err != nil { + res = append(res, err) + } + if err := m.validateContactEmail(formats); err != nil { res = append(res, err) } @@ -267,6 +275,36 @@ func (m *Site) validateAsn(formats strfmt.Registry) error { return nil } +func (m *Site) validateAsns(formats strfmt.Registry) error { + if swag.IsZero(m.Asns) { // not required + return nil + } + + if err := validate.UniqueItems("asns", "body", m.Asns); err != nil { + return err + } + + for i := 0; i < len(m.Asns); i++ { + if swag.IsZero(m.Asns[i]) { // not required + continue + } + + if m.Asns[i] != nil { + if err := m.Asns[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("asns" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("asns" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *Site) validateContactEmail(formats strfmt.Registry) error { if swag.IsZero(m.ContactEmail) { // not required return nil @@ -535,6 +573,10 @@ func (m *Site) validateURL(formats strfmt.Registry) error { func (m *Site) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateAsns(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateCircuitCount(ctx, formats); err != nil { res = append(res, err) } @@ -605,6 +647,26 @@ func (m *Site) ContextValidate(ctx context.Context, formats strfmt.Registry) err return nil } +func (m *Site) contextValidateAsns(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Asns); i++ { + + if m.Asns[i] != nil { + if err := m.Asns[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("asns" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("asns" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *Site) contextValidateCircuitCount(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "circuit_count", "body", int64(m.CircuitCount)); err != nil { diff --git a/netbox/models/site_group.go b/netbox/models/site_group.go index 023b9f42..ad59c58e 100644 --- a/netbox/models/site_group.go +++ b/netbox/models/site_group.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -83,6 +84,9 @@ type SiteGroup struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -117,6 +121,10 @@ func (m *SiteGroup) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -220,6 +228,32 @@ func (m *SiteGroup) validateSlug(formats strfmt.Registry) error { return nil } +func (m *SiteGroup) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *SiteGroup) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -264,6 +298,10 @@ func (m *SiteGroup) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -344,6 +382,26 @@ func (m *SiteGroup) contextValidateSiteCount(ctx context.Context, formats strfmt return nil } +func (m *SiteGroup) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *SiteGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/tag.go b/netbox/models/tag.go index f56dd738..8c598dbb 100644 --- a/netbox/models/tag.go +++ b/netbox/models/tag.go @@ -40,6 +40,11 @@ type Tag struct { // Pattern: ^[0-9a-f]{6}$ Color string `json:"color,omitempty"` + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Description // Max Length: 200 Description string `json:"description,omitempty"` @@ -52,6 +57,11 @@ type Tag struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Name // Required: true // Max Length: 100 @@ -83,10 +93,18 @@ func (m *Tag) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateDescription(formats); err != nil { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateName(formats); err != nil { res = append(res, err) } @@ -125,6 +143,18 @@ func (m *Tag) validateColor(formats strfmt.Registry) error { return nil } +func (m *Tag) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *Tag) validateDescription(formats strfmt.Registry) error { if swag.IsZero(m.Description) { // not required return nil @@ -137,6 +167,18 @@ func (m *Tag) validateDescription(formats strfmt.Registry) error { return nil } +func (m *Tag) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *Tag) validateName(formats strfmt.Registry) error { if err := validate.Required("name", "body", m.Name); err != nil { @@ -191,6 +233,10 @@ func (m *Tag) validateURL(formats strfmt.Registry) error { func (m *Tag) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -199,6 +245,10 @@ func (m *Tag) ContextValidate(ctx context.Context, formats strfmt.Registry) erro res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTaggedItems(ctx, formats); err != nil { res = append(res, err) } @@ -213,6 +263,15 @@ func (m *Tag) ContextValidate(ctx context.Context, formats strfmt.Registry) erro return nil } +func (m *Tag) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *Tag) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -231,6 +290,15 @@ func (m *Tag) contextValidateID(ctx context.Context, formats strfmt.Registry) er return nil } +func (m *Tag) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *Tag) contextValidateTaggedItems(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "tagged_items", "body", int64(m.TaggedItems)); err != nil { diff --git a/netbox/models/tenant_group.go b/netbox/models/tenant_group.go index 5aa641a8..3c6a75e7 100644 --- a/netbox/models/tenant_group.go +++ b/netbox/models/tenant_group.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -79,6 +80,9 @@ type TenantGroup struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Tenant count // Read Only: true TenantCount int64 `json:"tenant_count,omitempty"` @@ -117,6 +121,10 @@ func (m *TenantGroup) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -220,6 +228,32 @@ func (m *TenantGroup) validateSlug(formats strfmt.Registry) error { return nil } +func (m *TenantGroup) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *TenantGroup) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -260,6 +294,10 @@ func (m *TenantGroup) ContextValidate(ctx context.Context, formats strfmt.Regist res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTenantCount(ctx, formats); err != nil { res = append(res, err) } @@ -335,6 +373,26 @@ func (m *TenantGroup) contextValidateParent(ctx context.Context, formats strfmt. return nil } +func (m *TenantGroup) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *TenantGroup) contextValidateTenantCount(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "tenant_count", "body", int64(m.TenantCount)); err != nil { diff --git a/netbox/models/v_l_a_n_group.go b/netbox/models/v_l_a_n_group.go index 7715b0ee..301748e0 100644 --- a/netbox/models/v_l_a_n_group.go +++ b/netbox/models/v_l_a_n_group.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -70,7 +71,6 @@ type VLANGroup struct { Scope string `json:"scope,omitempty"` // Scope id - // Minimum: 0 ScopeID *int64 `json:"scope_id,omitempty"` // Scope type @@ -83,6 +83,9 @@ type VLANGroup struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -113,11 +116,11 @@ func (m *VLANGroup) Validate(formats strfmt.Registry) error { res = append(res, err) } - if err := m.validateScopeID(formats); err != nil { + if err := m.validateSlug(formats); err != nil { res = append(res, err) } - if err := m.validateSlug(formats); err != nil { + if err := m.validateTags(formats); err != nil { res = append(res, err) } @@ -184,18 +187,6 @@ func (m *VLANGroup) validateName(formats strfmt.Registry) error { return nil } -func (m *VLANGroup) validateScopeID(formats strfmt.Registry) error { - if swag.IsZero(m.ScopeID) { // not required - return nil - } - - if err := validate.MinimumInt("scope_id", "body", *m.ScopeID, 0, false); err != nil { - return err - } - - return nil -} - func (m *VLANGroup) validateSlug(formats strfmt.Registry) error { if err := validate.Required("slug", "body", m.Slug); err != nil { @@ -217,6 +208,32 @@ func (m *VLANGroup) validateSlug(formats strfmt.Registry) error { return nil } +func (m *VLANGroup) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *VLANGroup) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -253,6 +270,10 @@ func (m *VLANGroup) ContextValidate(ctx context.Context, formats strfmt.Registry res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -312,6 +333,26 @@ func (m *VLANGroup) contextValidateScope(ctx context.Context, formats strfmt.Reg return nil } +func (m *VLANGroup) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *VLANGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/virtual_chassis.go b/netbox/models/virtual_chassis.go index 0c685e51..c5ff5b84 100644 --- a/netbox/models/virtual_chassis.go +++ b/netbox/models/virtual_chassis.go @@ -35,6 +35,11 @@ import ( // swagger:model VirtualChassis type VirtualChassis struct { + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Custom fields CustomFields interface{} `json:"custom_fields,omitempty"` @@ -50,6 +55,11 @@ type VirtualChassis struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // master Master *NestedDevice `json:"master,omitempty"` @@ -76,10 +86,18 @@ type VirtualChassis struct { func (m *VirtualChassis) Validate(formats strfmt.Registry) error { var res []error + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateDomain(formats); err != nil { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateMaster(formats); err != nil { res = append(res, err) } @@ -102,6 +120,18 @@ func (m *VirtualChassis) Validate(formats strfmt.Registry) error { return nil } +func (m *VirtualChassis) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *VirtualChassis) validateDomain(formats strfmt.Registry) error { if swag.IsZero(m.Domain) { // not required return nil @@ -114,6 +144,18 @@ func (m *VirtualChassis) validateDomain(formats strfmt.Registry) error { return nil } +func (m *VirtualChassis) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *VirtualChassis) validateMaster(formats strfmt.Registry) error { if swag.IsZero(m.Master) { // not required return nil @@ -192,6 +234,10 @@ func (m *VirtualChassis) validateURL(formats strfmt.Registry) error { func (m *VirtualChassis) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -200,6 +246,10 @@ func (m *VirtualChassis) ContextValidate(ctx context.Context, formats strfmt.Reg res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateMaster(ctx, formats); err != nil { res = append(res, err) } @@ -222,6 +272,15 @@ func (m *VirtualChassis) ContextValidate(ctx context.Context, formats strfmt.Reg return nil } +func (m *VirtualChassis) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *VirtualChassis) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -240,6 +299,15 @@ func (m *VirtualChassis) contextValidateID(ctx context.Context, formats strfmt.R return nil } +func (m *VirtualChassis) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *VirtualChassis) contextValidateMaster(ctx context.Context, formats strfmt.Registry) error { if m.Master != nil { diff --git a/netbox/models/vm_interface.go b/netbox/models/vm_interface.go index 12cf99b3..80d6e4dc 100644 --- a/netbox/models/vm_interface.go +++ b/netbox/models/vm_interface.go @@ -36,6 +36,13 @@ import ( // swagger:model VMInterface type VMInterface struct { + // bridge + Bridge *NestedVMInterface `json:"bridge,omitempty"` + + // Count fhrp groups + // Read Only: true + CountFhrpGroups int64 `json:"count_fhrp_groups,omitempty"` + // Count ipaddresses // Read Only: true CountIpaddresses int64 `json:"count_ipaddresses,omitempty"` @@ -112,6 +119,10 @@ type VMInterface struct { func (m *VMInterface) Validate(formats strfmt.Registry) error { var res []error + if err := m.validateBridge(formats); err != nil { + res = append(res, err) + } + if err := m.validateCreated(formats); err != nil { res = append(res, err) } @@ -166,6 +177,25 @@ func (m *VMInterface) Validate(formats strfmt.Registry) error { return nil } +func (m *VMInterface) validateBridge(formats strfmt.Registry) error { + if swag.IsZero(m.Bridge) { // not required + return nil + } + + if m.Bridge != nil { + if err := m.Bridge.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("bridge") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("bridge") + } + return err + } + } + + return nil +} + func (m *VMInterface) validateCreated(formats strfmt.Registry) error { if swag.IsZero(m.Created) { // not required return nil @@ -384,6 +414,14 @@ func (m *VMInterface) validateVirtualMachine(formats strfmt.Registry) error { func (m *VMInterface) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateBridge(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateCountFhrpGroups(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateCountIpaddresses(ctx, formats); err != nil { res = append(res, err) } @@ -438,6 +476,31 @@ func (m *VMInterface) ContextValidate(ctx context.Context, formats strfmt.Regist return nil } +func (m *VMInterface) contextValidateBridge(ctx context.Context, formats strfmt.Registry) error { + + if m.Bridge != nil { + if err := m.Bridge.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("bridge") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("bridge") + } + return err + } + } + + return nil +} + +func (m *VMInterface) contextValidateCountFhrpGroups(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "count_fhrp_groups", "body", int64(m.CountFhrpGroups)); err != nil { + return err + } + + return nil +} + func (m *VMInterface) contextValidateCountIpaddresses(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "count_ipaddresses", "body", int64(m.CountIpaddresses)); err != nil { diff --git a/netbox/models/webhook.go b/netbox/models/webhook.go index ddee5e46..020c158d 100644 --- a/netbox/models/webhook.go +++ b/netbox/models/webhook.go @@ -51,11 +51,21 @@ type Webhook struct { // Max Length: 4096 CaFilePath *string `json:"ca_file_path,omitempty"` + // Conditions + // + // A set of conditions which determine whether the webhook will be generated. + Conditions *string `json:"conditions,omitempty"` + // content types // Required: true // Unique: true ContentTypes []string `json:"content_types"` + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Display // Read Only: true Display string `json:"display,omitempty"` @@ -78,6 +88,11 @@ type Webhook struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Name // Required: true // Max Length: 150 @@ -136,6 +151,10 @@ func (m *Webhook) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateHTTPContentType(formats); err != nil { res = append(res, err) } @@ -144,6 +163,10 @@ func (m *Webhook) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateName(formats); err != nil { res = append(res, err) } @@ -191,6 +214,18 @@ func (m *Webhook) validateContentTypes(formats strfmt.Registry) error { return nil } +func (m *Webhook) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *Webhook) validateHTTPContentType(formats strfmt.Registry) error { if swag.IsZero(m.HTTPContentType) { // not required return nil @@ -258,6 +293,18 @@ func (m *Webhook) validateHTTPMethod(formats strfmt.Registry) error { return nil } +func (m *Webhook) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *Webhook) validateName(formats strfmt.Registry) error { if err := validate.Required("name", "body", m.Name); err != nil { @@ -320,6 +367,10 @@ func (m *Webhook) validateURL(formats strfmt.Registry) error { func (m *Webhook) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -328,6 +379,10 @@ func (m *Webhook) ContextValidate(ctx context.Context, formats strfmt.Registry) res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -338,6 +393,15 @@ func (m *Webhook) ContextValidate(ctx context.Context, formats strfmt.Registry) return nil } +func (m *Webhook) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *Webhook) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -356,6 +420,15 @@ func (m *Webhook) contextValidateID(ctx context.Context, formats strfmt.Registry return nil } +func (m *Webhook) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *Webhook) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/wireless_l_a_n.go b/netbox/models/wireless_l_a_n.go new file mode 100644 index 00000000..4bc29b5a --- /dev/null +++ b/netbox/models/wireless_l_a_n.go @@ -0,0 +1,827 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "encoding/json" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WirelessLAN wireless l a n +// +// swagger:model WirelessLAN +type WirelessLAN struct { + + // auth cipher + AuthCipher *WirelessLANAuthCipher `json:"auth_cipher,omitempty"` + + // Pre-shared key + // Max Length: 64 + AuthPsk string `json:"auth_psk,omitempty"` + + // auth type + AuthType *WirelessLANAuthType `json:"auth_type,omitempty"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // group + Group *NestedWirelessLANGroup `json:"group,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // SSID + // Required: true + // Max Length: 32 + // Min Length: 1 + Ssid *string `json:"ssid"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` + + // vlan + Vlan *NestedVLAN `json:"vlan,omitempty"` +} + +// Validate validates this wireless l a n +func (m *WirelessLAN) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAuthCipher(formats); err != nil { + res = append(res, err) + } + + if err := m.validateAuthPsk(formats); err != nil { + res = append(res, err) + } + + if err := m.validateAuthType(formats); err != nil { + res = append(res, err) + } + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateGroup(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSsid(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if err := m.validateVlan(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WirelessLAN) validateAuthCipher(formats strfmt.Registry) error { + if swag.IsZero(m.AuthCipher) { // not required + return nil + } + + if m.AuthCipher != nil { + if err := m.AuthCipher.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("auth_cipher") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("auth_cipher") + } + return err + } + } + + return nil +} + +func (m *WirelessLAN) validateAuthPsk(formats strfmt.Registry) error { + if swag.IsZero(m.AuthPsk) { // not required + return nil + } + + if err := validate.MaxLength("auth_psk", "body", m.AuthPsk, 64); err != nil { + return err + } + + return nil +} + +func (m *WirelessLAN) validateAuthType(formats strfmt.Registry) error { + if swag.IsZero(m.AuthType) { // not required + return nil + } + + if m.AuthType != nil { + if err := m.AuthType.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("auth_type") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("auth_type") + } + return err + } + } + + return nil +} + +func (m *WirelessLAN) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WirelessLAN) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *WirelessLAN) validateGroup(formats strfmt.Registry) error { + if swag.IsZero(m.Group) { // not required + return nil + } + + if m.Group != nil { + if err := m.Group.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("group") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("group") + } + return err + } + } + + return nil +} + +func (m *WirelessLAN) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WirelessLAN) validateSsid(formats strfmt.Registry) error { + + if err := validate.Required("ssid", "body", m.Ssid); err != nil { + return err + } + + if err := validate.MinLength("ssid", "body", *m.Ssid, 1); err != nil { + return err + } + + if err := validate.MaxLength("ssid", "body", *m.Ssid, 32); err != nil { + return err + } + + return nil +} + +func (m *WirelessLAN) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WirelessLAN) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WirelessLAN) validateVlan(formats strfmt.Registry) error { + if swag.IsZero(m.Vlan) { // not required + return nil + } + + if m.Vlan != nil { + if err := m.Vlan.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("vlan") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("vlan") + } + return err + } + } + + return nil +} + +// ContextValidate validate this wireless l a n based on the context it is used +func (m *WirelessLAN) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateAuthCipher(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateAuthType(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateGroup(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateVlan(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WirelessLAN) contextValidateAuthCipher(ctx context.Context, formats strfmt.Registry) error { + + if m.AuthCipher != nil { + if err := m.AuthCipher.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("auth_cipher") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("auth_cipher") + } + return err + } + } + + return nil +} + +func (m *WirelessLAN) contextValidateAuthType(ctx context.Context, formats strfmt.Registry) error { + + if m.AuthType != nil { + if err := m.AuthType.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("auth_type") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("auth_type") + } + return err + } + } + + return nil +} + +func (m *WirelessLAN) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLAN) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLAN) contextValidateGroup(ctx context.Context, formats strfmt.Registry) error { + + if m.Group != nil { + if err := m.Group.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("group") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("group") + } + return err + } + } + + return nil +} + +func (m *WirelessLAN) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLAN) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLAN) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WirelessLAN) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLAN) contextValidateVlan(ctx context.Context, formats strfmt.Registry) error { + + if m.Vlan != nil { + if err := m.Vlan.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("vlan") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("vlan") + } + return err + } + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WirelessLAN) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WirelessLAN) UnmarshalBinary(b []byte) error { + var res WirelessLAN + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + +// WirelessLANAuthCipher Auth cipher +// +// swagger:model WirelessLANAuthCipher +type WirelessLANAuthCipher struct { + + // label + // Required: true + // Enum: [Auto TKIP AES] + Label *string `json:"label"` + + // value + // Required: true + // Enum: [auto tkip aes] + Value *string `json:"value"` +} + +// Validate validates this wireless l a n auth cipher +func (m *WirelessLANAuthCipher) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateLabel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateValue(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var wirelessLANAuthCipherTypeLabelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["Auto","TKIP","AES"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + wirelessLANAuthCipherTypeLabelPropEnum = append(wirelessLANAuthCipherTypeLabelPropEnum, v) + } +} + +const ( + + // WirelessLANAuthCipherLabelAuto captures enum value "Auto" + WirelessLANAuthCipherLabelAuto string = "Auto" + + // WirelessLANAuthCipherLabelTKIP captures enum value "TKIP" + WirelessLANAuthCipherLabelTKIP string = "TKIP" + + // WirelessLANAuthCipherLabelAES captures enum value "AES" + WirelessLANAuthCipherLabelAES string = "AES" +) + +// prop value enum +func (m *WirelessLANAuthCipher) validateLabelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, wirelessLANAuthCipherTypeLabelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WirelessLANAuthCipher) validateLabel(formats strfmt.Registry) error { + + if err := validate.Required("auth_cipher"+"."+"label", "body", m.Label); err != nil { + return err + } + + // value enum + if err := m.validateLabelEnum("auth_cipher"+"."+"label", "body", *m.Label); err != nil { + return err + } + + return nil +} + +var wirelessLANAuthCipherTypeValuePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["auto","tkip","aes"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + wirelessLANAuthCipherTypeValuePropEnum = append(wirelessLANAuthCipherTypeValuePropEnum, v) + } +} + +const ( + + // WirelessLANAuthCipherValueAuto captures enum value "auto" + WirelessLANAuthCipherValueAuto string = "auto" + + // WirelessLANAuthCipherValueTkip captures enum value "tkip" + WirelessLANAuthCipherValueTkip string = "tkip" + + // WirelessLANAuthCipherValueAes captures enum value "aes" + WirelessLANAuthCipherValueAes string = "aes" +) + +// prop value enum +func (m *WirelessLANAuthCipher) validateValueEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, wirelessLANAuthCipherTypeValuePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WirelessLANAuthCipher) validateValue(formats strfmt.Registry) error { + + if err := validate.Required("auth_cipher"+"."+"value", "body", m.Value); err != nil { + return err + } + + // value enum + if err := m.validateValueEnum("auth_cipher"+"."+"value", "body", *m.Value); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this wireless l a n auth cipher based on context it is used +func (m *WirelessLANAuthCipher) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *WirelessLANAuthCipher) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WirelessLANAuthCipher) UnmarshalBinary(b []byte) error { + var res WirelessLANAuthCipher + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + +// WirelessLANAuthType Auth type +// +// swagger:model WirelessLANAuthType +type WirelessLANAuthType struct { + + // label + // Required: true + // Enum: [Open WEP WPA Personal (PSK) WPA Enterprise] + Label *string `json:"label"` + + // value + // Required: true + // Enum: [open wep wpa-personal wpa-enterprise] + Value *string `json:"value"` +} + +// Validate validates this wireless l a n auth type +func (m *WirelessLANAuthType) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateLabel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateValue(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var wirelessLANAuthTypeTypeLabelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["Open","WEP","WPA Personal (PSK)","WPA Enterprise"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + wirelessLANAuthTypeTypeLabelPropEnum = append(wirelessLANAuthTypeTypeLabelPropEnum, v) + } +} + +const ( + + // WirelessLANAuthTypeLabelOpen captures enum value "Open" + WirelessLANAuthTypeLabelOpen string = "Open" + + // WirelessLANAuthTypeLabelWEP captures enum value "WEP" + WirelessLANAuthTypeLabelWEP string = "WEP" + + // WirelessLANAuthTypeLabelWPAPersonalPSK captures enum value "WPA Personal (PSK)" + WirelessLANAuthTypeLabelWPAPersonalPSK string = "WPA Personal (PSK)" + + // WirelessLANAuthTypeLabelWPAEnterprise captures enum value "WPA Enterprise" + WirelessLANAuthTypeLabelWPAEnterprise string = "WPA Enterprise" +) + +// prop value enum +func (m *WirelessLANAuthType) validateLabelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, wirelessLANAuthTypeTypeLabelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WirelessLANAuthType) validateLabel(formats strfmt.Registry) error { + + if err := validate.Required("auth_type"+"."+"label", "body", m.Label); err != nil { + return err + } + + // value enum + if err := m.validateLabelEnum("auth_type"+"."+"label", "body", *m.Label); err != nil { + return err + } + + return nil +} + +var wirelessLANAuthTypeTypeValuePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["open","wep","wpa-personal","wpa-enterprise"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + wirelessLANAuthTypeTypeValuePropEnum = append(wirelessLANAuthTypeTypeValuePropEnum, v) + } +} + +const ( + + // WirelessLANAuthTypeValueOpen captures enum value "open" + WirelessLANAuthTypeValueOpen string = "open" + + // WirelessLANAuthTypeValueWep captures enum value "wep" + WirelessLANAuthTypeValueWep string = "wep" + + // WirelessLANAuthTypeValueWpaDashPersonal captures enum value "wpa-personal" + WirelessLANAuthTypeValueWpaDashPersonal string = "wpa-personal" + + // WirelessLANAuthTypeValueWpaDashEnterprise captures enum value "wpa-enterprise" + WirelessLANAuthTypeValueWpaDashEnterprise string = "wpa-enterprise" +) + +// prop value enum +func (m *WirelessLANAuthType) validateValueEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, wirelessLANAuthTypeTypeValuePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WirelessLANAuthType) validateValue(formats strfmt.Registry) error { + + if err := validate.Required("auth_type"+"."+"value", "body", m.Value); err != nil { + return err + } + + // value enum + if err := m.validateValueEnum("auth_type"+"."+"value", "body", *m.Value); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this wireless l a n auth type based on context it is used +func (m *WirelessLANAuthType) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *WirelessLANAuthType) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WirelessLANAuthType) UnmarshalBinary(b []byte) error { + var res WirelessLANAuthType + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/wireless_l_a_n_group.go b/netbox/models/wireless_l_a_n_group.go new file mode 100644 index 00000000..b5b20f36 --- /dev/null +++ b/netbox/models/wireless_l_a_n_group.go @@ -0,0 +1,430 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WirelessLANGroup wireless l a n group +// +// swagger:model WirelessLANGroup +type WirelessLANGroup struct { + + // depth + // Read Only: true + Depth int64 `json:"_depth,omitempty"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Name + // Required: true + // Max Length: 100 + // Min Length: 1 + Name *string `json:"name"` + + // parent + Parent *NestedWirelessLANGroup `json:"parent,omitempty"` + + // Slug + // Required: true + // Max Length: 100 + // Min Length: 1 + // Pattern: ^[-a-zA-Z0-9_]+$ + Slug *string `json:"slug"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` + + // Wirelesslan count + // Read Only: true + WirelesslanCount int64 `json:"wirelesslan_count,omitempty"` +} + +// Validate validates this wireless l a n group +func (m *WirelessLANGroup) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateName(formats); err != nil { + res = append(res, err) + } + + if err := m.validateParent(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSlug(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WirelessLANGroup) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WirelessLANGroup) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *WirelessLANGroup) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WirelessLANGroup) validateName(formats strfmt.Registry) error { + + if err := validate.Required("name", "body", m.Name); err != nil { + return err + } + + if err := validate.MinLength("name", "body", *m.Name, 1); err != nil { + return err + } + + if err := validate.MaxLength("name", "body", *m.Name, 100); err != nil { + return err + } + + return nil +} + +func (m *WirelessLANGroup) validateParent(formats strfmt.Registry) error { + if swag.IsZero(m.Parent) { // not required + return nil + } + + if m.Parent != nil { + if err := m.Parent.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("parent") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("parent") + } + return err + } + } + + return nil +} + +func (m *WirelessLANGroup) validateSlug(formats strfmt.Registry) error { + + if err := validate.Required("slug", "body", m.Slug); err != nil { + return err + } + + if err := validate.MinLength("slug", "body", *m.Slug, 1); err != nil { + return err + } + + if err := validate.MaxLength("slug", "body", *m.Slug, 100); err != nil { + return err + } + + if err := validate.Pattern("slug", "body", *m.Slug, `^[-a-zA-Z0-9_]+$`); err != nil { + return err + } + + return nil +} + +func (m *WirelessLANGroup) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WirelessLANGroup) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this wireless l a n group based on the context it is used +func (m *WirelessLANGroup) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDepth(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateParent(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateWirelesslanCount(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WirelessLANGroup) contextValidateDepth(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "_depth", "body", int64(m.Depth)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLANGroup) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLANGroup) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLANGroup) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLANGroup) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLANGroup) contextValidateParent(ctx context.Context, formats strfmt.Registry) error { + + if m.Parent != nil { + if err := m.Parent.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("parent") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("parent") + } + return err + } + } + + return nil +} + +func (m *WirelessLANGroup) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WirelessLANGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLANGroup) contextValidateWirelesslanCount(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "wirelesslan_count", "body", int64(m.WirelesslanCount)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WirelessLANGroup) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WirelessLANGroup) UnmarshalBinary(b []byte) error { + var res WirelessLANGroup + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/wireless_link.go b/netbox/models/wireless_link.go new file mode 100644 index 00000000..1c865080 --- /dev/null +++ b/netbox/models/wireless_link.go @@ -0,0 +1,1019 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "encoding/json" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WirelessLink wireless link +// +// swagger:model WirelessLink +type WirelessLink struct { + + // auth cipher + AuthCipher *WirelessLinkAuthCipher `json:"auth_cipher,omitempty"` + + // Pre-shared key + // Max Length: 64 + AuthPsk string `json:"auth_psk,omitempty"` + + // auth type + AuthType *WirelessLinkAuthType `json:"auth_type,omitempty"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // interface a + // Required: true + Interfacea *NestedInterface `json:"interface_a"` + + // interface b + // Required: true + Interfaceb *NestedInterface `json:"interface_b"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // SSID + // Max Length: 32 + Ssid string `json:"ssid,omitempty"` + + // status + Status *WirelessLinkStatus `json:"status,omitempty"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this wireless link +func (m *WirelessLink) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAuthCipher(formats); err != nil { + res = append(res, err) + } + + if err := m.validateAuthPsk(formats); err != nil { + res = append(res, err) + } + + if err := m.validateAuthType(formats); err != nil { + res = append(res, err) + } + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateInterfacea(formats); err != nil { + res = append(res, err) + } + + if err := m.validateInterfaceb(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSsid(formats); err != nil { + res = append(res, err) + } + + if err := m.validateStatus(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WirelessLink) validateAuthCipher(formats strfmt.Registry) error { + if swag.IsZero(m.AuthCipher) { // not required + return nil + } + + if m.AuthCipher != nil { + if err := m.AuthCipher.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("auth_cipher") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("auth_cipher") + } + return err + } + } + + return nil +} + +func (m *WirelessLink) validateAuthPsk(formats strfmt.Registry) error { + if swag.IsZero(m.AuthPsk) { // not required + return nil + } + + if err := validate.MaxLength("auth_psk", "body", m.AuthPsk, 64); err != nil { + return err + } + + return nil +} + +func (m *WirelessLink) validateAuthType(formats strfmt.Registry) error { + if swag.IsZero(m.AuthType) { // not required + return nil + } + + if m.AuthType != nil { + if err := m.AuthType.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("auth_type") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("auth_type") + } + return err + } + } + + return nil +} + +func (m *WirelessLink) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WirelessLink) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *WirelessLink) validateInterfacea(formats strfmt.Registry) error { + + if err := validate.Required("interface_a", "body", m.Interfacea); err != nil { + return err + } + + if m.Interfacea != nil { + if err := m.Interfacea.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("interface_a") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("interface_a") + } + return err + } + } + + return nil +} + +func (m *WirelessLink) validateInterfaceb(formats strfmt.Registry) error { + + if err := validate.Required("interface_b", "body", m.Interfaceb); err != nil { + return err + } + + if m.Interfaceb != nil { + if err := m.Interfaceb.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("interface_b") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("interface_b") + } + return err + } + } + + return nil +} + +func (m *WirelessLink) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WirelessLink) validateSsid(formats strfmt.Registry) error { + if swag.IsZero(m.Ssid) { // not required + return nil + } + + if err := validate.MaxLength("ssid", "body", m.Ssid, 32); err != nil { + return err + } + + return nil +} + +func (m *WirelessLink) validateStatus(formats strfmt.Registry) error { + if swag.IsZero(m.Status) { // not required + return nil + } + + if m.Status != nil { + if err := m.Status.Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("status") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("status") + } + return err + } + } + + return nil +} + +func (m *WirelessLink) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WirelessLink) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this wireless link based on the context it is used +func (m *WirelessLink) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateAuthCipher(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateAuthType(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateInterfacea(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateInterfaceb(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateStatus(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WirelessLink) contextValidateAuthCipher(ctx context.Context, formats strfmt.Registry) error { + + if m.AuthCipher != nil { + if err := m.AuthCipher.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("auth_cipher") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("auth_cipher") + } + return err + } + } + + return nil +} + +func (m *WirelessLink) contextValidateAuthType(ctx context.Context, formats strfmt.Registry) error { + + if m.AuthType != nil { + if err := m.AuthType.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("auth_type") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("auth_type") + } + return err + } + } + + return nil +} + +func (m *WirelessLink) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLink) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLink) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLink) contextValidateInterfacea(ctx context.Context, formats strfmt.Registry) error { + + if m.Interfacea != nil { + if err := m.Interfacea.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("interface_a") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("interface_a") + } + return err + } + } + + return nil +} + +func (m *WirelessLink) contextValidateInterfaceb(ctx context.Context, formats strfmt.Registry) error { + + if m.Interfaceb != nil { + if err := m.Interfaceb.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("interface_b") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("interface_b") + } + return err + } + } + + return nil +} + +func (m *WirelessLink) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WirelessLink) contextValidateStatus(ctx context.Context, formats strfmt.Registry) error { + + if m.Status != nil { + if err := m.Status.ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("status") + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("status") + } + return err + } + } + + return nil +} + +func (m *WirelessLink) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WirelessLink) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WirelessLink) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WirelessLink) UnmarshalBinary(b []byte) error { + var res WirelessLink + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + +// WirelessLinkAuthCipher Auth cipher +// +// swagger:model WirelessLinkAuthCipher +type WirelessLinkAuthCipher struct { + + // label + // Required: true + // Enum: [Auto TKIP AES] + Label *string `json:"label"` + + // value + // Required: true + // Enum: [auto tkip aes] + Value *string `json:"value"` +} + +// Validate validates this wireless link auth cipher +func (m *WirelessLinkAuthCipher) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateLabel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateValue(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var wirelessLinkAuthCipherTypeLabelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["Auto","TKIP","AES"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + wirelessLinkAuthCipherTypeLabelPropEnum = append(wirelessLinkAuthCipherTypeLabelPropEnum, v) + } +} + +const ( + + // WirelessLinkAuthCipherLabelAuto captures enum value "Auto" + WirelessLinkAuthCipherLabelAuto string = "Auto" + + // WirelessLinkAuthCipherLabelTKIP captures enum value "TKIP" + WirelessLinkAuthCipherLabelTKIP string = "TKIP" + + // WirelessLinkAuthCipherLabelAES captures enum value "AES" + WirelessLinkAuthCipherLabelAES string = "AES" +) + +// prop value enum +func (m *WirelessLinkAuthCipher) validateLabelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, wirelessLinkAuthCipherTypeLabelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WirelessLinkAuthCipher) validateLabel(formats strfmt.Registry) error { + + if err := validate.Required("auth_cipher"+"."+"label", "body", m.Label); err != nil { + return err + } + + // value enum + if err := m.validateLabelEnum("auth_cipher"+"."+"label", "body", *m.Label); err != nil { + return err + } + + return nil +} + +var wirelessLinkAuthCipherTypeValuePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["auto","tkip","aes"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + wirelessLinkAuthCipherTypeValuePropEnum = append(wirelessLinkAuthCipherTypeValuePropEnum, v) + } +} + +const ( + + // WirelessLinkAuthCipherValueAuto captures enum value "auto" + WirelessLinkAuthCipherValueAuto string = "auto" + + // WirelessLinkAuthCipherValueTkip captures enum value "tkip" + WirelessLinkAuthCipherValueTkip string = "tkip" + + // WirelessLinkAuthCipherValueAes captures enum value "aes" + WirelessLinkAuthCipherValueAes string = "aes" +) + +// prop value enum +func (m *WirelessLinkAuthCipher) validateValueEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, wirelessLinkAuthCipherTypeValuePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WirelessLinkAuthCipher) validateValue(formats strfmt.Registry) error { + + if err := validate.Required("auth_cipher"+"."+"value", "body", m.Value); err != nil { + return err + } + + // value enum + if err := m.validateValueEnum("auth_cipher"+"."+"value", "body", *m.Value); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this wireless link auth cipher based on context it is used +func (m *WirelessLinkAuthCipher) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *WirelessLinkAuthCipher) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WirelessLinkAuthCipher) UnmarshalBinary(b []byte) error { + var res WirelessLinkAuthCipher + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + +// WirelessLinkAuthType Auth type +// +// swagger:model WirelessLinkAuthType +type WirelessLinkAuthType struct { + + // label + // Required: true + // Enum: [Open WEP WPA Personal (PSK) WPA Enterprise] + Label *string `json:"label"` + + // value + // Required: true + // Enum: [open wep wpa-personal wpa-enterprise] + Value *string `json:"value"` +} + +// Validate validates this wireless link auth type +func (m *WirelessLinkAuthType) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateLabel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateValue(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var wirelessLinkAuthTypeTypeLabelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["Open","WEP","WPA Personal (PSK)","WPA Enterprise"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + wirelessLinkAuthTypeTypeLabelPropEnum = append(wirelessLinkAuthTypeTypeLabelPropEnum, v) + } +} + +const ( + + // WirelessLinkAuthTypeLabelOpen captures enum value "Open" + WirelessLinkAuthTypeLabelOpen string = "Open" + + // WirelessLinkAuthTypeLabelWEP captures enum value "WEP" + WirelessLinkAuthTypeLabelWEP string = "WEP" + + // WirelessLinkAuthTypeLabelWPAPersonalPSK captures enum value "WPA Personal (PSK)" + WirelessLinkAuthTypeLabelWPAPersonalPSK string = "WPA Personal (PSK)" + + // WirelessLinkAuthTypeLabelWPAEnterprise captures enum value "WPA Enterprise" + WirelessLinkAuthTypeLabelWPAEnterprise string = "WPA Enterprise" +) + +// prop value enum +func (m *WirelessLinkAuthType) validateLabelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, wirelessLinkAuthTypeTypeLabelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WirelessLinkAuthType) validateLabel(formats strfmt.Registry) error { + + if err := validate.Required("auth_type"+"."+"label", "body", m.Label); err != nil { + return err + } + + // value enum + if err := m.validateLabelEnum("auth_type"+"."+"label", "body", *m.Label); err != nil { + return err + } + + return nil +} + +var wirelessLinkAuthTypeTypeValuePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["open","wep","wpa-personal","wpa-enterprise"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + wirelessLinkAuthTypeTypeValuePropEnum = append(wirelessLinkAuthTypeTypeValuePropEnum, v) + } +} + +const ( + + // WirelessLinkAuthTypeValueOpen captures enum value "open" + WirelessLinkAuthTypeValueOpen string = "open" + + // WirelessLinkAuthTypeValueWep captures enum value "wep" + WirelessLinkAuthTypeValueWep string = "wep" + + // WirelessLinkAuthTypeValueWpaDashPersonal captures enum value "wpa-personal" + WirelessLinkAuthTypeValueWpaDashPersonal string = "wpa-personal" + + // WirelessLinkAuthTypeValueWpaDashEnterprise captures enum value "wpa-enterprise" + WirelessLinkAuthTypeValueWpaDashEnterprise string = "wpa-enterprise" +) + +// prop value enum +func (m *WirelessLinkAuthType) validateValueEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, wirelessLinkAuthTypeTypeValuePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WirelessLinkAuthType) validateValue(formats strfmt.Registry) error { + + if err := validate.Required("auth_type"+"."+"value", "body", m.Value); err != nil { + return err + } + + // value enum + if err := m.validateValueEnum("auth_type"+"."+"value", "body", *m.Value); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this wireless link auth type based on context it is used +func (m *WirelessLinkAuthType) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *WirelessLinkAuthType) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WirelessLinkAuthType) UnmarshalBinary(b []byte) error { + var res WirelessLinkAuthType + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} + +// WirelessLinkStatus Status +// +// swagger:model WirelessLinkStatus +type WirelessLinkStatus struct { + + // label + // Required: true + // Enum: [Connected Planned Decommissioning] + Label *string `json:"label"` + + // value + // Required: true + // Enum: [connected planned decommissioning] + Value *string `json:"value"` +} + +// Validate validates this wireless link status +func (m *WirelessLinkStatus) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateLabel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateValue(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var wirelessLinkStatusTypeLabelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["Connected","Planned","Decommissioning"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + wirelessLinkStatusTypeLabelPropEnum = append(wirelessLinkStatusTypeLabelPropEnum, v) + } +} + +const ( + + // WirelessLinkStatusLabelConnected captures enum value "Connected" + WirelessLinkStatusLabelConnected string = "Connected" + + // WirelessLinkStatusLabelPlanned captures enum value "Planned" + WirelessLinkStatusLabelPlanned string = "Planned" + + // WirelessLinkStatusLabelDecommissioning captures enum value "Decommissioning" + WirelessLinkStatusLabelDecommissioning string = "Decommissioning" +) + +// prop value enum +func (m *WirelessLinkStatus) validateLabelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, wirelessLinkStatusTypeLabelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WirelessLinkStatus) validateLabel(formats strfmt.Registry) error { + + if err := validate.Required("status"+"."+"label", "body", m.Label); err != nil { + return err + } + + // value enum + if err := m.validateLabelEnum("status"+"."+"label", "body", *m.Label); err != nil { + return err + } + + return nil +} + +var wirelessLinkStatusTypeValuePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["connected","planned","decommissioning"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + wirelessLinkStatusTypeValuePropEnum = append(wirelessLinkStatusTypeValuePropEnum, v) + } +} + +const ( + + // WirelessLinkStatusValueConnected captures enum value "connected" + WirelessLinkStatusValueConnected string = "connected" + + // WirelessLinkStatusValuePlanned captures enum value "planned" + WirelessLinkStatusValuePlanned string = "planned" + + // WirelessLinkStatusValueDecommissioning captures enum value "decommissioning" + WirelessLinkStatusValueDecommissioning string = "decommissioning" +) + +// prop value enum +func (m *WirelessLinkStatus) validateValueEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, wirelessLinkStatusTypeValuePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WirelessLinkStatus) validateValue(formats strfmt.Registry) error { + + if err := validate.Required("status"+"."+"value", "body", m.Value); err != nil { + return err + } + + // value enum + if err := m.validateValueEnum("status"+"."+"value", "body", *m.Value); err != nil { + return err + } + + return nil +} + +// ContextValidate validates this wireless link status based on context it is used +func (m *WirelessLinkStatus) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + return nil +} + +// MarshalBinary interface implementation +func (m *WirelessLinkStatus) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WirelessLinkStatus) UnmarshalBinary(b []byte) error { + var res WirelessLinkStatus + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/writable_a_s_n.go b/netbox/models/writable_a_s_n.go new file mode 100644 index 00000000..95364a8b --- /dev/null +++ b/netbox/models/writable_a_s_n.go @@ -0,0 +1,357 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WritableASN writable a s n +// +// swagger:model WritableASN +type WritableASN struct { + + // ASN + // + // 32-bit autonomous system number + // Required: true + // Maximum: 4.294967295e+09 + // Minimum: 1 + Asn *int64 `json:"asn"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // RIR + // Required: true + Rir *int64 `json:"rir"` + + // Site count + // Read Only: true + SiteCount int64 `json:"site_count,omitempty"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Tenant + Tenant *int64 `json:"tenant,omitempty"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this writable a s n +func (m *WritableASN) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAsn(formats); err != nil { + res = append(res, err) + } + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateRir(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableASN) validateAsn(formats strfmt.Registry) error { + + if err := validate.Required("asn", "body", m.Asn); err != nil { + return err + } + + if err := validate.MinimumInt("asn", "body", *m.Asn, 1, false); err != nil { + return err + } + + if err := validate.MaximumInt("asn", "body", *m.Asn, 4.294967295e+09, false); err != nil { + return err + } + + return nil +} + +func (m *WritableASN) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableASN) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *WritableASN) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableASN) validateRir(formats strfmt.Registry) error { + + if err := validate.Required("rir", "body", m.Rir); err != nil { + return err + } + + return nil +} + +func (m *WritableASN) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableASN) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this writable a s n based on the context it is used +func (m *WritableASN) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateSiteCount(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableASN) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *WritableASN) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *WritableASN) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *WritableASN) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WritableASN) contextValidateSiteCount(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "site_count", "body", int64(m.SiteCount)); err != nil { + return err + } + + return nil +} + +func (m *WritableASN) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableASN) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WritableASN) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WritableASN) UnmarshalBinary(b []byte) error { + var res WritableASN + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/writable_available_ip.go b/netbox/models/writable_available_ip.go new file mode 100644 index 00000000..2d849c29 --- /dev/null +++ b/netbox/models/writable_available_ip.go @@ -0,0 +1,125 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WritableAvailableIP writable available IP +// +// swagger:model WritableAvailableIP +type WritableAvailableIP struct { + + // Address + // Read Only: true + // Min Length: 1 + Address string `json:"address,omitempty"` + + // Family + // Read Only: true + Family int64 `json:"family,omitempty"` +} + +// Validate validates this writable available IP +func (m *WritableAvailableIP) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAddress(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableAvailableIP) validateAddress(formats strfmt.Registry) error { + if swag.IsZero(m.Address) { // not required + return nil + } + + if err := validate.MinLength("address", "body", m.Address, 1); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this writable available IP based on the context it is used +func (m *WritableAvailableIP) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateAddress(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateFamily(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableAvailableIP) contextValidateAddress(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "address", "body", string(m.Address)); err != nil { + return err + } + + return nil +} + +func (m *WritableAvailableIP) contextValidateFamily(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "family", "body", int64(m.Family)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WritableAvailableIP) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WritableAvailableIP) UnmarshalBinary(b []byte) error { + var res WritableAvailableIP + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/writable_cable.go b/netbox/models/writable_cable.go index 22fbef38..c4daf545 100644 --- a/netbox/models/writable_cable.go +++ b/netbox/models/writable_cable.go @@ -41,6 +41,11 @@ type WritableCable struct { // Pattern: ^[0-9a-f]{6}$ Color string `json:"color,omitempty"` + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Custom fields CustomFields interface{} `json:"custom_fields,omitempty"` @@ -56,6 +61,11 @@ type WritableCable struct { // Max Length: 100 Label string `json:"label,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Length Length *float64 `json:"length,omitempty"` @@ -70,6 +80,9 @@ type WritableCable struct { // tags Tags []*NestedTag `json:"tags"` + // Tenant + Tenant *int64 `json:"tenant,omitempty"` + // Termination a // Read Only: true Terminationa map[string]*string `json:"termination_a,omitempty"` @@ -116,10 +129,18 @@ func (m *WritableCable) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateLabel(formats); err != nil { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateLengthUnit(formats); err != nil { res = append(res, err) } @@ -178,6 +199,18 @@ func (m *WritableCable) validateColor(formats strfmt.Registry) error { return nil } +func (m *WritableCable) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *WritableCable) validateLabel(formats strfmt.Registry) error { if swag.IsZero(m.Label) { // not required return nil @@ -190,6 +223,18 @@ func (m *WritableCable) validateLabel(formats strfmt.Registry) error { return nil } +func (m *WritableCable) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + var writableCableTypeLengthUnitPropEnum []interface{} func init() { @@ -488,6 +533,10 @@ func (m *WritableCable) validateURL(formats strfmt.Registry) error { func (m *WritableCable) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -496,6 +545,10 @@ func (m *WritableCable) ContextValidate(ctx context.Context, formats strfmt.Regi res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTags(ctx, formats); err != nil { res = append(res, err) } @@ -518,6 +571,15 @@ func (m *WritableCable) ContextValidate(ctx context.Context, formats strfmt.Regi return nil } +func (m *WritableCable) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *WritableCable) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -536,6 +598,15 @@ func (m *WritableCable) contextValidateID(ctx context.Context, formats strfmt.Re return nil } +func (m *WritableCable) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *WritableCable) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { diff --git a/netbox/models/writable_circuit_termination.go b/netbox/models/writable_circuit_termination.go index 938d38cd..3a955e4c 100644 --- a/netbox/models/writable_circuit_termination.go +++ b/netbox/models/writable_circuit_termination.go @@ -42,22 +42,15 @@ type WritableCircuitTermination struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Circuit // Required: true Circuit *int64 `json:"circuit"` + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Description // Max Length: 200 Description string `json:"description,omitempty"` @@ -70,6 +63,23 @@ type WritableCircuitTermination struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -124,10 +134,18 @@ func (m *WritableCircuitTermination) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateDescription(formats); err != nil { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validatePortSpeed(formats); err != nil { res = append(res, err) } @@ -186,6 +204,18 @@ func (m *WritableCircuitTermination) validateCircuit(formats strfmt.Registry) er return nil } +func (m *WritableCircuitTermination) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *WritableCircuitTermination) validateDescription(formats strfmt.Registry) error { if swag.IsZero(m.Description) { // not required return nil @@ -198,6 +228,18 @@ func (m *WritableCircuitTermination) validateDescription(formats strfmt.Registry return nil } +func (m *WritableCircuitTermination) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *WritableCircuitTermination) validatePortSpeed(formats strfmt.Registry) error { if swag.IsZero(m.PortSpeed) { // not required return nil @@ -321,19 +363,27 @@ func (m *WritableCircuitTermination) ContextValidate(ctx context.Context, format res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { + if err := m.contextValidateCreated(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateDisplay(ctx, formats); err != nil { + if err := m.contextValidateID(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateID(ctx, formats); err != nil { + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { res = append(res, err) } @@ -372,14 +422,9 @@ func (m *WritableCircuitTermination) contextValidateCable(ctx context.Context, f return nil } -func (m *WritableCircuitTermination) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *WritableCircuitTermination) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { +func (m *WritableCircuitTermination) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { return err } @@ -404,6 +449,29 @@ func (m *WritableCircuitTermination) contextValidateID(ctx context.Context, form return nil } +func (m *WritableCircuitTermination) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WritableCircuitTermination) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *WritableCircuitTermination) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *WritableCircuitTermination) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/writable_cluster.go b/netbox/models/writable_cluster.go index 0ba5cdd2..2c28d0b2 100644 --- a/netbox/models/writable_cluster.go +++ b/netbox/models/writable_cluster.go @@ -55,7 +55,8 @@ type WritableCluster struct { Display string `json:"display,omitempty"` // Group - Group *int64 `json:"group,omitempty"` + // Required: true + Group *int64 `json:"group"` // Id // Read Only: true @@ -73,7 +74,8 @@ type WritableCluster struct { Name *string `json:"name"` // Site - Site *int64 `json:"site,omitempty"` + // Required: true + Site *int64 `json:"site"` // tags Tags []*NestedTag `json:"tags"` @@ -103,6 +105,10 @@ func (m *WritableCluster) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateGroup(formats); err != nil { + res = append(res, err) + } + if err := m.validateLastUpdated(formats); err != nil { res = append(res, err) } @@ -111,6 +117,10 @@ func (m *WritableCluster) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateSite(formats); err != nil { + res = append(res, err) + } + if err := m.validateTags(formats); err != nil { res = append(res, err) } @@ -141,6 +151,15 @@ func (m *WritableCluster) validateCreated(formats strfmt.Registry) error { return nil } +func (m *WritableCluster) validateGroup(formats strfmt.Registry) error { + + if err := validate.Required("group", "body", m.Group); err != nil { + return err + } + + return nil +} + func (m *WritableCluster) validateLastUpdated(formats strfmt.Registry) error { if swag.IsZero(m.LastUpdated) { // not required return nil @@ -170,6 +189,15 @@ func (m *WritableCluster) validateName(formats strfmt.Registry) error { return nil } +func (m *WritableCluster) validateSite(formats strfmt.Registry) error { + + if err := validate.Required("site", "body", m.Site); err != nil { + return err + } + + return nil +} + func (m *WritableCluster) validateTags(formats strfmt.Registry) error { if swag.IsZero(m.Tags) { // not required return nil diff --git a/netbox/models/writable_console_port.go b/netbox/models/writable_console_port.go index 8b3db222..c2a4b800 100644 --- a/netbox/models/writable_console_port.go +++ b/netbox/models/writable_console_port.go @@ -43,18 +43,6 @@ type WritableConsolePort struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Connected endpoint // // @@ -106,6 +94,18 @@ type WritableConsolePort struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -449,14 +449,6 @@ func (m *WritableConsolePort) ContextValidate(ctx context.Context, formats strfm res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { - res = append(res, err) - } - if err := m.contextValidateConnectedEndpoint(ctx, formats); err != nil { res = append(res, err) } @@ -485,6 +477,14 @@ func (m *WritableConsolePort) ContextValidate(ctx context.Context, formats strfm res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTags(ctx, formats); err != nil { res = append(res, err) } @@ -524,20 +524,6 @@ func (m *WritableConsolePort) contextValidateCable(ctx context.Context, formats return nil } -func (m *WritableConsolePort) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *WritableConsolePort) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *WritableConsolePort) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil @@ -597,6 +583,20 @@ func (m *WritableConsolePort) contextValidateLastUpdated(ctx context.Context, fo return nil } +func (m *WritableConsolePort) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *WritableConsolePort) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *WritableConsolePort) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { diff --git a/netbox/models/writable_console_server_port.go b/netbox/models/writable_console_server_port.go index 8b117200..56965230 100644 --- a/netbox/models/writable_console_server_port.go +++ b/netbox/models/writable_console_server_port.go @@ -43,18 +43,6 @@ type WritableConsoleServerPort struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Connected endpoint // // @@ -106,6 +94,18 @@ type WritableConsoleServerPort struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -449,14 +449,6 @@ func (m *WritableConsoleServerPort) ContextValidate(ctx context.Context, formats res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { - res = append(res, err) - } - if err := m.contextValidateConnectedEndpoint(ctx, formats); err != nil { res = append(res, err) } @@ -485,6 +477,14 @@ func (m *WritableConsoleServerPort) ContextValidate(ctx context.Context, formats res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTags(ctx, formats); err != nil { res = append(res, err) } @@ -524,20 +524,6 @@ func (m *WritableConsoleServerPort) contextValidateCable(ctx context.Context, fo return nil } -func (m *WritableConsoleServerPort) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *WritableConsoleServerPort) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *WritableConsoleServerPort) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil @@ -597,6 +583,20 @@ func (m *WritableConsoleServerPort) contextValidateLastUpdated(ctx context.Conte return nil } +func (m *WritableConsoleServerPort) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *WritableConsoleServerPort) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *WritableConsoleServerPort) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { diff --git a/netbox/models/writable_contact.go b/netbox/models/writable_contact.go new file mode 100644 index 00000000..92d9654d --- /dev/null +++ b/netbox/models/writable_contact.go @@ -0,0 +1,403 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WritableContact writable contact +// +// swagger:model WritableContact +type WritableContact struct { + + // Address + // Max Length: 200 + Address string `json:"address,omitempty"` + + // Comments + Comments string `json:"comments,omitempty"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Email + // Max Length: 254 + // Format: email + Email strfmt.Email `json:"email,omitempty"` + + // Group + // Required: true + Group *int64 `json:"group"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Name + // Required: true + // Max Length: 100 + // Min Length: 1 + Name *string `json:"name"` + + // Phone + // Max Length: 50 + Phone string `json:"phone,omitempty"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Title + // Max Length: 100 + Title string `json:"title,omitempty"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this writable contact +func (m *WritableContact) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAddress(formats); err != nil { + res = append(res, err) + } + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateEmail(formats); err != nil { + res = append(res, err) + } + + if err := m.validateGroup(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateName(formats); err != nil { + res = append(res, err) + } + + if err := m.validatePhone(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTitle(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableContact) validateAddress(formats strfmt.Registry) error { + if swag.IsZero(m.Address) { // not required + return nil + } + + if err := validate.MaxLength("address", "body", m.Address, 200); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) validateEmail(formats strfmt.Registry) error { + if swag.IsZero(m.Email) { // not required + return nil + } + + if err := validate.MaxLength("email", "body", m.Email.String(), 254); err != nil { + return err + } + + if err := validate.FormatOf("email", "body", "email", m.Email.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) validateGroup(formats strfmt.Registry) error { + + if err := validate.Required("group", "body", m.Group); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) validateName(formats strfmt.Registry) error { + + if err := validate.Required("name", "body", m.Name); err != nil { + return err + } + + if err := validate.MinLength("name", "body", *m.Name, 1); err != nil { + return err + } + + if err := validate.MaxLength("name", "body", *m.Name, 100); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) validatePhone(formats strfmt.Registry) error { + if swag.IsZero(m.Phone) { // not required + return nil + } + + if err := validate.MaxLength("phone", "body", m.Phone, 50); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableContact) validateTitle(formats strfmt.Registry) error { + if swag.IsZero(m.Title) { // not required + return nil + } + + if err := validate.MaxLength("title", "body", m.Title, 100); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this writable contact based on the context it is used +func (m *WritableContact) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableContact) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WritableContact) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableContact) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WritableContact) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WritableContact) UnmarshalBinary(b []byte) error { + var res WritableContact + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/writable_contact_assignment.go b/netbox/models/writable_contact_assignment.go new file mode 100644 index 00000000..a1c7f880 --- /dev/null +++ b/netbox/models/writable_contact_assignment.go @@ -0,0 +1,360 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "encoding/json" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WritableContactAssignment writable contact assignment +// +// swagger:model WritableContactAssignment +type WritableContactAssignment struct { + + // Contact + // Required: true + Contact *int64 `json:"contact"` + + // Content type + // Required: true + ContentType *string `json:"content_type"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Object + // Read Only: true + Object map[string]*string `json:"object,omitempty"` + + // Object id + // Required: true + // Maximum: 2.147483647e+09 + // Minimum: 0 + ObjectID *int64 `json:"object_id"` + + // Priority + // Required: true + // Enum: [primary secondary tertiary inactive] + Priority *string `json:"priority"` + + // Role + // Required: true + Role *int64 `json:"role"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this writable contact assignment +func (m *WritableContactAssignment) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateContact(formats); err != nil { + res = append(res, err) + } + + if err := m.validateContentType(formats); err != nil { + res = append(res, err) + } + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateObjectID(formats); err != nil { + res = append(res, err) + } + + if err := m.validatePriority(formats); err != nil { + res = append(res, err) + } + + if err := m.validateRole(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableContactAssignment) validateContact(formats strfmt.Registry) error { + + if err := validate.Required("contact", "body", m.Contact); err != nil { + return err + } + + return nil +} + +func (m *WritableContactAssignment) validateContentType(formats strfmt.Registry) error { + + if err := validate.Required("content_type", "body", m.ContentType); err != nil { + return err + } + + return nil +} + +func (m *WritableContactAssignment) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableContactAssignment) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableContactAssignment) validateObjectID(formats strfmt.Registry) error { + + if err := validate.Required("object_id", "body", m.ObjectID); err != nil { + return err + } + + if err := validate.MinimumInt("object_id", "body", *m.ObjectID, 0, false); err != nil { + return err + } + + if err := validate.MaximumInt("object_id", "body", *m.ObjectID, 2.147483647e+09, false); err != nil { + return err + } + + return nil +} + +var writableContactAssignmentTypePriorityPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["primary","secondary","tertiary","inactive"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + writableContactAssignmentTypePriorityPropEnum = append(writableContactAssignmentTypePriorityPropEnum, v) + } +} + +const ( + + // WritableContactAssignmentPriorityPrimary captures enum value "primary" + WritableContactAssignmentPriorityPrimary string = "primary" + + // WritableContactAssignmentPrioritySecondary captures enum value "secondary" + WritableContactAssignmentPrioritySecondary string = "secondary" + + // WritableContactAssignmentPriorityTertiary captures enum value "tertiary" + WritableContactAssignmentPriorityTertiary string = "tertiary" + + // WritableContactAssignmentPriorityInactive captures enum value "inactive" + WritableContactAssignmentPriorityInactive string = "inactive" +) + +// prop value enum +func (m *WritableContactAssignment) validatePriorityEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, writableContactAssignmentTypePriorityPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WritableContactAssignment) validatePriority(formats strfmt.Registry) error { + + if err := validate.Required("priority", "body", m.Priority); err != nil { + return err + } + + // value enum + if err := m.validatePriorityEnum("priority", "body", *m.Priority); err != nil { + return err + } + + return nil +} + +func (m *WritableContactAssignment) validateRole(formats strfmt.Registry) error { + + if err := validate.Required("role", "body", m.Role); err != nil { + return err + } + + return nil +} + +func (m *WritableContactAssignment) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this writable contact assignment based on the context it is used +func (m *WritableContactAssignment) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateObject(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableContactAssignment) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *WritableContactAssignment) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *WritableContactAssignment) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *WritableContactAssignment) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WritableContactAssignment) contextValidateObject(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *WritableContactAssignment) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WritableContactAssignment) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WritableContactAssignment) UnmarshalBinary(b []byte) error { + var res WritableContactAssignment + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/writable_contact_group.go b/netbox/models/writable_contact_group.go new file mode 100644 index 00000000..b8748f11 --- /dev/null +++ b/netbox/models/writable_contact_group.go @@ -0,0 +1,401 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WritableContactGroup writable contact group +// +// swagger:model WritableContactGroup +type WritableContactGroup struct { + + // depth + // Read Only: true + Depth int64 `json:"_depth,omitempty"` + + // Contact count + // Read Only: true + ContactCount int64 `json:"contact_count,omitempty"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Name + // Required: true + // Max Length: 100 + // Min Length: 1 + Name *string `json:"name"` + + // Parent + // Required: true + Parent *int64 `json:"parent"` + + // Slug + // Required: true + // Max Length: 100 + // Min Length: 1 + // Pattern: ^[-a-zA-Z0-9_]+$ + Slug *string `json:"slug"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this writable contact group +func (m *WritableContactGroup) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateName(formats); err != nil { + res = append(res, err) + } + + if err := m.validateParent(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSlug(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableContactGroup) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) validateName(formats strfmt.Registry) error { + + if err := validate.Required("name", "body", m.Name); err != nil { + return err + } + + if err := validate.MinLength("name", "body", *m.Name, 1); err != nil { + return err + } + + if err := validate.MaxLength("name", "body", *m.Name, 100); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) validateParent(formats strfmt.Registry) error { + + if err := validate.Required("parent", "body", m.Parent); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) validateSlug(formats strfmt.Registry) error { + + if err := validate.Required("slug", "body", m.Slug); err != nil { + return err + } + + if err := validate.MinLength("slug", "body", *m.Slug, 1); err != nil { + return err + } + + if err := validate.MaxLength("slug", "body", *m.Slug, 100); err != nil { + return err + } + + if err := validate.Pattern("slug", "body", *m.Slug, `^[-a-zA-Z0-9_]+$`); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableContactGroup) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this writable contact group based on the context it is used +func (m *WritableContactGroup) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDepth(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateContactCount(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableContactGroup) contextValidateDepth(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "_depth", "body", int64(m.Depth)); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) contextValidateContactCount(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "contact_count", "body", int64(m.ContactCount)); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WritableContactGroup) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableContactGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WritableContactGroup) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WritableContactGroup) UnmarshalBinary(b []byte) error { + var res WritableContactGroup + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/writable_custom_field.go b/netbox/models/writable_custom_field.go index 54fbc071..b7f1c5d8 100644 --- a/netbox/models/writable_custom_field.go +++ b/netbox/models/writable_custom_field.go @@ -44,6 +44,11 @@ type WritableCustomField struct { // Unique: true ContentTypes []string `json:"content_types"` + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Default // // Default value for the field (must be a JSON value). Encapsulate strings with double quotes (e.g. "Foo"). @@ -73,12 +78,18 @@ type WritableCustomField struct { // Max Length: 50 Label string `json:"label,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Name // // Internal field name // Required: true // Max Length: 50 // Min Length: 1 + // Pattern: ^[a-z0-9_]+$ Name *string `json:"name"` // Required @@ -87,7 +98,7 @@ type WritableCustomField struct { Required bool `json:"required,omitempty"` // Type - // Enum: [text integer boolean date url select multiselect] + // Enum: [text longtext integer boolean date url json select multiselect] Type string `json:"type,omitempty"` // Url @@ -99,14 +110,14 @@ type WritableCustomField struct { // // Maximum allowed value (for numeric fields) // Maximum: 2.147483647e+09 - // Minimum: 0 + // Minimum: -2.147483648e+09 ValidationMaximum *int64 `json:"validation_maximum,omitempty"` // Minimum value // // Minimum allowed value (for numeric fields) // Maximum: 2.147483647e+09 - // Minimum: 0 + // Minimum: -2.147483648e+09 ValidationMinimum *int64 `json:"validation_minimum,omitempty"` // Validation regex @@ -135,6 +146,10 @@ func (m *WritableCustomField) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateDescription(formats); err != nil { res = append(res, err) } @@ -147,6 +162,10 @@ func (m *WritableCustomField) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateName(formats); err != nil { res = append(res, err) } @@ -214,6 +233,18 @@ func (m *WritableCustomField) validateContentTypes(formats strfmt.Registry) erro return nil } +func (m *WritableCustomField) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *WritableCustomField) validateDescription(formats strfmt.Registry) error { if swag.IsZero(m.Description) { // not required return nil @@ -283,6 +314,18 @@ func (m *WritableCustomField) validateLabel(formats strfmt.Registry) error { return nil } +func (m *WritableCustomField) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *WritableCustomField) validateName(formats strfmt.Registry) error { if err := validate.Required("name", "body", m.Name); err != nil { @@ -297,6 +340,10 @@ func (m *WritableCustomField) validateName(formats strfmt.Registry) error { return err } + if err := validate.Pattern("name", "body", *m.Name, `^[a-z0-9_]+$`); err != nil { + return err + } + return nil } @@ -304,7 +351,7 @@ var writableCustomFieldTypeTypePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["text","integer","boolean","date","url","select","multiselect"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["text","longtext","integer","boolean","date","url","json","select","multiselect"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -317,6 +364,9 @@ const ( // WritableCustomFieldTypeText captures enum value "text" WritableCustomFieldTypeText string = "text" + // WritableCustomFieldTypeLongtext captures enum value "longtext" + WritableCustomFieldTypeLongtext string = "longtext" + // WritableCustomFieldTypeInteger captures enum value "integer" WritableCustomFieldTypeInteger string = "integer" @@ -329,6 +379,9 @@ const ( // WritableCustomFieldTypeURL captures enum value "url" WritableCustomFieldTypeURL string = "url" + // WritableCustomFieldTypeJSON captures enum value "json" + WritableCustomFieldTypeJSON string = "json" + // WritableCustomFieldTypeSelect captures enum value "select" WritableCustomFieldTypeSelect string = "select" @@ -374,7 +427,7 @@ func (m *WritableCustomField) validateValidationMaximum(formats strfmt.Registry) return nil } - if err := validate.MinimumInt("validation_maximum", "body", *m.ValidationMaximum, 0, false); err != nil { + if err := validate.MinimumInt("validation_maximum", "body", *m.ValidationMaximum, -2.147483648e+09, false); err != nil { return err } @@ -390,7 +443,7 @@ func (m *WritableCustomField) validateValidationMinimum(formats strfmt.Registry) return nil } - if err := validate.MinimumInt("validation_minimum", "body", *m.ValidationMinimum, 0, false); err != nil { + if err := validate.MinimumInt("validation_minimum", "body", *m.ValidationMinimum, -2.147483648e+09, false); err != nil { return err } @@ -433,6 +486,10 @@ func (m *WritableCustomField) validateWeight(formats strfmt.Registry) error { func (m *WritableCustomField) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -441,6 +498,10 @@ func (m *WritableCustomField) ContextValidate(ctx context.Context, formats strfm res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -451,6 +512,15 @@ func (m *WritableCustomField) ContextValidate(ctx context.Context, formats strfm return nil } +func (m *WritableCustomField) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *WritableCustomField) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -469,6 +539,15 @@ func (m *WritableCustomField) contextValidateID(ctx context.Context, formats str return nil } +func (m *WritableCustomField) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *WritableCustomField) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/writable_device_type.go b/netbox/models/writable_device_type.go index 8e1e4479..be5e5fc9 100644 --- a/netbox/models/writable_device_type.go +++ b/netbox/models/writable_device_type.go @@ -36,6 +36,10 @@ import ( // swagger:model WritableDeviceType type WritableDeviceType struct { + // Airflow + // Enum: [front-to-rear rear-to-front left-to-right right-to-left side-to-rear passive] + Airflow string `json:"airflow,omitempty"` + // Comments Comments string `json:"comments,omitempty"` @@ -126,6 +130,10 @@ type WritableDeviceType struct { func (m *WritableDeviceType) Validate(formats strfmt.Registry) error { var res []error + if err := m.validateAirflow(formats); err != nil { + res = append(res, err) + } + if err := m.validateCreated(formats); err != nil { res = append(res, err) } @@ -180,6 +188,60 @@ func (m *WritableDeviceType) Validate(formats strfmt.Registry) error { return nil } +var writableDeviceTypeTypeAirflowPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["front-to-rear","rear-to-front","left-to-right","right-to-left","side-to-rear","passive"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + writableDeviceTypeTypeAirflowPropEnum = append(writableDeviceTypeTypeAirflowPropEnum, v) + } +} + +const ( + + // WritableDeviceTypeAirflowFrontDashToDashRear captures enum value "front-to-rear" + WritableDeviceTypeAirflowFrontDashToDashRear string = "front-to-rear" + + // WritableDeviceTypeAirflowRearDashToDashFront captures enum value "rear-to-front" + WritableDeviceTypeAirflowRearDashToDashFront string = "rear-to-front" + + // WritableDeviceTypeAirflowLeftDashToDashRight captures enum value "left-to-right" + WritableDeviceTypeAirflowLeftDashToDashRight string = "left-to-right" + + // WritableDeviceTypeAirflowRightDashToDashLeft captures enum value "right-to-left" + WritableDeviceTypeAirflowRightDashToDashLeft string = "right-to-left" + + // WritableDeviceTypeAirflowSideDashToDashRear captures enum value "side-to-rear" + WritableDeviceTypeAirflowSideDashToDashRear string = "side-to-rear" + + // WritableDeviceTypeAirflowPassive captures enum value "passive" + WritableDeviceTypeAirflowPassive string = "passive" +) + +// prop value enum +func (m *WritableDeviceType) validateAirflowEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, writableDeviceTypeTypeAirflowPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WritableDeviceType) validateAirflow(formats strfmt.Registry) error { + if swag.IsZero(m.Airflow) { // not required + return nil + } + + // value enum + if err := m.validateAirflowEnum("airflow", "body", m.Airflow); err != nil { + return err + } + + return nil +} + func (m *WritableDeviceType) validateCreated(formats strfmt.Registry) error { if swag.IsZero(m.Created) { // not required return nil diff --git a/netbox/models/writable_device_with_config_context.go b/netbox/models/writable_device_with_config_context.go index e00ef914..44c6b1cd 100644 --- a/netbox/models/writable_device_with_config_context.go +++ b/netbox/models/writable_device_with_config_context.go @@ -36,6 +36,10 @@ import ( // swagger:model WritableDeviceWithConfigContext type WritableDeviceWithConfigContext struct { + // Airflow + // Enum: [front-to-rear rear-to-front left-to-right right-to-left side-to-rear passive] + Airflow string `json:"airflow,omitempty"` + // Asset tag // // A unique tag used to identify this device @@ -73,8 +77,9 @@ type WritableDeviceWithConfigContext struct { Display string `json:"display,omitempty"` // Rack face + // Required: true // Enum: [front rear] - Face string `json:"face,omitempty"` + Face *string `json:"face"` // Id // Read Only: true @@ -92,8 +97,9 @@ type WritableDeviceWithConfigContext struct { Location *int64 `json:"location,omitempty"` // Name + // Required: true // Max Length: 64 - Name *string `json:"name,omitempty"` + Name *string `json:"name"` // parent device ParentDevice *NestedDevice `json:"parent_device,omitempty"` @@ -102,9 +108,6 @@ type WritableDeviceWithConfigContext struct { Platform *int64 `json:"platform,omitempty"` // Position (U) - // - // The lowest-numbered unit occupied by the device - // Maximum: 32767 // Minimum: 1 Position *int64 `json:"position,omitempty"` @@ -119,7 +122,8 @@ type WritableDeviceWithConfigContext struct { PrimaryIp6 *int64 `json:"primary_ip6,omitempty"` // Rack - Rack *int64 `json:"rack,omitempty"` + // Required: true + Rack *int64 `json:"rack"` // Serial number // Max Length: 50 @@ -137,7 +141,8 @@ type WritableDeviceWithConfigContext struct { Tags []*NestedTag `json:"tags"` // Tenant - Tenant *int64 `json:"tenant,omitempty"` + // Required: true + Tenant *int64 `json:"tenant"` // Url // Read Only: true @@ -155,13 +160,18 @@ type WritableDeviceWithConfigContext struct { VcPriority *int64 `json:"vc_priority,omitempty"` // Virtual chassis - VirtualChassis *int64 `json:"virtual_chassis,omitempty"` + // Required: true + VirtualChassis *int64 `json:"virtual_chassis"` } // Validate validates this writable device with config context func (m *WritableDeviceWithConfigContext) Validate(formats strfmt.Registry) error { var res []error + if err := m.validateAirflow(formats); err != nil { + res = append(res, err) + } + if err := m.validateAssetTag(formats); err != nil { res = append(res, err) } @@ -198,6 +208,10 @@ func (m *WritableDeviceWithConfigContext) Validate(formats strfmt.Registry) erro res = append(res, err) } + if err := m.validateRack(formats); err != nil { + res = append(res, err) + } + if err := m.validateSerial(formats); err != nil { res = append(res, err) } @@ -214,6 +228,10 @@ func (m *WritableDeviceWithConfigContext) Validate(formats strfmt.Registry) erro res = append(res, err) } + if err := m.validateTenant(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -226,12 +244,70 @@ func (m *WritableDeviceWithConfigContext) Validate(formats strfmt.Registry) erro res = append(res, err) } + if err := m.validateVirtualChassis(formats); err != nil { + res = append(res, err) + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } return nil } +var writableDeviceWithConfigContextTypeAirflowPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["front-to-rear","rear-to-front","left-to-right","right-to-left","side-to-rear","passive"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + writableDeviceWithConfigContextTypeAirflowPropEnum = append(writableDeviceWithConfigContextTypeAirflowPropEnum, v) + } +} + +const ( + + // WritableDeviceWithConfigContextAirflowFrontDashToDashRear captures enum value "front-to-rear" + WritableDeviceWithConfigContextAirflowFrontDashToDashRear string = "front-to-rear" + + // WritableDeviceWithConfigContextAirflowRearDashToDashFront captures enum value "rear-to-front" + WritableDeviceWithConfigContextAirflowRearDashToDashFront string = "rear-to-front" + + // WritableDeviceWithConfigContextAirflowLeftDashToDashRight captures enum value "left-to-right" + WritableDeviceWithConfigContextAirflowLeftDashToDashRight string = "left-to-right" + + // WritableDeviceWithConfigContextAirflowRightDashToDashLeft captures enum value "right-to-left" + WritableDeviceWithConfigContextAirflowRightDashToDashLeft string = "right-to-left" + + // WritableDeviceWithConfigContextAirflowSideDashToDashRear captures enum value "side-to-rear" + WritableDeviceWithConfigContextAirflowSideDashToDashRear string = "side-to-rear" + + // WritableDeviceWithConfigContextAirflowPassive captures enum value "passive" + WritableDeviceWithConfigContextAirflowPassive string = "passive" +) + +// prop value enum +func (m *WritableDeviceWithConfigContext) validateAirflowEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, writableDeviceWithConfigContextTypeAirflowPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WritableDeviceWithConfigContext) validateAirflow(formats strfmt.Registry) error { + if swag.IsZero(m.Airflow) { // not required + return nil + } + + // value enum + if err := m.validateAirflowEnum("airflow", "body", m.Airflow); err != nil { + return err + } + + return nil +} + func (m *WritableDeviceWithConfigContext) validateAssetTag(formats strfmt.Registry) error { if swag.IsZero(m.AssetTag) { // not required return nil @@ -304,12 +380,13 @@ func (m *WritableDeviceWithConfigContext) validateFaceEnum(path, location string } func (m *WritableDeviceWithConfigContext) validateFace(formats strfmt.Registry) error { - if swag.IsZero(m.Face) { // not required - return nil + + if err := validate.Required("face", "body", m.Face); err != nil { + return err } // value enum - if err := m.validateFaceEnum("face", "body", m.Face); err != nil { + if err := m.validateFaceEnum("face", "body", *m.Face); err != nil { return err } @@ -329,8 +406,9 @@ func (m *WritableDeviceWithConfigContext) validateLastUpdated(formats strfmt.Reg } func (m *WritableDeviceWithConfigContext) validateName(formats strfmt.Registry) error { - if swag.IsZero(m.Name) { // not required - return nil + + if err := validate.Required("name", "body", m.Name); err != nil { + return err } if err := validate.MaxLength("name", "body", *m.Name, 64); err != nil { @@ -368,7 +446,12 @@ func (m *WritableDeviceWithConfigContext) validatePosition(formats strfmt.Regist return err } - if err := validate.MaximumInt("position", "body", *m.Position, 32767, false); err != nil { + return nil +} + +func (m *WritableDeviceWithConfigContext) validateRack(formats strfmt.Registry) error { + + if err := validate.Required("rack", "body", m.Rack); err != nil { return err } @@ -479,6 +562,15 @@ func (m *WritableDeviceWithConfigContext) validateTags(formats strfmt.Registry) return nil } +func (m *WritableDeviceWithConfigContext) validateTenant(formats strfmt.Registry) error { + + if err := validate.Required("tenant", "body", m.Tenant); err != nil { + return err + } + + return nil +} + func (m *WritableDeviceWithConfigContext) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -523,6 +615,15 @@ func (m *WritableDeviceWithConfigContext) validateVcPriority(formats strfmt.Regi return nil } +func (m *WritableDeviceWithConfigContext) validateVirtualChassis(formats strfmt.Registry) error { + + if err := validate.Required("virtual_chassis", "body", m.VirtualChassis); err != nil { + return err + } + + return nil +} + // ContextValidate validate this writable device with config context based on the context it is used func (m *WritableDeviceWithConfigContext) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error diff --git a/netbox/models/writable_f_h_r_p_group_assignment.go b/netbox/models/writable_f_h_r_p_group_assignment.go new file mode 100644 index 00000000..aac59309 --- /dev/null +++ b/netbox/models/writable_f_h_r_p_group_assignment.go @@ -0,0 +1,311 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WritableFHRPGroupAssignment writable f h r p group assignment +// +// swagger:model WritableFHRPGroupAssignment +type WritableFHRPGroupAssignment struct { + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Group + // Required: true + Group *int64 `json:"group"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Interface + // Read Only: true + Interface map[string]*string `json:"interface,omitempty"` + + // Interface id + // Required: true + // Maximum: 2.147483647e+09 + // Minimum: 0 + InterfaceID *int64 `json:"interface_id"` + + // Interface type + // Required: true + InterfaceType *string `json:"interface_type"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Priority + // Required: true + // Maximum: 255 + // Minimum: 0 + Priority *int64 `json:"priority"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this writable f h r p group assignment +func (m *WritableFHRPGroupAssignment) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateGroup(formats); err != nil { + res = append(res, err) + } + + if err := m.validateInterfaceID(formats); err != nil { + res = append(res, err) + } + + if err := m.validateInterfaceType(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validatePriority(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableFHRPGroupAssignment) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableFHRPGroupAssignment) validateGroup(formats strfmt.Registry) error { + + if err := validate.Required("group", "body", m.Group); err != nil { + return err + } + + return nil +} + +func (m *WritableFHRPGroupAssignment) validateInterfaceID(formats strfmt.Registry) error { + + if err := validate.Required("interface_id", "body", m.InterfaceID); err != nil { + return err + } + + if err := validate.MinimumInt("interface_id", "body", *m.InterfaceID, 0, false); err != nil { + return err + } + + if err := validate.MaximumInt("interface_id", "body", *m.InterfaceID, 2.147483647e+09, false); err != nil { + return err + } + + return nil +} + +func (m *WritableFHRPGroupAssignment) validateInterfaceType(formats strfmt.Registry) error { + + if err := validate.Required("interface_type", "body", m.InterfaceType); err != nil { + return err + } + + return nil +} + +func (m *WritableFHRPGroupAssignment) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableFHRPGroupAssignment) validatePriority(formats strfmt.Registry) error { + + if err := validate.Required("priority", "body", m.Priority); err != nil { + return err + } + + if err := validate.MinimumInt("priority", "body", *m.Priority, 0, false); err != nil { + return err + } + + if err := validate.MaximumInt("priority", "body", *m.Priority, 255, false); err != nil { + return err + } + + return nil +} + +func (m *WritableFHRPGroupAssignment) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this writable f h r p group assignment based on the context it is used +func (m *WritableFHRPGroupAssignment) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateInterface(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableFHRPGroupAssignment) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *WritableFHRPGroupAssignment) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *WritableFHRPGroupAssignment) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *WritableFHRPGroupAssignment) contextValidateInterface(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *WritableFHRPGroupAssignment) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WritableFHRPGroupAssignment) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WritableFHRPGroupAssignment) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WritableFHRPGroupAssignment) UnmarshalBinary(b []byte) error { + var res WritableFHRPGroupAssignment + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/writable_front_port.go b/netbox/models/writable_front_port.go index fe654781..e7c7190c 100644 --- a/netbox/models/writable_front_port.go +++ b/netbox/models/writable_front_port.go @@ -43,18 +43,6 @@ type WritableFrontPort struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Color // Max Length: 6 // Pattern: ^[0-9a-f]{6}$ @@ -95,6 +83,18 @@ type WritableFrontPort struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -120,7 +120,7 @@ type WritableFrontPort struct { // Type // Required: true - // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-apc lsh lsh-apc mpo mtrj sc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] + // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-pc lc-upc lc-apc lsh lsh-pc lsh-upc lsh-apc mpo mtrj sc sc-pc sc-upc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] Type *string `json:"type"` // Url @@ -355,7 +355,7 @@ var writableFrontPortTypeTypePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-apc","lsh","lsh-apc","mpo","mtrj","sc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-pc","lc-upc","lc-apc","lsh","lsh-pc","lsh-upc","lsh-apc","mpo","mtrj","sc","sc-pc","sc-upc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -425,12 +425,24 @@ const ( // WritableFrontPortTypeLc captures enum value "lc" WritableFrontPortTypeLc string = "lc" + // WritableFrontPortTypeLcDashPc captures enum value "lc-pc" + WritableFrontPortTypeLcDashPc string = "lc-pc" + + // WritableFrontPortTypeLcDashUpc captures enum value "lc-upc" + WritableFrontPortTypeLcDashUpc string = "lc-upc" + // WritableFrontPortTypeLcDashApc captures enum value "lc-apc" WritableFrontPortTypeLcDashApc string = "lc-apc" // WritableFrontPortTypeLsh captures enum value "lsh" WritableFrontPortTypeLsh string = "lsh" + // WritableFrontPortTypeLshDashPc captures enum value "lsh-pc" + WritableFrontPortTypeLshDashPc string = "lsh-pc" + + // WritableFrontPortTypeLshDashUpc captures enum value "lsh-upc" + WritableFrontPortTypeLshDashUpc string = "lsh-upc" + // WritableFrontPortTypeLshDashApc captures enum value "lsh-apc" WritableFrontPortTypeLshDashApc string = "lsh-apc" @@ -443,6 +455,12 @@ const ( // WritableFrontPortTypeSc captures enum value "sc" WritableFrontPortTypeSc string = "sc" + // WritableFrontPortTypeScDashPc captures enum value "sc-pc" + WritableFrontPortTypeScDashPc string = "sc-pc" + + // WritableFrontPortTypeScDashUpc captures enum value "sc-upc" + WritableFrontPortTypeScDashUpc string = "sc-upc" + // WritableFrontPortTypeScDashApc captures enum value "sc-apc" WritableFrontPortTypeScDashApc string = "sc-apc" @@ -520,27 +538,27 @@ func (m *WritableFrontPort) ContextValidate(ctx context.Context, formats strfmt. res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { + if err := m.contextValidateCreated(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCreated(ctx, formats); err != nil { + if err := m.contextValidateID(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateDisplay(ctx, formats); err != nil { + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateID(ctx, formats); err != nil { + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { res = append(res, err) } @@ -583,20 +601,6 @@ func (m *WritableFrontPort) contextValidateCable(ctx context.Context, formats st return nil } -func (m *WritableFrontPort) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *WritableFrontPort) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *WritableFrontPort) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { @@ -633,6 +637,20 @@ func (m *WritableFrontPort) contextValidateLastUpdated(ctx context.Context, form return nil } +func (m *WritableFrontPort) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *WritableFrontPort) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *WritableFrontPort) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { diff --git a/netbox/models/writable_front_port_template.go b/netbox/models/writable_front_port_template.go index de1d4b87..dc286087 100644 --- a/netbox/models/writable_front_port_template.go +++ b/netbox/models/writable_front_port_template.go @@ -89,7 +89,7 @@ type WritableFrontPortTemplate struct { // Type // Required: true - // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-apc lsh lsh-apc mpo mtrj sc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] + // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-pc lc-upc lc-apc lsh lsh-pc lsh-upc lsh-apc mpo mtrj sc sc-pc sc-upc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] Type *string `json:"type"` // Url @@ -271,7 +271,7 @@ var writableFrontPortTemplateTypeTypePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-apc","lsh","lsh-apc","mpo","mtrj","sc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-pc","lc-upc","lc-apc","lsh","lsh-pc","lsh-upc","lsh-apc","mpo","mtrj","sc","sc-pc","sc-upc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -341,12 +341,24 @@ const ( // WritableFrontPortTemplateTypeLc captures enum value "lc" WritableFrontPortTemplateTypeLc string = "lc" + // WritableFrontPortTemplateTypeLcDashPc captures enum value "lc-pc" + WritableFrontPortTemplateTypeLcDashPc string = "lc-pc" + + // WritableFrontPortTemplateTypeLcDashUpc captures enum value "lc-upc" + WritableFrontPortTemplateTypeLcDashUpc string = "lc-upc" + // WritableFrontPortTemplateTypeLcDashApc captures enum value "lc-apc" WritableFrontPortTemplateTypeLcDashApc string = "lc-apc" // WritableFrontPortTemplateTypeLsh captures enum value "lsh" WritableFrontPortTemplateTypeLsh string = "lsh" + // WritableFrontPortTemplateTypeLshDashPc captures enum value "lsh-pc" + WritableFrontPortTemplateTypeLshDashPc string = "lsh-pc" + + // WritableFrontPortTemplateTypeLshDashUpc captures enum value "lsh-upc" + WritableFrontPortTemplateTypeLshDashUpc string = "lsh-upc" + // WritableFrontPortTemplateTypeLshDashApc captures enum value "lsh-apc" WritableFrontPortTemplateTypeLshDashApc string = "lsh-apc" @@ -359,6 +371,12 @@ const ( // WritableFrontPortTemplateTypeSc captures enum value "sc" WritableFrontPortTemplateTypeSc string = "sc" + // WritableFrontPortTemplateTypeScDashPc captures enum value "sc-pc" + WritableFrontPortTemplateTypeScDashPc string = "sc-pc" + + // WritableFrontPortTemplateTypeScDashUpc captures enum value "sc-upc" + WritableFrontPortTemplateTypeScDashUpc string = "sc-upc" + // WritableFrontPortTemplateTypeScDashApc captures enum value "sc-apc" WritableFrontPortTemplateTypeScDashApc string = "sc-apc" diff --git a/netbox/models/writable_interface.go b/netbox/models/writable_interface.go index 41a11b36..fce26539 100644 --- a/netbox/models/writable_interface.go +++ b/netbox/models/writable_interface.go @@ -40,21 +40,12 @@ type WritableInterface struct { // Read Only: true Occupied *bool `json:"_occupied,omitempty"` + // Bridge interface + Bridge *int64 `json:"bridge,omitempty"` + // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Connected endpoint // // @@ -71,6 +62,10 @@ type WritableInterface struct { // Read Only: true ConnectedEndpointType string `json:"connected_endpoint_type,omitempty"` + // Count fhrp groups + // Read Only: true + CountFhrpGroups int64 `json:"count_fhrp_groups,omitempty"` + // Count ipaddresses // Read Only: true CountIpaddresses int64 `json:"count_ipaddresses,omitempty"` @@ -116,6 +111,18 @@ type WritableInterface struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // MAC Address MacAddress *string `json:"mac_address,omitempty"` @@ -147,6 +154,20 @@ type WritableInterface struct { // Parent interface Parent *int64 `json:"parent,omitempty"` + // Wireless channel + // Enum: [2.4g-1-2412-22 2.4g-2-2417-22 2.4g-3-2422-22 2.4g-4-2427-22 2.4g-5-2432-22 2.4g-6-2437-22 2.4g-7-2442-22 2.4g-8-2447-22 2.4g-9-2452-22 2.4g-10-2457-22 2.4g-11-2462-22 2.4g-12-2467-22 2.4g-13-2472-22 5g-32-5160-20 5g-34-5170-40 5g-36-5180-20 5g-38-5190-40 5g-40-5200-20 5g-42-5210-80 5g-44-5220-20 5g-46-5230-40 5g-48-5240-20 5g-50-5250-160 5g-52-5260-20 5g-54-5270-40 5g-56-5280-20 5g-58-5290-80 5g-60-5300-20 5g-62-5310-40 5g-64-5320-20 5g-100-5500-20 5g-102-5510-40 5g-104-5520-20 5g-106-5530-80 5g-108-5540-20 5g-110-5550-40 5g-112-5560-20 5g-114-5570-160 5g-116-5580-20 5g-118-5590-40 5g-120-5600-20 5g-122-5610-80 5g-124-5620-20 5g-126-5630-40 5g-128-5640-20 5g-132-5660-20 5g-134-5670-40 5g-136-5680-20 5g-138-5690-80 5g-140-5700-20 5g-142-5710-40 5g-144-5720-20 5g-149-5745-20 5g-151-5755-40 5g-153-5765-20 5g-155-5775-80 5g-157-5785-20 5g-159-5795-40 5g-161-5805-20 5g-163-5815-160 5g-165-5825-20 5g-167-5835-40 5g-169-5845-20 5g-171-5855-80 5g-173-5865-20 5g-175-5875-40 5g-177-5885-20 6g-1-5955-20 6g-3-5965-40 6g-5-5975-20 6g-7-5985-80 6g-9-5995-20 6g-11-6005-40 6g-13-6015-20 6g-15-6025-160 6g-17-6035-20 6g-19-6045-40 6g-21-6055-20 6g-23-6065-80 6g-25-6075-20 6g-27-6085-40 6g-29-6095-20 6g-31-6105-320 6g-33-6115-20 6g-35-6125-40 6g-37-6135-20 6g-39-6145-80 6g-41-6155-20 6g-43-6165-40 6g-45-6175-20 6g-47-6185-160 6g-49-6195-20 6g-51-6205-40 6g-53-6215-20 6g-55-6225-80 6g-57-6235-20 6g-59-6245-40 6g-61-6255-20 6g-65-6275-20 6g-67-6285-40 6g-69-6295-20 6g-71-6305-80 6g-73-6315-20 6g-75-6325-40 6g-77-6335-20 6g-79-6345-160 6g-81-6355-20 6g-83-6365-40 6g-85-6375-20 6g-87-6385-80 6g-89-6395-20 6g-91-6405-40 6g-93-6415-20 6g-95-6425-320 6g-97-6435-20 6g-99-6445-40 6g-101-6455-20 6g-103-6465-80 6g-105-6475-20 6g-107-6485-40 6g-109-6495-20 6g-111-6505-160 6g-113-6515-20 6g-115-6525-40 6g-117-6535-20 6g-119-6545-80 6g-121-6555-20 6g-123-6565-40 6g-125-6575-20 6g-129-6595-20 6g-131-6605-40 6g-133-6615-20 6g-135-6625-80 6g-137-6635-20 6g-139-6645-40 6g-141-6655-20 6g-143-6665-160 6g-145-6675-20 6g-147-6685-40 6g-149-6695-20 6g-151-6705-80 6g-153-6715-20 6g-155-6725-40 6g-157-6735-20 6g-159-6745-320 6g-161-6755-20 6g-163-6765-40 6g-165-6775-20 6g-167-6785-80 6g-169-6795-20 6g-171-6805-40 6g-173-6815-20 6g-175-6825-160 6g-177-6835-20 6g-179-6845-40 6g-181-6855-20 6g-183-6865-80 6g-185-6875-20 6g-187-6885-40 6g-189-6895-20 6g-193-6915-20 6g-195-6925-40 6g-197-6935-20 6g-199-6945-80 6g-201-6955-20 6g-203-6965-40 6g-205-6975-20 6g-207-6985-160 6g-209-6995-20 6g-211-7005-40 6g-213-7015-20 6g-215-7025-80 6g-217-7035-20 6g-219-7045-40 6g-221-7055-20 6g-225-7075-20 6g-227-7085-40 6g-229-7095-20 6g-233-7115-20 60g-1-58320-2160 60g-2-60480-2160 60g-3-62640-2160 60g-4-64800-2160 60g-5-66960-2160 60g-6-69120-2160 60g-9-59400-4320 60g-10-61560-4320 60g-11-63720-4320 60g-12-65880-4320 60g-13-68040-4320 60g-17-60480-6480 60g-18-62640-6480 60g-19-64800-6480 60g-20-66960-6480 60g-25-61560-6480 60g-26-63720-6480 60g-27-65880-6480] + RfChannel string `json:"rf_channel,omitempty"` + + // Channel frequency (MHz) + RfChannelFrequency *float64 `json:"rf_channel_frequency,omitempty"` + + // Channel width (MHz) + RfChannelWidth *float64 `json:"rf_channel_width,omitempty"` + + // Wireless role + // Enum: [ap station] + RfRole string `json:"rf_role,omitempty"` + // tagged vlans // Unique: true TaggedVlans []int64 `json:"tagged_vlans"` @@ -154,9 +175,14 @@ type WritableInterface struct { // tags Tags []*NestedTag `json:"tags"` + // Transmit power (dBm) + // Maximum: 127 + // Minimum: 0 + TxPower *int64 `json:"tx_power,omitempty"` + // Type // Required: true - // Enum: [virtual lag 100base-tx 1000base-t 2.5gbase-t 5gbase-t 10gbase-t 10gbase-cx4 1000base-x-gbic 1000base-x-sfp 10gbase-x-sfpp 10gbase-x-xfp 10gbase-x-xenpak 10gbase-x-x2 25gbase-x-sfp28 50gbase-x-sfp56 40gbase-x-qsfpp 50gbase-x-sfp28 100gbase-x-cfp 100gbase-x-cfp2 200gbase-x-cfp2 100gbase-x-cfp4 100gbase-x-cpak 100gbase-x-qsfp28 200gbase-x-qsfp56 400gbase-x-qsfpdd 400gbase-x-osfp ieee802.11a ieee802.11g ieee802.11n ieee802.11ac ieee802.11ad ieee802.11ax ieee802.15.1 gsm cdma lte sonet-oc3 sonet-oc12 sonet-oc48 sonet-oc192 sonet-oc768 sonet-oc1920 sonet-oc3840 1gfc-sfp 2gfc-sfp 4gfc-sfp 8gfc-sfpp 16gfc-sfpp 32gfc-sfp28 64gfc-qsfpp 128gfc-sfp28 infiniband-sdr infiniband-ddr infiniband-qdr infiniband-fdr10 infiniband-fdr infiniband-edr infiniband-hdr infiniband-ndr infiniband-xdr t1 e1 t3 e3 xdsl cisco-stackwise cisco-stackwise-plus cisco-flexstack cisco-flexstack-plus juniper-vcp extreme-summitstack extreme-summitstack-128 extreme-summitstack-256 extreme-summitstack-512 other] + // Enum: [virtual bridge lag 100base-tx 1000base-t 2.5gbase-t 5gbase-t 10gbase-t 10gbase-cx4 1000base-x-gbic 1000base-x-sfp 10gbase-x-sfpp 10gbase-x-xfp 10gbase-x-xenpak 10gbase-x-x2 25gbase-x-sfp28 50gbase-x-sfp56 40gbase-x-qsfpp 50gbase-x-sfp28 100gbase-x-cfp 100gbase-x-cfp2 200gbase-x-cfp2 100gbase-x-cfp4 100gbase-x-cpak 100gbase-x-qsfp28 200gbase-x-qsfp56 400gbase-x-qsfpdd 400gbase-x-osfp ieee802.11a ieee802.11g ieee802.11n ieee802.11ac ieee802.11ad ieee802.11ax ieee802.15.1 gsm cdma lte sonet-oc3 sonet-oc12 sonet-oc48 sonet-oc192 sonet-oc768 sonet-oc1920 sonet-oc3840 1gfc-sfp 2gfc-sfp 4gfc-sfp 8gfc-sfpp 16gfc-sfpp 32gfc-sfp28 64gfc-qsfpp 128gfc-qsfp28 infiniband-sdr infiniband-ddr infiniband-qdr infiniband-fdr10 infiniband-fdr infiniband-edr infiniband-hdr infiniband-ndr infiniband-xdr t1 e1 t3 e3 xdsl cisco-stackwise cisco-stackwise-plus cisco-flexstack cisco-flexstack-plus cisco-stackwise-80 cisco-stackwise-160 cisco-stackwise-320 cisco-stackwise-480 juniper-vcp extreme-summitstack extreme-summitstack-128 extreme-summitstack-256 extreme-summitstack-512 other] Type *string `json:"type"` // Untagged VLAN @@ -166,6 +192,18 @@ type WritableInterface struct { // Read Only: true // Format: uri URL strfmt.URI `json:"url,omitempty"` + + // wireless lans + // Unique: true + WirelessLans []int64 `json:"wireless_lans"` + + // Wireless link + WirelessLink *int64 `json:"wireless_link,omitempty"` + + // WWN + // + // 64-bit World Wide Name + Wwn *string `json:"wwn,omitempty"` } // Validate validates this writable interface @@ -208,6 +246,14 @@ func (m *WritableInterface) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateRfChannel(formats); err != nil { + res = append(res, err) + } + + if err := m.validateRfRole(formats); err != nil { + res = append(res, err) + } + if err := m.validateTaggedVlans(formats); err != nil { res = append(res, err) } @@ -216,6 +262,10 @@ func (m *WritableInterface) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTxPower(formats); err != nil { + res = append(res, err) + } + if err := m.validateType(formats); err != nil { res = append(res, err) } @@ -224,6 +274,10 @@ func (m *WritableInterface) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateWirelessLans(formats); err != nil { + res = append(res, err) + } + if len(res) > 0 { return errors.CompositeValidationError(res...) } @@ -384,6 +438,675 @@ func (m *WritableInterface) validateName(formats strfmt.Registry) error { return nil } +var writableInterfaceTypeRfChannelPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["2.4g-1-2412-22","2.4g-2-2417-22","2.4g-3-2422-22","2.4g-4-2427-22","2.4g-5-2432-22","2.4g-6-2437-22","2.4g-7-2442-22","2.4g-8-2447-22","2.4g-9-2452-22","2.4g-10-2457-22","2.4g-11-2462-22","2.4g-12-2467-22","2.4g-13-2472-22","5g-32-5160-20","5g-34-5170-40","5g-36-5180-20","5g-38-5190-40","5g-40-5200-20","5g-42-5210-80","5g-44-5220-20","5g-46-5230-40","5g-48-5240-20","5g-50-5250-160","5g-52-5260-20","5g-54-5270-40","5g-56-5280-20","5g-58-5290-80","5g-60-5300-20","5g-62-5310-40","5g-64-5320-20","5g-100-5500-20","5g-102-5510-40","5g-104-5520-20","5g-106-5530-80","5g-108-5540-20","5g-110-5550-40","5g-112-5560-20","5g-114-5570-160","5g-116-5580-20","5g-118-5590-40","5g-120-5600-20","5g-122-5610-80","5g-124-5620-20","5g-126-5630-40","5g-128-5640-20","5g-132-5660-20","5g-134-5670-40","5g-136-5680-20","5g-138-5690-80","5g-140-5700-20","5g-142-5710-40","5g-144-5720-20","5g-149-5745-20","5g-151-5755-40","5g-153-5765-20","5g-155-5775-80","5g-157-5785-20","5g-159-5795-40","5g-161-5805-20","5g-163-5815-160","5g-165-5825-20","5g-167-5835-40","5g-169-5845-20","5g-171-5855-80","5g-173-5865-20","5g-175-5875-40","5g-177-5885-20","6g-1-5955-20","6g-3-5965-40","6g-5-5975-20","6g-7-5985-80","6g-9-5995-20","6g-11-6005-40","6g-13-6015-20","6g-15-6025-160","6g-17-6035-20","6g-19-6045-40","6g-21-6055-20","6g-23-6065-80","6g-25-6075-20","6g-27-6085-40","6g-29-6095-20","6g-31-6105-320","6g-33-6115-20","6g-35-6125-40","6g-37-6135-20","6g-39-6145-80","6g-41-6155-20","6g-43-6165-40","6g-45-6175-20","6g-47-6185-160","6g-49-6195-20","6g-51-6205-40","6g-53-6215-20","6g-55-6225-80","6g-57-6235-20","6g-59-6245-40","6g-61-6255-20","6g-65-6275-20","6g-67-6285-40","6g-69-6295-20","6g-71-6305-80","6g-73-6315-20","6g-75-6325-40","6g-77-6335-20","6g-79-6345-160","6g-81-6355-20","6g-83-6365-40","6g-85-6375-20","6g-87-6385-80","6g-89-6395-20","6g-91-6405-40","6g-93-6415-20","6g-95-6425-320","6g-97-6435-20","6g-99-6445-40","6g-101-6455-20","6g-103-6465-80","6g-105-6475-20","6g-107-6485-40","6g-109-6495-20","6g-111-6505-160","6g-113-6515-20","6g-115-6525-40","6g-117-6535-20","6g-119-6545-80","6g-121-6555-20","6g-123-6565-40","6g-125-6575-20","6g-129-6595-20","6g-131-6605-40","6g-133-6615-20","6g-135-6625-80","6g-137-6635-20","6g-139-6645-40","6g-141-6655-20","6g-143-6665-160","6g-145-6675-20","6g-147-6685-40","6g-149-6695-20","6g-151-6705-80","6g-153-6715-20","6g-155-6725-40","6g-157-6735-20","6g-159-6745-320","6g-161-6755-20","6g-163-6765-40","6g-165-6775-20","6g-167-6785-80","6g-169-6795-20","6g-171-6805-40","6g-173-6815-20","6g-175-6825-160","6g-177-6835-20","6g-179-6845-40","6g-181-6855-20","6g-183-6865-80","6g-185-6875-20","6g-187-6885-40","6g-189-6895-20","6g-193-6915-20","6g-195-6925-40","6g-197-6935-20","6g-199-6945-80","6g-201-6955-20","6g-203-6965-40","6g-205-6975-20","6g-207-6985-160","6g-209-6995-20","6g-211-7005-40","6g-213-7015-20","6g-215-7025-80","6g-217-7035-20","6g-219-7045-40","6g-221-7055-20","6g-225-7075-20","6g-227-7085-40","6g-229-7095-20","6g-233-7115-20","60g-1-58320-2160","60g-2-60480-2160","60g-3-62640-2160","60g-4-64800-2160","60g-5-66960-2160","60g-6-69120-2160","60g-9-59400-4320","60g-10-61560-4320","60g-11-63720-4320","60g-12-65880-4320","60g-13-68040-4320","60g-17-60480-6480","60g-18-62640-6480","60g-19-64800-6480","60g-20-66960-6480","60g-25-61560-6480","60g-26-63720-6480","60g-27-65880-6480"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + writableInterfaceTypeRfChannelPropEnum = append(writableInterfaceTypeRfChannelPropEnum, v) + } +} + +const ( + + // WritableInterfaceRfChannelNr2Dot4gDash1Dash2412Dash22 captures enum value "2.4g-1-2412-22" + WritableInterfaceRfChannelNr2Dot4gDash1Dash2412Dash22 string = "2.4g-1-2412-22" + + // WritableInterfaceRfChannelNr2Dot4gDash2Dash2417Dash22 captures enum value "2.4g-2-2417-22" + WritableInterfaceRfChannelNr2Dot4gDash2Dash2417Dash22 string = "2.4g-2-2417-22" + + // WritableInterfaceRfChannelNr2Dot4gDash3Dash2422Dash22 captures enum value "2.4g-3-2422-22" + WritableInterfaceRfChannelNr2Dot4gDash3Dash2422Dash22 string = "2.4g-3-2422-22" + + // WritableInterfaceRfChannelNr2Dot4gDash4Dash2427Dash22 captures enum value "2.4g-4-2427-22" + WritableInterfaceRfChannelNr2Dot4gDash4Dash2427Dash22 string = "2.4g-4-2427-22" + + // WritableInterfaceRfChannelNr2Dot4gDash5Dash2432Dash22 captures enum value "2.4g-5-2432-22" + WritableInterfaceRfChannelNr2Dot4gDash5Dash2432Dash22 string = "2.4g-5-2432-22" + + // WritableInterfaceRfChannelNr2Dot4gDash6Dash2437Dash22 captures enum value "2.4g-6-2437-22" + WritableInterfaceRfChannelNr2Dot4gDash6Dash2437Dash22 string = "2.4g-6-2437-22" + + // WritableInterfaceRfChannelNr2Dot4gDash7Dash2442Dash22 captures enum value "2.4g-7-2442-22" + WritableInterfaceRfChannelNr2Dot4gDash7Dash2442Dash22 string = "2.4g-7-2442-22" + + // WritableInterfaceRfChannelNr2Dot4gDash8Dash2447Dash22 captures enum value "2.4g-8-2447-22" + WritableInterfaceRfChannelNr2Dot4gDash8Dash2447Dash22 string = "2.4g-8-2447-22" + + // WritableInterfaceRfChannelNr2Dot4gDash9Dash2452Dash22 captures enum value "2.4g-9-2452-22" + WritableInterfaceRfChannelNr2Dot4gDash9Dash2452Dash22 string = "2.4g-9-2452-22" + + // WritableInterfaceRfChannelNr2Dot4gDash10Dash2457Dash22 captures enum value "2.4g-10-2457-22" + WritableInterfaceRfChannelNr2Dot4gDash10Dash2457Dash22 string = "2.4g-10-2457-22" + + // WritableInterfaceRfChannelNr2Dot4gDash11Dash2462Dash22 captures enum value "2.4g-11-2462-22" + WritableInterfaceRfChannelNr2Dot4gDash11Dash2462Dash22 string = "2.4g-11-2462-22" + + // WritableInterfaceRfChannelNr2Dot4gDash12Dash2467Dash22 captures enum value "2.4g-12-2467-22" + WritableInterfaceRfChannelNr2Dot4gDash12Dash2467Dash22 string = "2.4g-12-2467-22" + + // WritableInterfaceRfChannelNr2Dot4gDash13Dash2472Dash22 captures enum value "2.4g-13-2472-22" + WritableInterfaceRfChannelNr2Dot4gDash13Dash2472Dash22 string = "2.4g-13-2472-22" + + // WritableInterfaceRfChannelNr5gDash32Dash5160Dash20 captures enum value "5g-32-5160-20" + WritableInterfaceRfChannelNr5gDash32Dash5160Dash20 string = "5g-32-5160-20" + + // WritableInterfaceRfChannelNr5gDash34Dash5170Dash40 captures enum value "5g-34-5170-40" + WritableInterfaceRfChannelNr5gDash34Dash5170Dash40 string = "5g-34-5170-40" + + // WritableInterfaceRfChannelNr5gDash36Dash5180Dash20 captures enum value "5g-36-5180-20" + WritableInterfaceRfChannelNr5gDash36Dash5180Dash20 string = "5g-36-5180-20" + + // WritableInterfaceRfChannelNr5gDash38Dash5190Dash40 captures enum value "5g-38-5190-40" + WritableInterfaceRfChannelNr5gDash38Dash5190Dash40 string = "5g-38-5190-40" + + // WritableInterfaceRfChannelNr5gDash40Dash5200Dash20 captures enum value "5g-40-5200-20" + WritableInterfaceRfChannelNr5gDash40Dash5200Dash20 string = "5g-40-5200-20" + + // WritableInterfaceRfChannelNr5gDash42Dash5210Dash80 captures enum value "5g-42-5210-80" + WritableInterfaceRfChannelNr5gDash42Dash5210Dash80 string = "5g-42-5210-80" + + // WritableInterfaceRfChannelNr5gDash44Dash5220Dash20 captures enum value "5g-44-5220-20" + WritableInterfaceRfChannelNr5gDash44Dash5220Dash20 string = "5g-44-5220-20" + + // WritableInterfaceRfChannelNr5gDash46Dash5230Dash40 captures enum value "5g-46-5230-40" + WritableInterfaceRfChannelNr5gDash46Dash5230Dash40 string = "5g-46-5230-40" + + // WritableInterfaceRfChannelNr5gDash48Dash5240Dash20 captures enum value "5g-48-5240-20" + WritableInterfaceRfChannelNr5gDash48Dash5240Dash20 string = "5g-48-5240-20" + + // WritableInterfaceRfChannelNr5gDash50Dash5250Dash160 captures enum value "5g-50-5250-160" + WritableInterfaceRfChannelNr5gDash50Dash5250Dash160 string = "5g-50-5250-160" + + // WritableInterfaceRfChannelNr5gDash52Dash5260Dash20 captures enum value "5g-52-5260-20" + WritableInterfaceRfChannelNr5gDash52Dash5260Dash20 string = "5g-52-5260-20" + + // WritableInterfaceRfChannelNr5gDash54Dash5270Dash40 captures enum value "5g-54-5270-40" + WritableInterfaceRfChannelNr5gDash54Dash5270Dash40 string = "5g-54-5270-40" + + // WritableInterfaceRfChannelNr5gDash56Dash5280Dash20 captures enum value "5g-56-5280-20" + WritableInterfaceRfChannelNr5gDash56Dash5280Dash20 string = "5g-56-5280-20" + + // WritableInterfaceRfChannelNr5gDash58Dash5290Dash80 captures enum value "5g-58-5290-80" + WritableInterfaceRfChannelNr5gDash58Dash5290Dash80 string = "5g-58-5290-80" + + // WritableInterfaceRfChannelNr5gDash60Dash5300Dash20 captures enum value "5g-60-5300-20" + WritableInterfaceRfChannelNr5gDash60Dash5300Dash20 string = "5g-60-5300-20" + + // WritableInterfaceRfChannelNr5gDash62Dash5310Dash40 captures enum value "5g-62-5310-40" + WritableInterfaceRfChannelNr5gDash62Dash5310Dash40 string = "5g-62-5310-40" + + // WritableInterfaceRfChannelNr5gDash64Dash5320Dash20 captures enum value "5g-64-5320-20" + WritableInterfaceRfChannelNr5gDash64Dash5320Dash20 string = "5g-64-5320-20" + + // WritableInterfaceRfChannelNr5gDash100Dash5500Dash20 captures enum value "5g-100-5500-20" + WritableInterfaceRfChannelNr5gDash100Dash5500Dash20 string = "5g-100-5500-20" + + // WritableInterfaceRfChannelNr5gDash102Dash5510Dash40 captures enum value "5g-102-5510-40" + WritableInterfaceRfChannelNr5gDash102Dash5510Dash40 string = "5g-102-5510-40" + + // WritableInterfaceRfChannelNr5gDash104Dash5520Dash20 captures enum value "5g-104-5520-20" + WritableInterfaceRfChannelNr5gDash104Dash5520Dash20 string = "5g-104-5520-20" + + // WritableInterfaceRfChannelNr5gDash106Dash5530Dash80 captures enum value "5g-106-5530-80" + WritableInterfaceRfChannelNr5gDash106Dash5530Dash80 string = "5g-106-5530-80" + + // WritableInterfaceRfChannelNr5gDash108Dash5540Dash20 captures enum value "5g-108-5540-20" + WritableInterfaceRfChannelNr5gDash108Dash5540Dash20 string = "5g-108-5540-20" + + // WritableInterfaceRfChannelNr5gDash110Dash5550Dash40 captures enum value "5g-110-5550-40" + WritableInterfaceRfChannelNr5gDash110Dash5550Dash40 string = "5g-110-5550-40" + + // WritableInterfaceRfChannelNr5gDash112Dash5560Dash20 captures enum value "5g-112-5560-20" + WritableInterfaceRfChannelNr5gDash112Dash5560Dash20 string = "5g-112-5560-20" + + // WritableInterfaceRfChannelNr5gDash114Dash5570Dash160 captures enum value "5g-114-5570-160" + WritableInterfaceRfChannelNr5gDash114Dash5570Dash160 string = "5g-114-5570-160" + + // WritableInterfaceRfChannelNr5gDash116Dash5580Dash20 captures enum value "5g-116-5580-20" + WritableInterfaceRfChannelNr5gDash116Dash5580Dash20 string = "5g-116-5580-20" + + // WritableInterfaceRfChannelNr5gDash118Dash5590Dash40 captures enum value "5g-118-5590-40" + WritableInterfaceRfChannelNr5gDash118Dash5590Dash40 string = "5g-118-5590-40" + + // WritableInterfaceRfChannelNr5gDash120Dash5600Dash20 captures enum value "5g-120-5600-20" + WritableInterfaceRfChannelNr5gDash120Dash5600Dash20 string = "5g-120-5600-20" + + // WritableInterfaceRfChannelNr5gDash122Dash5610Dash80 captures enum value "5g-122-5610-80" + WritableInterfaceRfChannelNr5gDash122Dash5610Dash80 string = "5g-122-5610-80" + + // WritableInterfaceRfChannelNr5gDash124Dash5620Dash20 captures enum value "5g-124-5620-20" + WritableInterfaceRfChannelNr5gDash124Dash5620Dash20 string = "5g-124-5620-20" + + // WritableInterfaceRfChannelNr5gDash126Dash5630Dash40 captures enum value "5g-126-5630-40" + WritableInterfaceRfChannelNr5gDash126Dash5630Dash40 string = "5g-126-5630-40" + + // WritableInterfaceRfChannelNr5gDash128Dash5640Dash20 captures enum value "5g-128-5640-20" + WritableInterfaceRfChannelNr5gDash128Dash5640Dash20 string = "5g-128-5640-20" + + // WritableInterfaceRfChannelNr5gDash132Dash5660Dash20 captures enum value "5g-132-5660-20" + WritableInterfaceRfChannelNr5gDash132Dash5660Dash20 string = "5g-132-5660-20" + + // WritableInterfaceRfChannelNr5gDash134Dash5670Dash40 captures enum value "5g-134-5670-40" + WritableInterfaceRfChannelNr5gDash134Dash5670Dash40 string = "5g-134-5670-40" + + // WritableInterfaceRfChannelNr5gDash136Dash5680Dash20 captures enum value "5g-136-5680-20" + WritableInterfaceRfChannelNr5gDash136Dash5680Dash20 string = "5g-136-5680-20" + + // WritableInterfaceRfChannelNr5gDash138Dash5690Dash80 captures enum value "5g-138-5690-80" + WritableInterfaceRfChannelNr5gDash138Dash5690Dash80 string = "5g-138-5690-80" + + // WritableInterfaceRfChannelNr5gDash140Dash5700Dash20 captures enum value "5g-140-5700-20" + WritableInterfaceRfChannelNr5gDash140Dash5700Dash20 string = "5g-140-5700-20" + + // WritableInterfaceRfChannelNr5gDash142Dash5710Dash40 captures enum value "5g-142-5710-40" + WritableInterfaceRfChannelNr5gDash142Dash5710Dash40 string = "5g-142-5710-40" + + // WritableInterfaceRfChannelNr5gDash144Dash5720Dash20 captures enum value "5g-144-5720-20" + WritableInterfaceRfChannelNr5gDash144Dash5720Dash20 string = "5g-144-5720-20" + + // WritableInterfaceRfChannelNr5gDash149Dash5745Dash20 captures enum value "5g-149-5745-20" + WritableInterfaceRfChannelNr5gDash149Dash5745Dash20 string = "5g-149-5745-20" + + // WritableInterfaceRfChannelNr5gDash151Dash5755Dash40 captures enum value "5g-151-5755-40" + WritableInterfaceRfChannelNr5gDash151Dash5755Dash40 string = "5g-151-5755-40" + + // WritableInterfaceRfChannelNr5gDash153Dash5765Dash20 captures enum value "5g-153-5765-20" + WritableInterfaceRfChannelNr5gDash153Dash5765Dash20 string = "5g-153-5765-20" + + // WritableInterfaceRfChannelNr5gDash155Dash5775Dash80 captures enum value "5g-155-5775-80" + WritableInterfaceRfChannelNr5gDash155Dash5775Dash80 string = "5g-155-5775-80" + + // WritableInterfaceRfChannelNr5gDash157Dash5785Dash20 captures enum value "5g-157-5785-20" + WritableInterfaceRfChannelNr5gDash157Dash5785Dash20 string = "5g-157-5785-20" + + // WritableInterfaceRfChannelNr5gDash159Dash5795Dash40 captures enum value "5g-159-5795-40" + WritableInterfaceRfChannelNr5gDash159Dash5795Dash40 string = "5g-159-5795-40" + + // WritableInterfaceRfChannelNr5gDash161Dash5805Dash20 captures enum value "5g-161-5805-20" + WritableInterfaceRfChannelNr5gDash161Dash5805Dash20 string = "5g-161-5805-20" + + // WritableInterfaceRfChannelNr5gDash163Dash5815Dash160 captures enum value "5g-163-5815-160" + WritableInterfaceRfChannelNr5gDash163Dash5815Dash160 string = "5g-163-5815-160" + + // WritableInterfaceRfChannelNr5gDash165Dash5825Dash20 captures enum value "5g-165-5825-20" + WritableInterfaceRfChannelNr5gDash165Dash5825Dash20 string = "5g-165-5825-20" + + // WritableInterfaceRfChannelNr5gDash167Dash5835Dash40 captures enum value "5g-167-5835-40" + WritableInterfaceRfChannelNr5gDash167Dash5835Dash40 string = "5g-167-5835-40" + + // WritableInterfaceRfChannelNr5gDash169Dash5845Dash20 captures enum value "5g-169-5845-20" + WritableInterfaceRfChannelNr5gDash169Dash5845Dash20 string = "5g-169-5845-20" + + // WritableInterfaceRfChannelNr5gDash171Dash5855Dash80 captures enum value "5g-171-5855-80" + WritableInterfaceRfChannelNr5gDash171Dash5855Dash80 string = "5g-171-5855-80" + + // WritableInterfaceRfChannelNr5gDash173Dash5865Dash20 captures enum value "5g-173-5865-20" + WritableInterfaceRfChannelNr5gDash173Dash5865Dash20 string = "5g-173-5865-20" + + // WritableInterfaceRfChannelNr5gDash175Dash5875Dash40 captures enum value "5g-175-5875-40" + WritableInterfaceRfChannelNr5gDash175Dash5875Dash40 string = "5g-175-5875-40" + + // WritableInterfaceRfChannelNr5gDash177Dash5885Dash20 captures enum value "5g-177-5885-20" + WritableInterfaceRfChannelNr5gDash177Dash5885Dash20 string = "5g-177-5885-20" + + // WritableInterfaceRfChannelNr6gDash1Dash5955Dash20 captures enum value "6g-1-5955-20" + WritableInterfaceRfChannelNr6gDash1Dash5955Dash20 string = "6g-1-5955-20" + + // WritableInterfaceRfChannelNr6gDash3Dash5965Dash40 captures enum value "6g-3-5965-40" + WritableInterfaceRfChannelNr6gDash3Dash5965Dash40 string = "6g-3-5965-40" + + // WritableInterfaceRfChannelNr6gDash5Dash5975Dash20 captures enum value "6g-5-5975-20" + WritableInterfaceRfChannelNr6gDash5Dash5975Dash20 string = "6g-5-5975-20" + + // WritableInterfaceRfChannelNr6gDash7Dash5985Dash80 captures enum value "6g-7-5985-80" + WritableInterfaceRfChannelNr6gDash7Dash5985Dash80 string = "6g-7-5985-80" + + // WritableInterfaceRfChannelNr6gDash9Dash5995Dash20 captures enum value "6g-9-5995-20" + WritableInterfaceRfChannelNr6gDash9Dash5995Dash20 string = "6g-9-5995-20" + + // WritableInterfaceRfChannelNr6gDash11Dash6005Dash40 captures enum value "6g-11-6005-40" + WritableInterfaceRfChannelNr6gDash11Dash6005Dash40 string = "6g-11-6005-40" + + // WritableInterfaceRfChannelNr6gDash13Dash6015Dash20 captures enum value "6g-13-6015-20" + WritableInterfaceRfChannelNr6gDash13Dash6015Dash20 string = "6g-13-6015-20" + + // WritableInterfaceRfChannelNr6gDash15Dash6025Dash160 captures enum value "6g-15-6025-160" + WritableInterfaceRfChannelNr6gDash15Dash6025Dash160 string = "6g-15-6025-160" + + // WritableInterfaceRfChannelNr6gDash17Dash6035Dash20 captures enum value "6g-17-6035-20" + WritableInterfaceRfChannelNr6gDash17Dash6035Dash20 string = "6g-17-6035-20" + + // WritableInterfaceRfChannelNr6gDash19Dash6045Dash40 captures enum value "6g-19-6045-40" + WritableInterfaceRfChannelNr6gDash19Dash6045Dash40 string = "6g-19-6045-40" + + // WritableInterfaceRfChannelNr6gDash21Dash6055Dash20 captures enum value "6g-21-6055-20" + WritableInterfaceRfChannelNr6gDash21Dash6055Dash20 string = "6g-21-6055-20" + + // WritableInterfaceRfChannelNr6gDash23Dash6065Dash80 captures enum value "6g-23-6065-80" + WritableInterfaceRfChannelNr6gDash23Dash6065Dash80 string = "6g-23-6065-80" + + // WritableInterfaceRfChannelNr6gDash25Dash6075Dash20 captures enum value "6g-25-6075-20" + WritableInterfaceRfChannelNr6gDash25Dash6075Dash20 string = "6g-25-6075-20" + + // WritableInterfaceRfChannelNr6gDash27Dash6085Dash40 captures enum value "6g-27-6085-40" + WritableInterfaceRfChannelNr6gDash27Dash6085Dash40 string = "6g-27-6085-40" + + // WritableInterfaceRfChannelNr6gDash29Dash6095Dash20 captures enum value "6g-29-6095-20" + WritableInterfaceRfChannelNr6gDash29Dash6095Dash20 string = "6g-29-6095-20" + + // WritableInterfaceRfChannelNr6gDash31Dash6105Dash320 captures enum value "6g-31-6105-320" + WritableInterfaceRfChannelNr6gDash31Dash6105Dash320 string = "6g-31-6105-320" + + // WritableInterfaceRfChannelNr6gDash33Dash6115Dash20 captures enum value "6g-33-6115-20" + WritableInterfaceRfChannelNr6gDash33Dash6115Dash20 string = "6g-33-6115-20" + + // WritableInterfaceRfChannelNr6gDash35Dash6125Dash40 captures enum value "6g-35-6125-40" + WritableInterfaceRfChannelNr6gDash35Dash6125Dash40 string = "6g-35-6125-40" + + // WritableInterfaceRfChannelNr6gDash37Dash6135Dash20 captures enum value "6g-37-6135-20" + WritableInterfaceRfChannelNr6gDash37Dash6135Dash20 string = "6g-37-6135-20" + + // WritableInterfaceRfChannelNr6gDash39Dash6145Dash80 captures enum value "6g-39-6145-80" + WritableInterfaceRfChannelNr6gDash39Dash6145Dash80 string = "6g-39-6145-80" + + // WritableInterfaceRfChannelNr6gDash41Dash6155Dash20 captures enum value "6g-41-6155-20" + WritableInterfaceRfChannelNr6gDash41Dash6155Dash20 string = "6g-41-6155-20" + + // WritableInterfaceRfChannelNr6gDash43Dash6165Dash40 captures enum value "6g-43-6165-40" + WritableInterfaceRfChannelNr6gDash43Dash6165Dash40 string = "6g-43-6165-40" + + // WritableInterfaceRfChannelNr6gDash45Dash6175Dash20 captures enum value "6g-45-6175-20" + WritableInterfaceRfChannelNr6gDash45Dash6175Dash20 string = "6g-45-6175-20" + + // WritableInterfaceRfChannelNr6gDash47Dash6185Dash160 captures enum value "6g-47-6185-160" + WritableInterfaceRfChannelNr6gDash47Dash6185Dash160 string = "6g-47-6185-160" + + // WritableInterfaceRfChannelNr6gDash49Dash6195Dash20 captures enum value "6g-49-6195-20" + WritableInterfaceRfChannelNr6gDash49Dash6195Dash20 string = "6g-49-6195-20" + + // WritableInterfaceRfChannelNr6gDash51Dash6205Dash40 captures enum value "6g-51-6205-40" + WritableInterfaceRfChannelNr6gDash51Dash6205Dash40 string = "6g-51-6205-40" + + // WritableInterfaceRfChannelNr6gDash53Dash6215Dash20 captures enum value "6g-53-6215-20" + WritableInterfaceRfChannelNr6gDash53Dash6215Dash20 string = "6g-53-6215-20" + + // WritableInterfaceRfChannelNr6gDash55Dash6225Dash80 captures enum value "6g-55-6225-80" + WritableInterfaceRfChannelNr6gDash55Dash6225Dash80 string = "6g-55-6225-80" + + // WritableInterfaceRfChannelNr6gDash57Dash6235Dash20 captures enum value "6g-57-6235-20" + WritableInterfaceRfChannelNr6gDash57Dash6235Dash20 string = "6g-57-6235-20" + + // WritableInterfaceRfChannelNr6gDash59Dash6245Dash40 captures enum value "6g-59-6245-40" + WritableInterfaceRfChannelNr6gDash59Dash6245Dash40 string = "6g-59-6245-40" + + // WritableInterfaceRfChannelNr6gDash61Dash6255Dash20 captures enum value "6g-61-6255-20" + WritableInterfaceRfChannelNr6gDash61Dash6255Dash20 string = "6g-61-6255-20" + + // WritableInterfaceRfChannelNr6gDash65Dash6275Dash20 captures enum value "6g-65-6275-20" + WritableInterfaceRfChannelNr6gDash65Dash6275Dash20 string = "6g-65-6275-20" + + // WritableInterfaceRfChannelNr6gDash67Dash6285Dash40 captures enum value "6g-67-6285-40" + WritableInterfaceRfChannelNr6gDash67Dash6285Dash40 string = "6g-67-6285-40" + + // WritableInterfaceRfChannelNr6gDash69Dash6295Dash20 captures enum value "6g-69-6295-20" + WritableInterfaceRfChannelNr6gDash69Dash6295Dash20 string = "6g-69-6295-20" + + // WritableInterfaceRfChannelNr6gDash71Dash6305Dash80 captures enum value "6g-71-6305-80" + WritableInterfaceRfChannelNr6gDash71Dash6305Dash80 string = "6g-71-6305-80" + + // WritableInterfaceRfChannelNr6gDash73Dash6315Dash20 captures enum value "6g-73-6315-20" + WritableInterfaceRfChannelNr6gDash73Dash6315Dash20 string = "6g-73-6315-20" + + // WritableInterfaceRfChannelNr6gDash75Dash6325Dash40 captures enum value "6g-75-6325-40" + WritableInterfaceRfChannelNr6gDash75Dash6325Dash40 string = "6g-75-6325-40" + + // WritableInterfaceRfChannelNr6gDash77Dash6335Dash20 captures enum value "6g-77-6335-20" + WritableInterfaceRfChannelNr6gDash77Dash6335Dash20 string = "6g-77-6335-20" + + // WritableInterfaceRfChannelNr6gDash79Dash6345Dash160 captures enum value "6g-79-6345-160" + WritableInterfaceRfChannelNr6gDash79Dash6345Dash160 string = "6g-79-6345-160" + + // WritableInterfaceRfChannelNr6gDash81Dash6355Dash20 captures enum value "6g-81-6355-20" + WritableInterfaceRfChannelNr6gDash81Dash6355Dash20 string = "6g-81-6355-20" + + // WritableInterfaceRfChannelNr6gDash83Dash6365Dash40 captures enum value "6g-83-6365-40" + WritableInterfaceRfChannelNr6gDash83Dash6365Dash40 string = "6g-83-6365-40" + + // WritableInterfaceRfChannelNr6gDash85Dash6375Dash20 captures enum value "6g-85-6375-20" + WritableInterfaceRfChannelNr6gDash85Dash6375Dash20 string = "6g-85-6375-20" + + // WritableInterfaceRfChannelNr6gDash87Dash6385Dash80 captures enum value "6g-87-6385-80" + WritableInterfaceRfChannelNr6gDash87Dash6385Dash80 string = "6g-87-6385-80" + + // WritableInterfaceRfChannelNr6gDash89Dash6395Dash20 captures enum value "6g-89-6395-20" + WritableInterfaceRfChannelNr6gDash89Dash6395Dash20 string = "6g-89-6395-20" + + // WritableInterfaceRfChannelNr6gDash91Dash6405Dash40 captures enum value "6g-91-6405-40" + WritableInterfaceRfChannelNr6gDash91Dash6405Dash40 string = "6g-91-6405-40" + + // WritableInterfaceRfChannelNr6gDash93Dash6415Dash20 captures enum value "6g-93-6415-20" + WritableInterfaceRfChannelNr6gDash93Dash6415Dash20 string = "6g-93-6415-20" + + // WritableInterfaceRfChannelNr6gDash95Dash6425Dash320 captures enum value "6g-95-6425-320" + WritableInterfaceRfChannelNr6gDash95Dash6425Dash320 string = "6g-95-6425-320" + + // WritableInterfaceRfChannelNr6gDash97Dash6435Dash20 captures enum value "6g-97-6435-20" + WritableInterfaceRfChannelNr6gDash97Dash6435Dash20 string = "6g-97-6435-20" + + // WritableInterfaceRfChannelNr6gDash99Dash6445Dash40 captures enum value "6g-99-6445-40" + WritableInterfaceRfChannelNr6gDash99Dash6445Dash40 string = "6g-99-6445-40" + + // WritableInterfaceRfChannelNr6gDash101Dash6455Dash20 captures enum value "6g-101-6455-20" + WritableInterfaceRfChannelNr6gDash101Dash6455Dash20 string = "6g-101-6455-20" + + // WritableInterfaceRfChannelNr6gDash103Dash6465Dash80 captures enum value "6g-103-6465-80" + WritableInterfaceRfChannelNr6gDash103Dash6465Dash80 string = "6g-103-6465-80" + + // WritableInterfaceRfChannelNr6gDash105Dash6475Dash20 captures enum value "6g-105-6475-20" + WritableInterfaceRfChannelNr6gDash105Dash6475Dash20 string = "6g-105-6475-20" + + // WritableInterfaceRfChannelNr6gDash107Dash6485Dash40 captures enum value "6g-107-6485-40" + WritableInterfaceRfChannelNr6gDash107Dash6485Dash40 string = "6g-107-6485-40" + + // WritableInterfaceRfChannelNr6gDash109Dash6495Dash20 captures enum value "6g-109-6495-20" + WritableInterfaceRfChannelNr6gDash109Dash6495Dash20 string = "6g-109-6495-20" + + // WritableInterfaceRfChannelNr6gDash111Dash6505Dash160 captures enum value "6g-111-6505-160" + WritableInterfaceRfChannelNr6gDash111Dash6505Dash160 string = "6g-111-6505-160" + + // WritableInterfaceRfChannelNr6gDash113Dash6515Dash20 captures enum value "6g-113-6515-20" + WritableInterfaceRfChannelNr6gDash113Dash6515Dash20 string = "6g-113-6515-20" + + // WritableInterfaceRfChannelNr6gDash115Dash6525Dash40 captures enum value "6g-115-6525-40" + WritableInterfaceRfChannelNr6gDash115Dash6525Dash40 string = "6g-115-6525-40" + + // WritableInterfaceRfChannelNr6gDash117Dash6535Dash20 captures enum value "6g-117-6535-20" + WritableInterfaceRfChannelNr6gDash117Dash6535Dash20 string = "6g-117-6535-20" + + // WritableInterfaceRfChannelNr6gDash119Dash6545Dash80 captures enum value "6g-119-6545-80" + WritableInterfaceRfChannelNr6gDash119Dash6545Dash80 string = "6g-119-6545-80" + + // WritableInterfaceRfChannelNr6gDash121Dash6555Dash20 captures enum value "6g-121-6555-20" + WritableInterfaceRfChannelNr6gDash121Dash6555Dash20 string = "6g-121-6555-20" + + // WritableInterfaceRfChannelNr6gDash123Dash6565Dash40 captures enum value "6g-123-6565-40" + WritableInterfaceRfChannelNr6gDash123Dash6565Dash40 string = "6g-123-6565-40" + + // WritableInterfaceRfChannelNr6gDash125Dash6575Dash20 captures enum value "6g-125-6575-20" + WritableInterfaceRfChannelNr6gDash125Dash6575Dash20 string = "6g-125-6575-20" + + // WritableInterfaceRfChannelNr6gDash129Dash6595Dash20 captures enum value "6g-129-6595-20" + WritableInterfaceRfChannelNr6gDash129Dash6595Dash20 string = "6g-129-6595-20" + + // WritableInterfaceRfChannelNr6gDash131Dash6605Dash40 captures enum value "6g-131-6605-40" + WritableInterfaceRfChannelNr6gDash131Dash6605Dash40 string = "6g-131-6605-40" + + // WritableInterfaceRfChannelNr6gDash133Dash6615Dash20 captures enum value "6g-133-6615-20" + WritableInterfaceRfChannelNr6gDash133Dash6615Dash20 string = "6g-133-6615-20" + + // WritableInterfaceRfChannelNr6gDash135Dash6625Dash80 captures enum value "6g-135-6625-80" + WritableInterfaceRfChannelNr6gDash135Dash6625Dash80 string = "6g-135-6625-80" + + // WritableInterfaceRfChannelNr6gDash137Dash6635Dash20 captures enum value "6g-137-6635-20" + WritableInterfaceRfChannelNr6gDash137Dash6635Dash20 string = "6g-137-6635-20" + + // WritableInterfaceRfChannelNr6gDash139Dash6645Dash40 captures enum value "6g-139-6645-40" + WritableInterfaceRfChannelNr6gDash139Dash6645Dash40 string = "6g-139-6645-40" + + // WritableInterfaceRfChannelNr6gDash141Dash6655Dash20 captures enum value "6g-141-6655-20" + WritableInterfaceRfChannelNr6gDash141Dash6655Dash20 string = "6g-141-6655-20" + + // WritableInterfaceRfChannelNr6gDash143Dash6665Dash160 captures enum value "6g-143-6665-160" + WritableInterfaceRfChannelNr6gDash143Dash6665Dash160 string = "6g-143-6665-160" + + // WritableInterfaceRfChannelNr6gDash145Dash6675Dash20 captures enum value "6g-145-6675-20" + WritableInterfaceRfChannelNr6gDash145Dash6675Dash20 string = "6g-145-6675-20" + + // WritableInterfaceRfChannelNr6gDash147Dash6685Dash40 captures enum value "6g-147-6685-40" + WritableInterfaceRfChannelNr6gDash147Dash6685Dash40 string = "6g-147-6685-40" + + // WritableInterfaceRfChannelNr6gDash149Dash6695Dash20 captures enum value "6g-149-6695-20" + WritableInterfaceRfChannelNr6gDash149Dash6695Dash20 string = "6g-149-6695-20" + + // WritableInterfaceRfChannelNr6gDash151Dash6705Dash80 captures enum value "6g-151-6705-80" + WritableInterfaceRfChannelNr6gDash151Dash6705Dash80 string = "6g-151-6705-80" + + // WritableInterfaceRfChannelNr6gDash153Dash6715Dash20 captures enum value "6g-153-6715-20" + WritableInterfaceRfChannelNr6gDash153Dash6715Dash20 string = "6g-153-6715-20" + + // WritableInterfaceRfChannelNr6gDash155Dash6725Dash40 captures enum value "6g-155-6725-40" + WritableInterfaceRfChannelNr6gDash155Dash6725Dash40 string = "6g-155-6725-40" + + // WritableInterfaceRfChannelNr6gDash157Dash6735Dash20 captures enum value "6g-157-6735-20" + WritableInterfaceRfChannelNr6gDash157Dash6735Dash20 string = "6g-157-6735-20" + + // WritableInterfaceRfChannelNr6gDash159Dash6745Dash320 captures enum value "6g-159-6745-320" + WritableInterfaceRfChannelNr6gDash159Dash6745Dash320 string = "6g-159-6745-320" + + // WritableInterfaceRfChannelNr6gDash161Dash6755Dash20 captures enum value "6g-161-6755-20" + WritableInterfaceRfChannelNr6gDash161Dash6755Dash20 string = "6g-161-6755-20" + + // WritableInterfaceRfChannelNr6gDash163Dash6765Dash40 captures enum value "6g-163-6765-40" + WritableInterfaceRfChannelNr6gDash163Dash6765Dash40 string = "6g-163-6765-40" + + // WritableInterfaceRfChannelNr6gDash165Dash6775Dash20 captures enum value "6g-165-6775-20" + WritableInterfaceRfChannelNr6gDash165Dash6775Dash20 string = "6g-165-6775-20" + + // WritableInterfaceRfChannelNr6gDash167Dash6785Dash80 captures enum value "6g-167-6785-80" + WritableInterfaceRfChannelNr6gDash167Dash6785Dash80 string = "6g-167-6785-80" + + // WritableInterfaceRfChannelNr6gDash169Dash6795Dash20 captures enum value "6g-169-6795-20" + WritableInterfaceRfChannelNr6gDash169Dash6795Dash20 string = "6g-169-6795-20" + + // WritableInterfaceRfChannelNr6gDash171Dash6805Dash40 captures enum value "6g-171-6805-40" + WritableInterfaceRfChannelNr6gDash171Dash6805Dash40 string = "6g-171-6805-40" + + // WritableInterfaceRfChannelNr6gDash173Dash6815Dash20 captures enum value "6g-173-6815-20" + WritableInterfaceRfChannelNr6gDash173Dash6815Dash20 string = "6g-173-6815-20" + + // WritableInterfaceRfChannelNr6gDash175Dash6825Dash160 captures enum value "6g-175-6825-160" + WritableInterfaceRfChannelNr6gDash175Dash6825Dash160 string = "6g-175-6825-160" + + // WritableInterfaceRfChannelNr6gDash177Dash6835Dash20 captures enum value "6g-177-6835-20" + WritableInterfaceRfChannelNr6gDash177Dash6835Dash20 string = "6g-177-6835-20" + + // WritableInterfaceRfChannelNr6gDash179Dash6845Dash40 captures enum value "6g-179-6845-40" + WritableInterfaceRfChannelNr6gDash179Dash6845Dash40 string = "6g-179-6845-40" + + // WritableInterfaceRfChannelNr6gDash181Dash6855Dash20 captures enum value "6g-181-6855-20" + WritableInterfaceRfChannelNr6gDash181Dash6855Dash20 string = "6g-181-6855-20" + + // WritableInterfaceRfChannelNr6gDash183Dash6865Dash80 captures enum value "6g-183-6865-80" + WritableInterfaceRfChannelNr6gDash183Dash6865Dash80 string = "6g-183-6865-80" + + // WritableInterfaceRfChannelNr6gDash185Dash6875Dash20 captures enum value "6g-185-6875-20" + WritableInterfaceRfChannelNr6gDash185Dash6875Dash20 string = "6g-185-6875-20" + + // WritableInterfaceRfChannelNr6gDash187Dash6885Dash40 captures enum value "6g-187-6885-40" + WritableInterfaceRfChannelNr6gDash187Dash6885Dash40 string = "6g-187-6885-40" + + // WritableInterfaceRfChannelNr6gDash189Dash6895Dash20 captures enum value "6g-189-6895-20" + WritableInterfaceRfChannelNr6gDash189Dash6895Dash20 string = "6g-189-6895-20" + + // WritableInterfaceRfChannelNr6gDash193Dash6915Dash20 captures enum value "6g-193-6915-20" + WritableInterfaceRfChannelNr6gDash193Dash6915Dash20 string = "6g-193-6915-20" + + // WritableInterfaceRfChannelNr6gDash195Dash6925Dash40 captures enum value "6g-195-6925-40" + WritableInterfaceRfChannelNr6gDash195Dash6925Dash40 string = "6g-195-6925-40" + + // WritableInterfaceRfChannelNr6gDash197Dash6935Dash20 captures enum value "6g-197-6935-20" + WritableInterfaceRfChannelNr6gDash197Dash6935Dash20 string = "6g-197-6935-20" + + // WritableInterfaceRfChannelNr6gDash199Dash6945Dash80 captures enum value "6g-199-6945-80" + WritableInterfaceRfChannelNr6gDash199Dash6945Dash80 string = "6g-199-6945-80" + + // WritableInterfaceRfChannelNr6gDash201Dash6955Dash20 captures enum value "6g-201-6955-20" + WritableInterfaceRfChannelNr6gDash201Dash6955Dash20 string = "6g-201-6955-20" + + // WritableInterfaceRfChannelNr6gDash203Dash6965Dash40 captures enum value "6g-203-6965-40" + WritableInterfaceRfChannelNr6gDash203Dash6965Dash40 string = "6g-203-6965-40" + + // WritableInterfaceRfChannelNr6gDash205Dash6975Dash20 captures enum value "6g-205-6975-20" + WritableInterfaceRfChannelNr6gDash205Dash6975Dash20 string = "6g-205-6975-20" + + // WritableInterfaceRfChannelNr6gDash207Dash6985Dash160 captures enum value "6g-207-6985-160" + WritableInterfaceRfChannelNr6gDash207Dash6985Dash160 string = "6g-207-6985-160" + + // WritableInterfaceRfChannelNr6gDash209Dash6995Dash20 captures enum value "6g-209-6995-20" + WritableInterfaceRfChannelNr6gDash209Dash6995Dash20 string = "6g-209-6995-20" + + // WritableInterfaceRfChannelNr6gDash211Dash7005Dash40 captures enum value "6g-211-7005-40" + WritableInterfaceRfChannelNr6gDash211Dash7005Dash40 string = "6g-211-7005-40" + + // WritableInterfaceRfChannelNr6gDash213Dash7015Dash20 captures enum value "6g-213-7015-20" + WritableInterfaceRfChannelNr6gDash213Dash7015Dash20 string = "6g-213-7015-20" + + // WritableInterfaceRfChannelNr6gDash215Dash7025Dash80 captures enum value "6g-215-7025-80" + WritableInterfaceRfChannelNr6gDash215Dash7025Dash80 string = "6g-215-7025-80" + + // WritableInterfaceRfChannelNr6gDash217Dash7035Dash20 captures enum value "6g-217-7035-20" + WritableInterfaceRfChannelNr6gDash217Dash7035Dash20 string = "6g-217-7035-20" + + // WritableInterfaceRfChannelNr6gDash219Dash7045Dash40 captures enum value "6g-219-7045-40" + WritableInterfaceRfChannelNr6gDash219Dash7045Dash40 string = "6g-219-7045-40" + + // WritableInterfaceRfChannelNr6gDash221Dash7055Dash20 captures enum value "6g-221-7055-20" + WritableInterfaceRfChannelNr6gDash221Dash7055Dash20 string = "6g-221-7055-20" + + // WritableInterfaceRfChannelNr6gDash225Dash7075Dash20 captures enum value "6g-225-7075-20" + WritableInterfaceRfChannelNr6gDash225Dash7075Dash20 string = "6g-225-7075-20" + + // WritableInterfaceRfChannelNr6gDash227Dash7085Dash40 captures enum value "6g-227-7085-40" + WritableInterfaceRfChannelNr6gDash227Dash7085Dash40 string = "6g-227-7085-40" + + // WritableInterfaceRfChannelNr6gDash229Dash7095Dash20 captures enum value "6g-229-7095-20" + WritableInterfaceRfChannelNr6gDash229Dash7095Dash20 string = "6g-229-7095-20" + + // WritableInterfaceRfChannelNr6gDash233Dash7115Dash20 captures enum value "6g-233-7115-20" + WritableInterfaceRfChannelNr6gDash233Dash7115Dash20 string = "6g-233-7115-20" + + // WritableInterfaceRfChannelNr60gDash1Dash58320Dash2160 captures enum value "60g-1-58320-2160" + WritableInterfaceRfChannelNr60gDash1Dash58320Dash2160 string = "60g-1-58320-2160" + + // WritableInterfaceRfChannelNr60gDash2Dash60480Dash2160 captures enum value "60g-2-60480-2160" + WritableInterfaceRfChannelNr60gDash2Dash60480Dash2160 string = "60g-2-60480-2160" + + // WritableInterfaceRfChannelNr60gDash3Dash62640Dash2160 captures enum value "60g-3-62640-2160" + WritableInterfaceRfChannelNr60gDash3Dash62640Dash2160 string = "60g-3-62640-2160" + + // WritableInterfaceRfChannelNr60gDash4Dash64800Dash2160 captures enum value "60g-4-64800-2160" + WritableInterfaceRfChannelNr60gDash4Dash64800Dash2160 string = "60g-4-64800-2160" + + // WritableInterfaceRfChannelNr60gDash5Dash66960Dash2160 captures enum value "60g-5-66960-2160" + WritableInterfaceRfChannelNr60gDash5Dash66960Dash2160 string = "60g-5-66960-2160" + + // WritableInterfaceRfChannelNr60gDash6Dash69120Dash2160 captures enum value "60g-6-69120-2160" + WritableInterfaceRfChannelNr60gDash6Dash69120Dash2160 string = "60g-6-69120-2160" + + // WritableInterfaceRfChannelNr60gDash9Dash59400Dash4320 captures enum value "60g-9-59400-4320" + WritableInterfaceRfChannelNr60gDash9Dash59400Dash4320 string = "60g-9-59400-4320" + + // WritableInterfaceRfChannelNr60gDash10Dash61560Dash4320 captures enum value "60g-10-61560-4320" + WritableInterfaceRfChannelNr60gDash10Dash61560Dash4320 string = "60g-10-61560-4320" + + // WritableInterfaceRfChannelNr60gDash11Dash63720Dash4320 captures enum value "60g-11-63720-4320" + WritableInterfaceRfChannelNr60gDash11Dash63720Dash4320 string = "60g-11-63720-4320" + + // WritableInterfaceRfChannelNr60gDash12Dash65880Dash4320 captures enum value "60g-12-65880-4320" + WritableInterfaceRfChannelNr60gDash12Dash65880Dash4320 string = "60g-12-65880-4320" + + // WritableInterfaceRfChannelNr60gDash13Dash68040Dash4320 captures enum value "60g-13-68040-4320" + WritableInterfaceRfChannelNr60gDash13Dash68040Dash4320 string = "60g-13-68040-4320" + + // WritableInterfaceRfChannelNr60gDash17Dash60480Dash6480 captures enum value "60g-17-60480-6480" + WritableInterfaceRfChannelNr60gDash17Dash60480Dash6480 string = "60g-17-60480-6480" + + // WritableInterfaceRfChannelNr60gDash18Dash62640Dash6480 captures enum value "60g-18-62640-6480" + WritableInterfaceRfChannelNr60gDash18Dash62640Dash6480 string = "60g-18-62640-6480" + + // WritableInterfaceRfChannelNr60gDash19Dash64800Dash6480 captures enum value "60g-19-64800-6480" + WritableInterfaceRfChannelNr60gDash19Dash64800Dash6480 string = "60g-19-64800-6480" + + // WritableInterfaceRfChannelNr60gDash20Dash66960Dash6480 captures enum value "60g-20-66960-6480" + WritableInterfaceRfChannelNr60gDash20Dash66960Dash6480 string = "60g-20-66960-6480" + + // WritableInterfaceRfChannelNr60gDash25Dash61560Dash6480 captures enum value "60g-25-61560-6480" + WritableInterfaceRfChannelNr60gDash25Dash61560Dash6480 string = "60g-25-61560-6480" + + // WritableInterfaceRfChannelNr60gDash26Dash63720Dash6480 captures enum value "60g-26-63720-6480" + WritableInterfaceRfChannelNr60gDash26Dash63720Dash6480 string = "60g-26-63720-6480" + + // WritableInterfaceRfChannelNr60gDash27Dash65880Dash6480 captures enum value "60g-27-65880-6480" + WritableInterfaceRfChannelNr60gDash27Dash65880Dash6480 string = "60g-27-65880-6480" +) + +// prop value enum +func (m *WritableInterface) validateRfChannelEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, writableInterfaceTypeRfChannelPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WritableInterface) validateRfChannel(formats strfmt.Registry) error { + if swag.IsZero(m.RfChannel) { // not required + return nil + } + + // value enum + if err := m.validateRfChannelEnum("rf_channel", "body", m.RfChannel); err != nil { + return err + } + + return nil +} + +var writableInterfaceTypeRfRolePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["ap","station"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + writableInterfaceTypeRfRolePropEnum = append(writableInterfaceTypeRfRolePropEnum, v) + } +} + +const ( + + // WritableInterfaceRfRoleAp captures enum value "ap" + WritableInterfaceRfRoleAp string = "ap" + + // WritableInterfaceRfRoleStation captures enum value "station" + WritableInterfaceRfRoleStation string = "station" +) + +// prop value enum +func (m *WritableInterface) validateRfRoleEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, writableInterfaceTypeRfRolePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WritableInterface) validateRfRole(formats strfmt.Registry) error { + if swag.IsZero(m.RfRole) { // not required + return nil + } + + // value enum + if err := m.validateRfRoleEnum("rf_role", "body", m.RfRole); err != nil { + return err + } + + return nil +} + func (m *WritableInterface) validateTaggedVlans(formats strfmt.Registry) error { if swag.IsZero(m.TaggedVlans) { // not required return nil @@ -422,11 +1145,27 @@ func (m *WritableInterface) validateTags(formats strfmt.Registry) error { return nil } +func (m *WritableInterface) validateTxPower(formats strfmt.Registry) error { + if swag.IsZero(m.TxPower) { // not required + return nil + } + + if err := validate.MinimumInt("tx_power", "body", *m.TxPower, 0, false); err != nil { + return err + } + + if err := validate.MaximumInt("tx_power", "body", *m.TxPower, 127, false); err != nil { + return err + } + + return nil +} + var writableInterfaceTypeTypePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["virtual","lag","100base-tx","1000base-t","2.5gbase-t","5gbase-t","10gbase-t","10gbase-cx4","1000base-x-gbic","1000base-x-sfp","10gbase-x-sfpp","10gbase-x-xfp","10gbase-x-xenpak","10gbase-x-x2","25gbase-x-sfp28","50gbase-x-sfp56","40gbase-x-qsfpp","50gbase-x-sfp28","100gbase-x-cfp","100gbase-x-cfp2","200gbase-x-cfp2","100gbase-x-cfp4","100gbase-x-cpak","100gbase-x-qsfp28","200gbase-x-qsfp56","400gbase-x-qsfpdd","400gbase-x-osfp","ieee802.11a","ieee802.11g","ieee802.11n","ieee802.11ac","ieee802.11ad","ieee802.11ax","ieee802.15.1","gsm","cdma","lte","sonet-oc3","sonet-oc12","sonet-oc48","sonet-oc192","sonet-oc768","sonet-oc1920","sonet-oc3840","1gfc-sfp","2gfc-sfp","4gfc-sfp","8gfc-sfpp","16gfc-sfpp","32gfc-sfp28","64gfc-qsfpp","128gfc-sfp28","infiniband-sdr","infiniband-ddr","infiniband-qdr","infiniband-fdr10","infiniband-fdr","infiniband-edr","infiniband-hdr","infiniband-ndr","infiniband-xdr","t1","e1","t3","e3","xdsl","cisco-stackwise","cisco-stackwise-plus","cisco-flexstack","cisco-flexstack-plus","juniper-vcp","extreme-summitstack","extreme-summitstack-128","extreme-summitstack-256","extreme-summitstack-512","other"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["virtual","bridge","lag","100base-tx","1000base-t","2.5gbase-t","5gbase-t","10gbase-t","10gbase-cx4","1000base-x-gbic","1000base-x-sfp","10gbase-x-sfpp","10gbase-x-xfp","10gbase-x-xenpak","10gbase-x-x2","25gbase-x-sfp28","50gbase-x-sfp56","40gbase-x-qsfpp","50gbase-x-sfp28","100gbase-x-cfp","100gbase-x-cfp2","200gbase-x-cfp2","100gbase-x-cfp4","100gbase-x-cpak","100gbase-x-qsfp28","200gbase-x-qsfp56","400gbase-x-qsfpdd","400gbase-x-osfp","ieee802.11a","ieee802.11g","ieee802.11n","ieee802.11ac","ieee802.11ad","ieee802.11ax","ieee802.15.1","gsm","cdma","lte","sonet-oc3","sonet-oc12","sonet-oc48","sonet-oc192","sonet-oc768","sonet-oc1920","sonet-oc3840","1gfc-sfp","2gfc-sfp","4gfc-sfp","8gfc-sfpp","16gfc-sfpp","32gfc-sfp28","64gfc-qsfpp","128gfc-qsfp28","infiniband-sdr","infiniband-ddr","infiniband-qdr","infiniband-fdr10","infiniband-fdr","infiniband-edr","infiniband-hdr","infiniband-ndr","infiniband-xdr","t1","e1","t3","e3","xdsl","cisco-stackwise","cisco-stackwise-plus","cisco-flexstack","cisco-flexstack-plus","cisco-stackwise-80","cisco-stackwise-160","cisco-stackwise-320","cisco-stackwise-480","juniper-vcp","extreme-summitstack","extreme-summitstack-128","extreme-summitstack-256","extreme-summitstack-512","other"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -439,6 +1178,9 @@ const ( // WritableInterfaceTypeVirtual captures enum value "virtual" WritableInterfaceTypeVirtual string = "virtual" + // WritableInterfaceTypeBridge captures enum value "bridge" + WritableInterfaceTypeBridge string = "bridge" + // WritableInterfaceTypeLag captures enum value "lag" WritableInterfaceTypeLag string = "lag" @@ -589,8 +1331,8 @@ const ( // WritableInterfaceTypeNr64gfcDashQsfpp captures enum value "64gfc-qsfpp" WritableInterfaceTypeNr64gfcDashQsfpp string = "64gfc-qsfpp" - // WritableInterfaceTypeNr128gfcDashSfp28 captures enum value "128gfc-sfp28" - WritableInterfaceTypeNr128gfcDashSfp28 string = "128gfc-sfp28" + // WritableInterfaceTypeNr128gfcDashQsfp28 captures enum value "128gfc-qsfp28" + WritableInterfaceTypeNr128gfcDashQsfp28 string = "128gfc-qsfp28" // WritableInterfaceTypeInfinibandDashSdr captures enum value "infiniband-sdr" WritableInterfaceTypeInfinibandDashSdr string = "infiniband-sdr" @@ -646,6 +1388,18 @@ const ( // WritableInterfaceTypeCiscoDashFlexstackDashPlus captures enum value "cisco-flexstack-plus" WritableInterfaceTypeCiscoDashFlexstackDashPlus string = "cisco-flexstack-plus" + // WritableInterfaceTypeCiscoDashStackwiseDash80 captures enum value "cisco-stackwise-80" + WritableInterfaceTypeCiscoDashStackwiseDash80 string = "cisco-stackwise-80" + + // WritableInterfaceTypeCiscoDashStackwiseDash160 captures enum value "cisco-stackwise-160" + WritableInterfaceTypeCiscoDashStackwiseDash160 string = "cisco-stackwise-160" + + // WritableInterfaceTypeCiscoDashStackwiseDash320 captures enum value "cisco-stackwise-320" + WritableInterfaceTypeCiscoDashStackwiseDash320 string = "cisco-stackwise-320" + + // WritableInterfaceTypeCiscoDashStackwiseDash480 captures enum value "cisco-stackwise-480" + WritableInterfaceTypeCiscoDashStackwiseDash480 string = "cisco-stackwise-480" + // WritableInterfaceTypeJuniperDashVcp captures enum value "juniper-vcp" WritableInterfaceTypeJuniperDashVcp string = "juniper-vcp" @@ -699,6 +1453,18 @@ func (m *WritableInterface) validateURL(formats strfmt.Registry) error { return nil } +func (m *WritableInterface) validateWirelessLans(formats strfmt.Registry) error { + if swag.IsZero(m.WirelessLans) { // not required + return nil + } + + if err := validate.UniqueItems("wireless_lans", "body", m.WirelessLans); err != nil { + return err + } + + return nil +} + // ContextValidate validate this writable interface based on the context it is used func (m *WritableInterface) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error @@ -711,14 +1477,6 @@ func (m *WritableInterface) ContextValidate(ctx context.Context, formats strfmt. res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { - res = append(res, err) - } - if err := m.contextValidateConnectedEndpoint(ctx, formats); err != nil { res = append(res, err) } @@ -731,6 +1489,10 @@ func (m *WritableInterface) ContextValidate(ctx context.Context, formats strfmt. res = append(res, err) } + if err := m.contextValidateCountFhrpGroups(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateCountIpaddresses(ctx, formats); err != nil { res = append(res, err) } @@ -751,6 +1513,14 @@ func (m *WritableInterface) ContextValidate(ctx context.Context, formats strfmt. res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTags(ctx, formats); err != nil { res = append(res, err) } @@ -790,37 +1560,32 @@ func (m *WritableInterface) contextValidateCable(ctx context.Context, formats st return nil } -func (m *WritableInterface) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { +func (m *WritableInterface) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil } -func (m *WritableInterface) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { +func (m *WritableInterface) contextValidateConnectedEndpointReachable(ctx context.Context, formats strfmt.Registry) error { - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { + if err := validate.ReadOnly(ctx, "connected_endpoint_reachable", "body", m.ConnectedEndpointReachable); err != nil { return err } return nil } -func (m *WritableInterface) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *WritableInterface) contextValidateConnectedEndpointReachable(ctx context.Context, formats strfmt.Registry) error { +func (m *WritableInterface) contextValidateConnectedEndpointType(ctx context.Context, formats strfmt.Registry) error { - if err := validate.ReadOnly(ctx, "connected_endpoint_reachable", "body", m.ConnectedEndpointReachable); err != nil { + if err := validate.ReadOnly(ctx, "connected_endpoint_type", "body", string(m.ConnectedEndpointType)); err != nil { return err } return nil } -func (m *WritableInterface) contextValidateConnectedEndpointType(ctx context.Context, formats strfmt.Registry) error { +func (m *WritableInterface) contextValidateCountFhrpGroups(ctx context.Context, formats strfmt.Registry) error { - if err := validate.ReadOnly(ctx, "connected_endpoint_type", "body", string(m.ConnectedEndpointType)); err != nil { + if err := validate.ReadOnly(ctx, "count_fhrp_groups", "body", int64(m.CountFhrpGroups)); err != nil { return err } @@ -872,6 +1637,20 @@ func (m *WritableInterface) contextValidateLastUpdated(ctx context.Context, form return nil } +func (m *WritableInterface) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *WritableInterface) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *WritableInterface) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { diff --git a/netbox/models/writable_interface_template.go b/netbox/models/writable_interface_template.go index c4a28dda..e26e741c 100644 --- a/netbox/models/writable_interface_template.go +++ b/netbox/models/writable_interface_template.go @@ -78,7 +78,7 @@ type WritableInterfaceTemplate struct { // Type // Required: true - // Enum: [virtual lag 100base-tx 1000base-t 2.5gbase-t 5gbase-t 10gbase-t 10gbase-cx4 1000base-x-gbic 1000base-x-sfp 10gbase-x-sfpp 10gbase-x-xfp 10gbase-x-xenpak 10gbase-x-x2 25gbase-x-sfp28 50gbase-x-sfp56 40gbase-x-qsfpp 50gbase-x-sfp28 100gbase-x-cfp 100gbase-x-cfp2 200gbase-x-cfp2 100gbase-x-cfp4 100gbase-x-cpak 100gbase-x-qsfp28 200gbase-x-qsfp56 400gbase-x-qsfpdd 400gbase-x-osfp ieee802.11a ieee802.11g ieee802.11n ieee802.11ac ieee802.11ad ieee802.11ax ieee802.15.1 gsm cdma lte sonet-oc3 sonet-oc12 sonet-oc48 sonet-oc192 sonet-oc768 sonet-oc1920 sonet-oc3840 1gfc-sfp 2gfc-sfp 4gfc-sfp 8gfc-sfpp 16gfc-sfpp 32gfc-sfp28 64gfc-qsfpp 128gfc-sfp28 infiniband-sdr infiniband-ddr infiniband-qdr infiniband-fdr10 infiniband-fdr infiniband-edr infiniband-hdr infiniband-ndr infiniband-xdr t1 e1 t3 e3 xdsl cisco-stackwise cisco-stackwise-plus cisco-flexstack cisco-flexstack-plus juniper-vcp extreme-summitstack extreme-summitstack-128 extreme-summitstack-256 extreme-summitstack-512 other] + // Enum: [virtual bridge lag 100base-tx 1000base-t 2.5gbase-t 5gbase-t 10gbase-t 10gbase-cx4 1000base-x-gbic 1000base-x-sfp 10gbase-x-sfpp 10gbase-x-xfp 10gbase-x-xenpak 10gbase-x-x2 25gbase-x-sfp28 50gbase-x-sfp56 40gbase-x-qsfpp 50gbase-x-sfp28 100gbase-x-cfp 100gbase-x-cfp2 200gbase-x-cfp2 100gbase-x-cfp4 100gbase-x-cpak 100gbase-x-qsfp28 200gbase-x-qsfp56 400gbase-x-qsfpdd 400gbase-x-osfp ieee802.11a ieee802.11g ieee802.11n ieee802.11ac ieee802.11ad ieee802.11ax ieee802.15.1 gsm cdma lte sonet-oc3 sonet-oc12 sonet-oc48 sonet-oc192 sonet-oc768 sonet-oc1920 sonet-oc3840 1gfc-sfp 2gfc-sfp 4gfc-sfp 8gfc-sfpp 16gfc-sfpp 32gfc-sfp28 64gfc-qsfpp 128gfc-qsfp28 infiniband-sdr infiniband-ddr infiniband-qdr infiniband-fdr10 infiniband-fdr infiniband-edr infiniband-hdr infiniband-ndr infiniband-xdr t1 e1 t3 e3 xdsl cisco-stackwise cisco-stackwise-plus cisco-flexstack cisco-flexstack-plus cisco-stackwise-80 cisco-stackwise-160 cisco-stackwise-320 cisco-stackwise-480 juniper-vcp extreme-summitstack extreme-summitstack-128 extreme-summitstack-256 extreme-summitstack-512 other] Type *string `json:"type"` // Url @@ -207,7 +207,7 @@ var writableInterfaceTemplateTypeTypePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["virtual","lag","100base-tx","1000base-t","2.5gbase-t","5gbase-t","10gbase-t","10gbase-cx4","1000base-x-gbic","1000base-x-sfp","10gbase-x-sfpp","10gbase-x-xfp","10gbase-x-xenpak","10gbase-x-x2","25gbase-x-sfp28","50gbase-x-sfp56","40gbase-x-qsfpp","50gbase-x-sfp28","100gbase-x-cfp","100gbase-x-cfp2","200gbase-x-cfp2","100gbase-x-cfp4","100gbase-x-cpak","100gbase-x-qsfp28","200gbase-x-qsfp56","400gbase-x-qsfpdd","400gbase-x-osfp","ieee802.11a","ieee802.11g","ieee802.11n","ieee802.11ac","ieee802.11ad","ieee802.11ax","ieee802.15.1","gsm","cdma","lte","sonet-oc3","sonet-oc12","sonet-oc48","sonet-oc192","sonet-oc768","sonet-oc1920","sonet-oc3840","1gfc-sfp","2gfc-sfp","4gfc-sfp","8gfc-sfpp","16gfc-sfpp","32gfc-sfp28","64gfc-qsfpp","128gfc-sfp28","infiniband-sdr","infiniband-ddr","infiniband-qdr","infiniband-fdr10","infiniband-fdr","infiniband-edr","infiniband-hdr","infiniband-ndr","infiniband-xdr","t1","e1","t3","e3","xdsl","cisco-stackwise","cisco-stackwise-plus","cisco-flexstack","cisco-flexstack-plus","juniper-vcp","extreme-summitstack","extreme-summitstack-128","extreme-summitstack-256","extreme-summitstack-512","other"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["virtual","bridge","lag","100base-tx","1000base-t","2.5gbase-t","5gbase-t","10gbase-t","10gbase-cx4","1000base-x-gbic","1000base-x-sfp","10gbase-x-sfpp","10gbase-x-xfp","10gbase-x-xenpak","10gbase-x-x2","25gbase-x-sfp28","50gbase-x-sfp56","40gbase-x-qsfpp","50gbase-x-sfp28","100gbase-x-cfp","100gbase-x-cfp2","200gbase-x-cfp2","100gbase-x-cfp4","100gbase-x-cpak","100gbase-x-qsfp28","200gbase-x-qsfp56","400gbase-x-qsfpdd","400gbase-x-osfp","ieee802.11a","ieee802.11g","ieee802.11n","ieee802.11ac","ieee802.11ad","ieee802.11ax","ieee802.15.1","gsm","cdma","lte","sonet-oc3","sonet-oc12","sonet-oc48","sonet-oc192","sonet-oc768","sonet-oc1920","sonet-oc3840","1gfc-sfp","2gfc-sfp","4gfc-sfp","8gfc-sfpp","16gfc-sfpp","32gfc-sfp28","64gfc-qsfpp","128gfc-qsfp28","infiniband-sdr","infiniband-ddr","infiniband-qdr","infiniband-fdr10","infiniband-fdr","infiniband-edr","infiniband-hdr","infiniband-ndr","infiniband-xdr","t1","e1","t3","e3","xdsl","cisco-stackwise","cisco-stackwise-plus","cisco-flexstack","cisco-flexstack-plus","cisco-stackwise-80","cisco-stackwise-160","cisco-stackwise-320","cisco-stackwise-480","juniper-vcp","extreme-summitstack","extreme-summitstack-128","extreme-summitstack-256","extreme-summitstack-512","other"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -220,6 +220,9 @@ const ( // WritableInterfaceTemplateTypeVirtual captures enum value "virtual" WritableInterfaceTemplateTypeVirtual string = "virtual" + // WritableInterfaceTemplateTypeBridge captures enum value "bridge" + WritableInterfaceTemplateTypeBridge string = "bridge" + // WritableInterfaceTemplateTypeLag captures enum value "lag" WritableInterfaceTemplateTypeLag string = "lag" @@ -370,8 +373,8 @@ const ( // WritableInterfaceTemplateTypeNr64gfcDashQsfpp captures enum value "64gfc-qsfpp" WritableInterfaceTemplateTypeNr64gfcDashQsfpp string = "64gfc-qsfpp" - // WritableInterfaceTemplateTypeNr128gfcDashSfp28 captures enum value "128gfc-sfp28" - WritableInterfaceTemplateTypeNr128gfcDashSfp28 string = "128gfc-sfp28" + // WritableInterfaceTemplateTypeNr128gfcDashQsfp28 captures enum value "128gfc-qsfp28" + WritableInterfaceTemplateTypeNr128gfcDashQsfp28 string = "128gfc-qsfp28" // WritableInterfaceTemplateTypeInfinibandDashSdr captures enum value "infiniband-sdr" WritableInterfaceTemplateTypeInfinibandDashSdr string = "infiniband-sdr" @@ -427,6 +430,18 @@ const ( // WritableInterfaceTemplateTypeCiscoDashFlexstackDashPlus captures enum value "cisco-flexstack-plus" WritableInterfaceTemplateTypeCiscoDashFlexstackDashPlus string = "cisco-flexstack-plus" + // WritableInterfaceTemplateTypeCiscoDashStackwiseDash80 captures enum value "cisco-stackwise-80" + WritableInterfaceTemplateTypeCiscoDashStackwiseDash80 string = "cisco-stackwise-80" + + // WritableInterfaceTemplateTypeCiscoDashStackwiseDash160 captures enum value "cisco-stackwise-160" + WritableInterfaceTemplateTypeCiscoDashStackwiseDash160 string = "cisco-stackwise-160" + + // WritableInterfaceTemplateTypeCiscoDashStackwiseDash320 captures enum value "cisco-stackwise-320" + WritableInterfaceTemplateTypeCiscoDashStackwiseDash320 string = "cisco-stackwise-320" + + // WritableInterfaceTemplateTypeCiscoDashStackwiseDash480 captures enum value "cisco-stackwise-480" + WritableInterfaceTemplateTypeCiscoDashStackwiseDash480 string = "cisco-stackwise-480" + // WritableInterfaceTemplateTypeJuniperDashVcp captures enum value "juniper-vcp" WritableInterfaceTemplateTypeJuniperDashVcp string = "juniper-vcp" diff --git a/netbox/models/writable_ip_address.go b/netbox/models/writable_ip_address.go index ac8956b5..466ca16e 100644 --- a/netbox/models/writable_ip_address.go +++ b/netbox/models/writable_ip_address.go @@ -74,7 +74,7 @@ type WritableIPAddress struct { // // Hostname or FQDN (not case-sensitive) // Max Length: 255 - // Pattern: ^[0-9A-Za-z._-]+$ + // Pattern: ^([0-9A-Za-z_-]+|\*)(\.[0-9A-Za-z_-]+)*\.?$ DNSName string `json:"dns_name,omitempty"` // Family @@ -234,7 +234,7 @@ func (m *WritableIPAddress) validateDNSName(formats strfmt.Registry) error { return err } - if err := validate.Pattern("dns_name", "body", m.DNSName, `^[0-9A-Za-z._-]+$`); err != nil { + if err := validate.Pattern("dns_name", "body", m.DNSName, `^([0-9A-Za-z_-]+|\*)(\.[0-9A-Za-z_-]+)*\.?$`); err != nil { return err } diff --git a/netbox/models/writable_location.go b/netbox/models/writable_location.go index 24c19dd0..4e2e51c5 100644 --- a/netbox/models/writable_location.go +++ b/netbox/models/writable_location.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -91,6 +92,12 @@ type WritableLocation struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + + // Tenant + Tenant *int64 `json:"tenant,omitempty"` + // Url // Read Only: true // Format: uri @@ -125,6 +132,10 @@ func (m *WritableLocation) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -218,6 +229,32 @@ func (m *WritableLocation) validateSlug(formats strfmt.Registry) error { return nil } +func (m *WritableLocation) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *WritableLocation) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -262,6 +299,10 @@ func (m *WritableLocation) ContextValidate(ctx context.Context, formats strfmt.R res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -335,6 +376,26 @@ func (m *WritableLocation) contextValidateRackCount(ctx context.Context, formats return nil } +func (m *WritableLocation) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *WritableLocation) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/writable_platform.go b/netbox/models/writable_platform.go index 04e45d22..80149fe9 100644 --- a/netbox/models/writable_platform.go +++ b/netbox/models/writable_platform.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -92,6 +93,9 @@ type WritablePlatform struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -130,6 +134,10 @@ func (m *WritablePlatform) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -226,6 +234,32 @@ func (m *WritablePlatform) validateSlug(formats strfmt.Registry) error { return nil } +func (m *WritablePlatform) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *WritablePlatform) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -262,6 +296,10 @@ func (m *WritablePlatform) ContextValidate(ctx context.Context, formats strfmt.R res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -321,6 +359,26 @@ func (m *WritablePlatform) contextValidateLastUpdated(ctx context.Context, forma return nil } +func (m *WritablePlatform) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *WritablePlatform) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/writable_power_feed.go b/netbox/models/writable_power_feed.go index 7a21f187..8fbbc695 100644 --- a/netbox/models/writable_power_feed.go +++ b/netbox/models/writable_power_feed.go @@ -48,18 +48,6 @@ type WritablePowerFeed struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Comments Comments string `json:"comments,omitempty"` @@ -100,6 +88,18 @@ type WritablePowerFeed struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -562,14 +562,6 @@ func (m *WritablePowerFeed) ContextValidate(ctx context.Context, formats strfmt. res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { - res = append(res, err) - } - if err := m.contextValidateConnectedEndpoint(ctx, formats); err != nil { res = append(res, err) } @@ -598,6 +590,14 @@ func (m *WritablePowerFeed) ContextValidate(ctx context.Context, formats strfmt. res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTags(ctx, formats); err != nil { res = append(res, err) } @@ -637,20 +637,6 @@ func (m *WritablePowerFeed) contextValidateCable(ctx context.Context, formats st return nil } -func (m *WritablePowerFeed) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *WritablePowerFeed) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *WritablePowerFeed) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil @@ -710,6 +696,20 @@ func (m *WritablePowerFeed) contextValidateLastUpdated(ctx context.Context, form return nil } +func (m *WritablePowerFeed) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *WritablePowerFeed) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *WritablePowerFeed) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { diff --git a/netbox/models/writable_power_outlet.go b/netbox/models/writable_power_outlet.go index 8731067f..187db30a 100644 --- a/netbox/models/writable_power_outlet.go +++ b/netbox/models/writable_power_outlet.go @@ -43,18 +43,6 @@ type WritablePowerOutlet struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Connected endpoint // // @@ -112,6 +100,18 @@ type WritablePowerOutlet struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -132,7 +132,7 @@ type WritablePowerOutlet struct { // Type // // Physical port type - // Enum: [iec-60320-c5 iec-60320-c7 iec-60320-c13 iec-60320-c15 iec-60320-c19 iec-60320-c21 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15r nema-5-15r nema-5-20r nema-5-30r nema-5-50r nema-6-15r nema-6-20r nema-6-30r nema-6-50r nema-10-30r nema-10-50r nema-14-20r nema-14-30r nema-14-50r nema-14-60r nema-15-15r nema-15-20r nema-15-30r nema-15-50r nema-15-60r nema-l1-15r nema-l5-15r nema-l5-20r nema-l5-30r nema-l5-50r nema-l6-15r nema-l6-20r nema-l6-30r nema-l6-50r nema-l10-30r nema-l14-20r nema-l14-30r nema-l14-50r nema-l14-60r nema-l15-20r nema-l15-30r nema-l15-50r nema-l15-60r nema-l21-20r nema-l21-30r CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ita-e ita-f ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-micro-b usb-c dc-terminal hdot-cx saf-d-grid hardwired] + // Enum: [iec-60320-c5 iec-60320-c7 iec-60320-c13 iec-60320-c15 iec-60320-c19 iec-60320-c21 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15r nema-5-15r nema-5-20r nema-5-30r nema-5-50r nema-6-15r nema-6-20r nema-6-30r nema-6-50r nema-10-30r nema-10-50r nema-14-20r nema-14-30r nema-14-50r nema-14-60r nema-15-15r nema-15-20r nema-15-30r nema-15-50r nema-15-60r nema-l1-15r nema-l5-15r nema-l5-20r nema-l5-30r nema-l5-50r nema-l6-15r nema-l6-20r nema-l6-30r nema-l6-50r nema-l10-30r nema-l14-20r nema-l14-30r nema-l14-50r nema-l14-60r nema-l15-20r nema-l15-30r nema-l15-50r nema-l15-60r nema-l21-20r nema-l21-30r nema-l22-30r CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ita-e ita-f ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o ita-multistandard usb-a usb-micro-b usb-c dc-terminal hdot-cx saf-d-grid hardwired] Type string `json:"type,omitempty"` // Url @@ -363,7 +363,7 @@ var writablePowerOutletTypeTypePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["iec-60320-c5","iec-60320-c7","iec-60320-c13","iec-60320-c15","iec-60320-c19","iec-60320-c21","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15r","nema-5-15r","nema-5-20r","nema-5-30r","nema-5-50r","nema-6-15r","nema-6-20r","nema-6-30r","nema-6-50r","nema-10-30r","nema-10-50r","nema-14-20r","nema-14-30r","nema-14-50r","nema-14-60r","nema-15-15r","nema-15-20r","nema-15-30r","nema-15-50r","nema-15-60r","nema-l1-15r","nema-l5-15r","nema-l5-20r","nema-l5-30r","nema-l5-50r","nema-l6-15r","nema-l6-20r","nema-l6-30r","nema-l6-50r","nema-l10-30r","nema-l14-20r","nema-l14-30r","nema-l14-50r","nema-l14-60r","nema-l15-20r","nema-l15-30r","nema-l15-50r","nema-l15-60r","nema-l21-20r","nema-l21-30r","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ita-e","ita-f","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-micro-b","usb-c","dc-terminal","hdot-cx","saf-d-grid","hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["iec-60320-c5","iec-60320-c7","iec-60320-c13","iec-60320-c15","iec-60320-c19","iec-60320-c21","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15r","nema-5-15r","nema-5-20r","nema-5-30r","nema-5-50r","nema-6-15r","nema-6-20r","nema-6-30r","nema-6-50r","nema-10-30r","nema-10-50r","nema-14-20r","nema-14-30r","nema-14-50r","nema-14-60r","nema-15-15r","nema-15-20r","nema-15-30r","nema-15-50r","nema-15-60r","nema-l1-15r","nema-l5-15r","nema-l5-20r","nema-l5-30r","nema-l5-50r","nema-l6-15r","nema-l6-20r","nema-l6-30r","nema-l6-50r","nema-l10-30r","nema-l14-20r","nema-l14-30r","nema-l14-50r","nema-l14-60r","nema-l15-20r","nema-l15-30r","nema-l15-50r","nema-l15-60r","nema-l21-20r","nema-l21-30r","nema-l22-30r","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ita-e","ita-f","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","ita-multistandard","usb-a","usb-micro-b","usb-c","dc-terminal","hdot-cx","saf-d-grid","hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -547,6 +547,9 @@ const ( // WritablePowerOutletTypeNemaDashL21Dash30r captures enum value "nema-l21-30r" WritablePowerOutletTypeNemaDashL21Dash30r string = "nema-l21-30r" + // WritablePowerOutletTypeNemaDashL22Dash30r captures enum value "nema-l22-30r" + WritablePowerOutletTypeNemaDashL22Dash30r string = "nema-l22-30r" + // WritablePowerOutletTypeCS6360C captures enum value "CS6360C" WritablePowerOutletTypeCS6360C string = "CS6360C" @@ -598,6 +601,9 @@ const ( // WritablePowerOutletTypeItaDasho captures enum value "ita-o" WritablePowerOutletTypeItaDasho string = "ita-o" + // WritablePowerOutletTypeItaDashMultistandard captures enum value "ita-multistandard" + WritablePowerOutletTypeItaDashMultistandard string = "ita-multistandard" + // WritablePowerOutletTypeUsbDasha captures enum value "usb-a" WritablePowerOutletTypeUsbDasha string = "usb-a" @@ -665,14 +671,6 @@ func (m *WritablePowerOutlet) ContextValidate(ctx context.Context, formats strfm res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { - res = append(res, err) - } - if err := m.contextValidateConnectedEndpoint(ctx, formats); err != nil { res = append(res, err) } @@ -701,6 +699,14 @@ func (m *WritablePowerOutlet) ContextValidate(ctx context.Context, formats strfm res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTags(ctx, formats); err != nil { res = append(res, err) } @@ -740,20 +746,6 @@ func (m *WritablePowerOutlet) contextValidateCable(ctx context.Context, formats return nil } -func (m *WritablePowerOutlet) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *WritablePowerOutlet) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *WritablePowerOutlet) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil @@ -813,6 +805,20 @@ func (m *WritablePowerOutlet) contextValidateLastUpdated(ctx context.Context, fo return nil } +func (m *WritablePowerOutlet) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *WritablePowerOutlet) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *WritablePowerOutlet) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { diff --git a/netbox/models/writable_power_outlet_template.go b/netbox/models/writable_power_outlet_template.go index ae94dfb8..25748123 100644 --- a/netbox/models/writable_power_outlet_template.go +++ b/netbox/models/writable_power_outlet_template.go @@ -83,7 +83,7 @@ type WritablePowerOutletTemplate struct { PowerPort *int64 `json:"power_port,omitempty"` // Type - // Enum: [iec-60320-c5 iec-60320-c7 iec-60320-c13 iec-60320-c15 iec-60320-c19 iec-60320-c21 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15r nema-5-15r nema-5-20r nema-5-30r nema-5-50r nema-6-15r nema-6-20r nema-6-30r nema-6-50r nema-10-30r nema-10-50r nema-14-20r nema-14-30r nema-14-50r nema-14-60r nema-15-15r nema-15-20r nema-15-30r nema-15-50r nema-15-60r nema-l1-15r nema-l5-15r nema-l5-20r nema-l5-30r nema-l5-50r nema-l6-15r nema-l6-20r nema-l6-30r nema-l6-50r nema-l10-30r nema-l14-20r nema-l14-30r nema-l14-50r nema-l14-60r nema-l15-20r nema-l15-30r nema-l15-50r nema-l15-60r nema-l21-20r nema-l21-30r CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ita-e ita-f ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-micro-b usb-c dc-terminal hdot-cx saf-d-grid hardwired] + // Enum: [iec-60320-c5 iec-60320-c7 iec-60320-c13 iec-60320-c15 iec-60320-c19 iec-60320-c21 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15r nema-5-15r nema-5-20r nema-5-30r nema-5-50r nema-6-15r nema-6-20r nema-6-30r nema-6-50r nema-10-30r nema-10-50r nema-14-20r nema-14-30r nema-14-50r nema-14-60r nema-15-15r nema-15-20r nema-15-30r nema-15-50r nema-15-60r nema-l1-15r nema-l5-15r nema-l5-20r nema-l5-30r nema-l5-50r nema-l6-15r nema-l6-20r nema-l6-30r nema-l6-50r nema-l10-30r nema-l14-20r nema-l14-30r nema-l14-50r nema-l14-60r nema-l15-20r nema-l15-30r nema-l15-50r nema-l15-60r nema-l21-20r nema-l21-30r nema-l22-30r CS6360C CS6364C CS8164C CS8264C CS8364C CS8464C ita-e ita-f ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o ita-multistandard usb-a usb-micro-b usb-c dc-terminal hdot-cx saf-d-grid hardwired] Type string `json:"type,omitempty"` // Url @@ -261,7 +261,7 @@ var writablePowerOutletTemplateTypeTypePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["iec-60320-c5","iec-60320-c7","iec-60320-c13","iec-60320-c15","iec-60320-c19","iec-60320-c21","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15r","nema-5-15r","nema-5-20r","nema-5-30r","nema-5-50r","nema-6-15r","nema-6-20r","nema-6-30r","nema-6-50r","nema-10-30r","nema-10-50r","nema-14-20r","nema-14-30r","nema-14-50r","nema-14-60r","nema-15-15r","nema-15-20r","nema-15-30r","nema-15-50r","nema-15-60r","nema-l1-15r","nema-l5-15r","nema-l5-20r","nema-l5-30r","nema-l5-50r","nema-l6-15r","nema-l6-20r","nema-l6-30r","nema-l6-50r","nema-l10-30r","nema-l14-20r","nema-l14-30r","nema-l14-50r","nema-l14-60r","nema-l15-20r","nema-l15-30r","nema-l15-50r","nema-l15-60r","nema-l21-20r","nema-l21-30r","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ita-e","ita-f","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-micro-b","usb-c","dc-terminal","hdot-cx","saf-d-grid","hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["iec-60320-c5","iec-60320-c7","iec-60320-c13","iec-60320-c15","iec-60320-c19","iec-60320-c21","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15r","nema-5-15r","nema-5-20r","nema-5-30r","nema-5-50r","nema-6-15r","nema-6-20r","nema-6-30r","nema-6-50r","nema-10-30r","nema-10-50r","nema-14-20r","nema-14-30r","nema-14-50r","nema-14-60r","nema-15-15r","nema-15-20r","nema-15-30r","nema-15-50r","nema-15-60r","nema-l1-15r","nema-l5-15r","nema-l5-20r","nema-l5-30r","nema-l5-50r","nema-l6-15r","nema-l6-20r","nema-l6-30r","nema-l6-50r","nema-l10-30r","nema-l14-20r","nema-l14-30r","nema-l14-50r","nema-l14-60r","nema-l15-20r","nema-l15-30r","nema-l15-50r","nema-l15-60r","nema-l21-20r","nema-l21-30r","nema-l22-30r","CS6360C","CS6364C","CS8164C","CS8264C","CS8364C","CS8464C","ita-e","ita-f","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","ita-multistandard","usb-a","usb-micro-b","usb-c","dc-terminal","hdot-cx","saf-d-grid","hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -445,6 +445,9 @@ const ( // WritablePowerOutletTemplateTypeNemaDashL21Dash30r captures enum value "nema-l21-30r" WritablePowerOutletTemplateTypeNemaDashL21Dash30r string = "nema-l21-30r" + // WritablePowerOutletTemplateTypeNemaDashL22Dash30r captures enum value "nema-l22-30r" + WritablePowerOutletTemplateTypeNemaDashL22Dash30r string = "nema-l22-30r" + // WritablePowerOutletTemplateTypeCS6360C captures enum value "CS6360C" WritablePowerOutletTemplateTypeCS6360C string = "CS6360C" @@ -496,6 +499,9 @@ const ( // WritablePowerOutletTemplateTypeItaDasho captures enum value "ita-o" WritablePowerOutletTemplateTypeItaDasho string = "ita-o" + // WritablePowerOutletTemplateTypeItaDashMultistandard captures enum value "ita-multistandard" + WritablePowerOutletTemplateTypeItaDashMultistandard string = "ita-multistandard" + // WritablePowerOutletTemplateTypeUsbDasha captures enum value "usb-a" WritablePowerOutletTemplateTypeUsbDasha string = "usb-a" diff --git a/netbox/models/writable_power_panel.go b/netbox/models/writable_power_panel.go index 48fa7087..1da5770a 100644 --- a/netbox/models/writable_power_panel.go +++ b/netbox/models/writable_power_panel.go @@ -35,6 +35,11 @@ import ( // swagger:model WritablePowerPanel type WritablePowerPanel struct { + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Custom fields CustomFields interface{} `json:"custom_fields,omitempty"` @@ -46,6 +51,11 @@ type WritablePowerPanel struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Location Location *int64 `json:"location,omitempty"` @@ -76,6 +86,14 @@ type WritablePowerPanel struct { func (m *WritablePowerPanel) Validate(formats strfmt.Registry) error { var res []error + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateName(formats); err != nil { res = append(res, err) } @@ -98,6 +116,30 @@ func (m *WritablePowerPanel) Validate(formats strfmt.Registry) error { return nil } +func (m *WritablePowerPanel) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritablePowerPanel) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *WritablePowerPanel) validateName(formats strfmt.Registry) error { if err := validate.Required("name", "body", m.Name); err != nil { @@ -166,6 +208,10 @@ func (m *WritablePowerPanel) validateURL(formats strfmt.Registry) error { func (m *WritablePowerPanel) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -174,6 +220,10 @@ func (m *WritablePowerPanel) ContextValidate(ctx context.Context, formats strfmt res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidatePowerfeedCount(ctx, formats); err != nil { res = append(res, err) } @@ -192,6 +242,15 @@ func (m *WritablePowerPanel) ContextValidate(ctx context.Context, formats strfmt return nil } +func (m *WritablePowerPanel) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *WritablePowerPanel) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -210,6 +269,15 @@ func (m *WritablePowerPanel) contextValidateID(ctx context.Context, formats strf return nil } +func (m *WritablePowerPanel) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *WritablePowerPanel) contextValidatePowerfeedCount(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "powerfeed_count", "body", int64(m.PowerfeedCount)); err != nil { diff --git a/netbox/models/writable_power_port.go b/netbox/models/writable_power_port.go index 78c60ccd..00288944 100644 --- a/netbox/models/writable_power_port.go +++ b/netbox/models/writable_power_port.go @@ -50,18 +50,6 @@ type WritablePowerPort struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Connected endpoint // // @@ -113,6 +101,18 @@ type WritablePowerPort struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -137,7 +137,7 @@ type WritablePowerPort struct { // Type // // Physical port type - // Enum: [iec-60320-c6 iec-60320-c8 iec-60320-c14 iec-60320-c16 iec-60320-c20 iec-60320-c22 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15p nema-5-15p nema-5-20p nema-5-30p nema-5-50p nema-6-15p nema-6-20p nema-6-30p nema-6-50p nema-10-30p nema-10-50p nema-14-20p nema-14-30p nema-14-50p nema-14-60p nema-15-15p nema-15-20p nema-15-30p nema-15-50p nema-15-60p nema-l1-15p nema-l5-15p nema-l5-20p nema-l5-30p nema-l5-50p nema-l6-15p nema-l6-20p nema-l6-30p nema-l6-50p nema-l10-30p nema-l14-20p nema-l14-30p nema-l14-50p nema-l14-60p nema-l15-20p nema-l15-30p nema-l15-50p nema-l15-60p nema-l21-20p nema-l21-30p cs6361c cs6365c cs8165c cs8265c cs8365c cs8465c ita-c ita-e ita-f ita-ef ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-b usb-c usb-mini-a usb-mini-b usb-micro-a usb-micro-b usb-micro-ab usb-3-b usb-3-micro-b dc-terminal saf-d-grid hardwired] + // Enum: [iec-60320-c6 iec-60320-c8 iec-60320-c14 iec-60320-c16 iec-60320-c20 iec-60320-c22 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15p nema-5-15p nema-5-20p nema-5-30p nema-5-50p nema-6-15p nema-6-20p nema-6-30p nema-6-50p nema-10-30p nema-10-50p nema-14-20p nema-14-30p nema-14-50p nema-14-60p nema-15-15p nema-15-20p nema-15-30p nema-15-50p nema-15-60p nema-l1-15p nema-l5-15p nema-l5-20p nema-l5-30p nema-l5-50p nema-l6-15p nema-l6-20p nema-l6-30p nema-l6-50p nema-l10-30p nema-l14-20p nema-l14-30p nema-l14-50p nema-l14-60p nema-l15-20p nema-l15-30p nema-l15-50p nema-l15-60p nema-l21-20p nema-l21-30p nema-l22-30p cs6361c cs6365c cs8165c cs8265c cs8365c cs8465c ita-c ita-e ita-f ita-ef ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-b usb-c usb-mini-a usb-mini-b usb-micro-a usb-micro-b usb-micro-ab usb-3-b usb-3-micro-b dc-terminal saf-d-grid hardwired] Type string `json:"type,omitempty"` // Url @@ -359,7 +359,7 @@ var writablePowerPortTypeTypePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["iec-60320-c6","iec-60320-c8","iec-60320-c14","iec-60320-c16","iec-60320-c20","iec-60320-c22","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15p","nema-5-15p","nema-5-20p","nema-5-30p","nema-5-50p","nema-6-15p","nema-6-20p","nema-6-30p","nema-6-50p","nema-10-30p","nema-10-50p","nema-14-20p","nema-14-30p","nema-14-50p","nema-14-60p","nema-15-15p","nema-15-20p","nema-15-30p","nema-15-50p","nema-15-60p","nema-l1-15p","nema-l5-15p","nema-l5-20p","nema-l5-30p","nema-l5-50p","nema-l6-15p","nema-l6-20p","nema-l6-30p","nema-l6-50p","nema-l10-30p","nema-l14-20p","nema-l14-30p","nema-l14-50p","nema-l14-60p","nema-l15-20p","nema-l15-30p","nema-l15-50p","nema-l15-60p","nema-l21-20p","nema-l21-30p","cs6361c","cs6365c","cs8165c","cs8265c","cs8365c","cs8465c","ita-c","ita-e","ita-f","ita-ef","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-b","usb-c","usb-mini-a","usb-mini-b","usb-micro-a","usb-micro-b","usb-micro-ab","usb-3-b","usb-3-micro-b","dc-terminal","saf-d-grid","hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["iec-60320-c6","iec-60320-c8","iec-60320-c14","iec-60320-c16","iec-60320-c20","iec-60320-c22","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15p","nema-5-15p","nema-5-20p","nema-5-30p","nema-5-50p","nema-6-15p","nema-6-20p","nema-6-30p","nema-6-50p","nema-10-30p","nema-10-50p","nema-14-20p","nema-14-30p","nema-14-50p","nema-14-60p","nema-15-15p","nema-15-20p","nema-15-30p","nema-15-50p","nema-15-60p","nema-l1-15p","nema-l5-15p","nema-l5-20p","nema-l5-30p","nema-l5-50p","nema-l6-15p","nema-l6-20p","nema-l6-30p","nema-l6-50p","nema-l10-30p","nema-l14-20p","nema-l14-30p","nema-l14-50p","nema-l14-60p","nema-l15-20p","nema-l15-30p","nema-l15-50p","nema-l15-60p","nema-l21-20p","nema-l21-30p","nema-l22-30p","cs6361c","cs6365c","cs8165c","cs8265c","cs8365c","cs8465c","ita-c","ita-e","ita-f","ita-ef","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-b","usb-c","usb-mini-a","usb-mini-b","usb-micro-a","usb-micro-b","usb-micro-ab","usb-3-b","usb-3-micro-b","dc-terminal","saf-d-grid","hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -543,6 +543,9 @@ const ( // WritablePowerPortTypeNemaDashL21Dash30p captures enum value "nema-l21-30p" WritablePowerPortTypeNemaDashL21Dash30p string = "nema-l21-30p" + // WritablePowerPortTypeNemaDashL22Dash30p captures enum value "nema-l22-30p" + WritablePowerPortTypeNemaDashL22Dash30p string = "nema-l22-30p" + // WritablePowerPortTypeCs6361c captures enum value "cs6361c" WritablePowerPortTypeCs6361c string = "cs6361c" @@ -685,14 +688,6 @@ func (m *WritablePowerPort) ContextValidate(ctx context.Context, formats strfmt. res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { - res = append(res, err) - } - - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { - res = append(res, err) - } - if err := m.contextValidateConnectedEndpoint(ctx, formats); err != nil { res = append(res, err) } @@ -721,6 +716,14 @@ func (m *WritablePowerPort) ContextValidate(ctx context.Context, formats strfmt. res = append(res, err) } + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTags(ctx, formats); err != nil { res = append(res, err) } @@ -760,20 +763,6 @@ func (m *WritablePowerPort) contextValidateCable(ctx context.Context, formats st return nil } -func (m *WritablePowerPort) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *WritablePowerPort) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *WritablePowerPort) contextValidateConnectedEndpoint(ctx context.Context, formats strfmt.Registry) error { return nil @@ -833,6 +822,20 @@ func (m *WritablePowerPort) contextValidateLastUpdated(ctx context.Context, form return nil } +func (m *WritablePowerPort) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *WritablePowerPort) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *WritablePowerPort) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { diff --git a/netbox/models/writable_power_port_template.go b/netbox/models/writable_power_port_template.go index 3697c655..8c7367e7 100644 --- a/netbox/models/writable_power_port_template.go +++ b/netbox/models/writable_power_port_template.go @@ -88,7 +88,7 @@ type WritablePowerPortTemplate struct { Name *string `json:"name"` // Type - // Enum: [iec-60320-c6 iec-60320-c8 iec-60320-c14 iec-60320-c16 iec-60320-c20 iec-60320-c22 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15p nema-5-15p nema-5-20p nema-5-30p nema-5-50p nema-6-15p nema-6-20p nema-6-30p nema-6-50p nema-10-30p nema-10-50p nema-14-20p nema-14-30p nema-14-50p nema-14-60p nema-15-15p nema-15-20p nema-15-30p nema-15-50p nema-15-60p nema-l1-15p nema-l5-15p nema-l5-20p nema-l5-30p nema-l5-50p nema-l6-15p nema-l6-20p nema-l6-30p nema-l6-50p nema-l10-30p nema-l14-20p nema-l14-30p nema-l14-50p nema-l14-60p nema-l15-20p nema-l15-30p nema-l15-50p nema-l15-60p nema-l21-20p nema-l21-30p cs6361c cs6365c cs8165c cs8265c cs8365c cs8465c ita-c ita-e ita-f ita-ef ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-b usb-c usb-mini-a usb-mini-b usb-micro-a usb-micro-b usb-micro-ab usb-3-b usb-3-micro-b dc-terminal saf-d-grid hardwired] + // Enum: [iec-60320-c6 iec-60320-c8 iec-60320-c14 iec-60320-c16 iec-60320-c20 iec-60320-c22 iec-60309-p-n-e-4h iec-60309-p-n-e-6h iec-60309-p-n-e-9h iec-60309-2p-e-4h iec-60309-2p-e-6h iec-60309-2p-e-9h iec-60309-3p-e-4h iec-60309-3p-e-6h iec-60309-3p-e-9h iec-60309-3p-n-e-4h iec-60309-3p-n-e-6h iec-60309-3p-n-e-9h nema-1-15p nema-5-15p nema-5-20p nema-5-30p nema-5-50p nema-6-15p nema-6-20p nema-6-30p nema-6-50p nema-10-30p nema-10-50p nema-14-20p nema-14-30p nema-14-50p nema-14-60p nema-15-15p nema-15-20p nema-15-30p nema-15-50p nema-15-60p nema-l1-15p nema-l5-15p nema-l5-20p nema-l5-30p nema-l5-50p nema-l6-15p nema-l6-20p nema-l6-30p nema-l6-50p nema-l10-30p nema-l14-20p nema-l14-30p nema-l14-50p nema-l14-60p nema-l15-20p nema-l15-30p nema-l15-50p nema-l15-60p nema-l21-20p nema-l21-30p nema-l22-30p cs6361c cs6365c cs8165c cs8265c cs8365c cs8465c ita-c ita-e ita-f ita-ef ita-g ita-h ita-i ita-j ita-k ita-l ita-m ita-n ita-o usb-a usb-b usb-c usb-mini-a usb-mini-b usb-micro-a usb-micro-b usb-micro-ab usb-3-b usb-3-micro-b dc-terminal saf-d-grid hardwired] Type string `json:"type,omitempty"` // Url @@ -257,7 +257,7 @@ var writablePowerPortTemplateTypeTypePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["iec-60320-c6","iec-60320-c8","iec-60320-c14","iec-60320-c16","iec-60320-c20","iec-60320-c22","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15p","nema-5-15p","nema-5-20p","nema-5-30p","nema-5-50p","nema-6-15p","nema-6-20p","nema-6-30p","nema-6-50p","nema-10-30p","nema-10-50p","nema-14-20p","nema-14-30p","nema-14-50p","nema-14-60p","nema-15-15p","nema-15-20p","nema-15-30p","nema-15-50p","nema-15-60p","nema-l1-15p","nema-l5-15p","nema-l5-20p","nema-l5-30p","nema-l5-50p","nema-l6-15p","nema-l6-20p","nema-l6-30p","nema-l6-50p","nema-l10-30p","nema-l14-20p","nema-l14-30p","nema-l14-50p","nema-l14-60p","nema-l15-20p","nema-l15-30p","nema-l15-50p","nema-l15-60p","nema-l21-20p","nema-l21-30p","cs6361c","cs6365c","cs8165c","cs8265c","cs8365c","cs8465c","ita-c","ita-e","ita-f","ita-ef","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-b","usb-c","usb-mini-a","usb-mini-b","usb-micro-a","usb-micro-b","usb-micro-ab","usb-3-b","usb-3-micro-b","dc-terminal","saf-d-grid","hardwired"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["iec-60320-c6","iec-60320-c8","iec-60320-c14","iec-60320-c16","iec-60320-c20","iec-60320-c22","iec-60309-p-n-e-4h","iec-60309-p-n-e-6h","iec-60309-p-n-e-9h","iec-60309-2p-e-4h","iec-60309-2p-e-6h","iec-60309-2p-e-9h","iec-60309-3p-e-4h","iec-60309-3p-e-6h","iec-60309-3p-e-9h","iec-60309-3p-n-e-4h","iec-60309-3p-n-e-6h","iec-60309-3p-n-e-9h","nema-1-15p","nema-5-15p","nema-5-20p","nema-5-30p","nema-5-50p","nema-6-15p","nema-6-20p","nema-6-30p","nema-6-50p","nema-10-30p","nema-10-50p","nema-14-20p","nema-14-30p","nema-14-50p","nema-14-60p","nema-15-15p","nema-15-20p","nema-15-30p","nema-15-50p","nema-15-60p","nema-l1-15p","nema-l5-15p","nema-l5-20p","nema-l5-30p","nema-l5-50p","nema-l6-15p","nema-l6-20p","nema-l6-30p","nema-l6-50p","nema-l10-30p","nema-l14-20p","nema-l14-30p","nema-l14-50p","nema-l14-60p","nema-l15-20p","nema-l15-30p","nema-l15-50p","nema-l15-60p","nema-l21-20p","nema-l21-30p","nema-l22-30p","cs6361c","cs6365c","cs8165c","cs8265c","cs8365c","cs8465c","ita-c","ita-e","ita-f","ita-ef","ita-g","ita-h","ita-i","ita-j","ita-k","ita-l","ita-m","ita-n","ita-o","usb-a","usb-b","usb-c","usb-mini-a","usb-mini-b","usb-micro-a","usb-micro-b","usb-micro-ab","usb-3-b","usb-3-micro-b","dc-terminal","saf-d-grid","hardwired"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -441,6 +441,9 @@ const ( // WritablePowerPortTemplateTypeNemaDashL21Dash30p captures enum value "nema-l21-30p" WritablePowerPortTemplateTypeNemaDashL21Dash30p string = "nema-l21-30p" + // WritablePowerPortTemplateTypeNemaDashL22Dash30p captures enum value "nema-l22-30p" + WritablePowerPortTemplateTypeNemaDashL22Dash30p string = "nema-l22-30p" + // WritablePowerPortTemplateTypeCs6361c captures enum value "cs6361c" WritablePowerPortTemplateTypeCs6361c string = "cs6361c" diff --git a/netbox/models/writable_rack.go b/netbox/models/writable_rack.go index c657f3fa..abfd36b7 100644 --- a/netbox/models/writable_rack.go +++ b/netbox/models/writable_rack.go @@ -67,8 +67,6 @@ type WritableRack struct { Display string `json:"display,omitempty"` // Facility ID - // - // Locally-assigned identifier // Max Length: 50 FacilityID *string `json:"facility_id,omitempty"` @@ -82,7 +80,8 @@ type WritableRack struct { LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` // Location - Location *int64 `json:"location,omitempty"` + // Required: true + Location *int64 `json:"location"` // Name // Required: true @@ -178,6 +177,10 @@ func (m *WritableRack) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateLocation(formats); err != nil { + res = append(res, err) + } + if err := m.validateName(formats); err != nil { res = append(res, err) } @@ -280,6 +283,15 @@ func (m *WritableRack) validateLastUpdated(formats strfmt.Registry) error { return nil } +func (m *WritableRack) validateLocation(formats strfmt.Registry) error { + + if err := validate.Required("location", "body", m.Location); err != nil { + return err + } + + return nil +} + func (m *WritableRack) validateName(formats strfmt.Registry) error { if err := validate.Required("name", "body", m.Name); err != nil { diff --git a/netbox/models/writable_rack_reservation.go b/netbox/models/writable_rack_reservation.go index df311e9c..6bece7c0 100644 --- a/netbox/models/writable_rack_reservation.go +++ b/netbox/models/writable_rack_reservation.go @@ -57,6 +57,11 @@ type WritableRackReservation struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Rack // Required: true Rack *int64 `json:"rack"` @@ -93,6 +98,10 @@ func (m *WritableRackReservation) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateRack(formats); err != nil { res = append(res, err) } @@ -148,6 +157,18 @@ func (m *WritableRackReservation) validateDescription(formats strfmt.Registry) e return nil } +func (m *WritableRackReservation) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *WritableRackReservation) validateRack(formats strfmt.Registry) error { if err := validate.Required("rack", "body", m.Rack); err != nil { @@ -244,6 +265,10 @@ func (m *WritableRackReservation) ContextValidate(ctx context.Context, formats s res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTags(ctx, formats); err != nil { res = append(res, err) } @@ -285,6 +310,15 @@ func (m *WritableRackReservation) contextValidateID(ctx context.Context, formats return nil } +func (m *WritableRackReservation) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *WritableRackReservation) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { diff --git a/netbox/models/writable_rear_port.go b/netbox/models/writable_rear_port.go index 4b647b03..1ecaf5f3 100644 --- a/netbox/models/writable_rear_port.go +++ b/netbox/models/writable_rear_port.go @@ -43,18 +43,6 @@ type WritableRearPort struct { // cable Cable *NestedCable `json:"cable,omitempty"` - // Cable peer - // - // - // Return the appropriate serializer for the cable termination model. - // - // Read Only: true - CablePeer map[string]*string `json:"cable_peer,omitempty"` - - // Cable peer type - // Read Only: true - CablePeerType string `json:"cable_peer_type,omitempty"` - // Color // Max Length: 6 // Pattern: ^[0-9a-f]{6}$ @@ -95,6 +83,18 @@ type WritableRearPort struct { // Format: date-time LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Link peer + // + // + // Return the appropriate serializer for the link termination model. + // + // Read Only: true + LinkPeer map[string]*string `json:"link_peer,omitempty"` + + // Link peer type + // Read Only: true + LinkPeerType string `json:"link_peer_type,omitempty"` + // Mark connected // // Treat as if a cable is connected @@ -116,7 +116,7 @@ type WritableRearPort struct { // Type // Required: true - // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-apc lsh lsh-apc mpo mtrj sc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] + // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-pc lc-upc lc-apc lsh lsh-pc lsh-upc lsh-apc mpo mtrj sc sc-pc sc-upc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] Type *string `json:"type"` // Url @@ -338,7 +338,7 @@ var writableRearPortTypeTypePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-apc","lsh","lsh-apc","mpo","mtrj","sc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-pc","lc-upc","lc-apc","lsh","lsh-pc","lsh-upc","lsh-apc","mpo","mtrj","sc","sc-pc","sc-upc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -408,12 +408,24 @@ const ( // WritableRearPortTypeLc captures enum value "lc" WritableRearPortTypeLc string = "lc" + // WritableRearPortTypeLcDashPc captures enum value "lc-pc" + WritableRearPortTypeLcDashPc string = "lc-pc" + + // WritableRearPortTypeLcDashUpc captures enum value "lc-upc" + WritableRearPortTypeLcDashUpc string = "lc-upc" + // WritableRearPortTypeLcDashApc captures enum value "lc-apc" WritableRearPortTypeLcDashApc string = "lc-apc" // WritableRearPortTypeLsh captures enum value "lsh" WritableRearPortTypeLsh string = "lsh" + // WritableRearPortTypeLshDashPc captures enum value "lsh-pc" + WritableRearPortTypeLshDashPc string = "lsh-pc" + + // WritableRearPortTypeLshDashUpc captures enum value "lsh-upc" + WritableRearPortTypeLshDashUpc string = "lsh-upc" + // WritableRearPortTypeLshDashApc captures enum value "lsh-apc" WritableRearPortTypeLshDashApc string = "lsh-apc" @@ -426,6 +438,12 @@ const ( // WritableRearPortTypeSc captures enum value "sc" WritableRearPortTypeSc string = "sc" + // WritableRearPortTypeScDashPc captures enum value "sc-pc" + WritableRearPortTypeScDashPc string = "sc-pc" + + // WritableRearPortTypeScDashUpc captures enum value "sc-upc" + WritableRearPortTypeScDashUpc string = "sc-upc" + // WritableRearPortTypeScDashApc captures enum value "sc-apc" WritableRearPortTypeScDashApc string = "sc-apc" @@ -503,27 +521,27 @@ func (m *WritableRearPort) ContextValidate(ctx context.Context, formats strfmt.R res = append(res, err) } - if err := m.contextValidateCablePeer(ctx, formats); err != nil { + if err := m.contextValidateCreated(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCablePeerType(ctx, formats); err != nil { + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateCreated(ctx, formats); err != nil { + if err := m.contextValidateID(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateDisplay(ctx, formats); err != nil { + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateID(ctx, formats); err != nil { + if err := m.contextValidateLinkPeer(ctx, formats); err != nil { res = append(res, err) } - if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + if err := m.contextValidateLinkPeerType(ctx, formats); err != nil { res = append(res, err) } @@ -566,20 +584,6 @@ func (m *WritableRearPort) contextValidateCable(ctx context.Context, formats str return nil } -func (m *WritableRearPort) contextValidateCablePeer(ctx context.Context, formats strfmt.Registry) error { - - return nil -} - -func (m *WritableRearPort) contextValidateCablePeerType(ctx context.Context, formats strfmt.Registry) error { - - if err := validate.ReadOnly(ctx, "cable_peer_type", "body", string(m.CablePeerType)); err != nil { - return err - } - - return nil -} - func (m *WritableRearPort) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { @@ -616,6 +620,20 @@ func (m *WritableRearPort) contextValidateLastUpdated(ctx context.Context, forma return nil } +func (m *WritableRearPort) contextValidateLinkPeer(ctx context.Context, formats strfmt.Registry) error { + + return nil +} + +func (m *WritableRearPort) contextValidateLinkPeerType(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "link_peer_type", "body", string(m.LinkPeerType)); err != nil { + return err + } + + return nil +} + func (m *WritableRearPort) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { for i := 0; i < len(m.Tags); i++ { diff --git a/netbox/models/writable_rear_port_template.go b/netbox/models/writable_rear_port_template.go index 20a179e2..91fc8e78 100644 --- a/netbox/models/writable_rear_port_template.go +++ b/netbox/models/writable_rear_port_template.go @@ -85,7 +85,7 @@ type WritableRearPortTemplate struct { // Type // Required: true - // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-apc lsh lsh-apc mpo mtrj sc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] + // Enum: [8p8c 8p6c 8p4c 8p2c 6p6c 6p4c 6p2c 4p4c 4p2c gg45 tera-4p tera-2p tera-1p 110-punch bnc f n mrj21 fc lc lc-pc lc-upc lc-apc lsh lsh-pc lsh-upc lsh-apc mpo mtrj sc sc-pc sc-upc sc-apc st cs sn sma-905 sma-906 urm-p2 urm-p4 urm-p8 splice] Type *string `json:"type"` // Url @@ -254,7 +254,7 @@ var writableRearPortTemplateTypeTypePropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-apc","lsh","lsh-apc","mpo","mtrj","sc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["8p8c","8p6c","8p4c","8p2c","6p6c","6p4c","6p2c","4p4c","4p2c","gg45","tera-4p","tera-2p","tera-1p","110-punch","bnc","f","n","mrj21","fc","lc","lc-pc","lc-upc","lc-apc","lsh","lsh-pc","lsh-upc","lsh-apc","mpo","mtrj","sc","sc-pc","sc-upc","sc-apc","st","cs","sn","sma-905","sma-906","urm-p2","urm-p4","urm-p8","splice"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -324,12 +324,24 @@ const ( // WritableRearPortTemplateTypeLc captures enum value "lc" WritableRearPortTemplateTypeLc string = "lc" + // WritableRearPortTemplateTypeLcDashPc captures enum value "lc-pc" + WritableRearPortTemplateTypeLcDashPc string = "lc-pc" + + // WritableRearPortTemplateTypeLcDashUpc captures enum value "lc-upc" + WritableRearPortTemplateTypeLcDashUpc string = "lc-upc" + // WritableRearPortTemplateTypeLcDashApc captures enum value "lc-apc" WritableRearPortTemplateTypeLcDashApc string = "lc-apc" // WritableRearPortTemplateTypeLsh captures enum value "lsh" WritableRearPortTemplateTypeLsh string = "lsh" + // WritableRearPortTemplateTypeLshDashPc captures enum value "lsh-pc" + WritableRearPortTemplateTypeLshDashPc string = "lsh-pc" + + // WritableRearPortTemplateTypeLshDashUpc captures enum value "lsh-upc" + WritableRearPortTemplateTypeLshDashUpc string = "lsh-upc" + // WritableRearPortTemplateTypeLshDashApc captures enum value "lsh-apc" WritableRearPortTemplateTypeLshDashApc string = "lsh-apc" @@ -342,6 +354,12 @@ const ( // WritableRearPortTemplateTypeSc captures enum value "sc" WritableRearPortTemplateTypeSc string = "sc" + // WritableRearPortTemplateTypeScDashPc captures enum value "sc-pc" + WritableRearPortTemplateTypeScDashPc string = "sc-pc" + + // WritableRearPortTemplateTypeScDashUpc captures enum value "sc-upc" + WritableRearPortTemplateTypeScDashUpc string = "sc-upc" + // WritableRearPortTemplateTypeScDashApc captures enum value "sc-apc" WritableRearPortTemplateTypeScDashApc string = "sc-apc" diff --git a/netbox/models/writable_region.go b/netbox/models/writable_region.go index 0b764b07..66356eb9 100644 --- a/netbox/models/writable_region.go +++ b/netbox/models/writable_region.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -83,6 +84,9 @@ type WritableRegion struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -113,6 +117,10 @@ func (m *WritableRegion) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -197,6 +205,32 @@ func (m *WritableRegion) validateSlug(formats strfmt.Registry) error { return nil } +func (m *WritableRegion) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *WritableRegion) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -237,6 +271,10 @@ func (m *WritableRegion) ContextValidate(ctx context.Context, formats strfmt.Reg res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -301,6 +339,26 @@ func (m *WritableRegion) contextValidateSiteCount(ctx context.Context, formats s return nil } +func (m *WritableRegion) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *WritableRegion) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/writable_service.go b/netbox/models/writable_service.go index 199fefbd..c77dcd22 100644 --- a/netbox/models/writable_service.go +++ b/netbox/models/writable_service.go @@ -80,7 +80,7 @@ type WritableService struct { // Protocol // Required: true - // Enum: [tcp udp] + // Enum: [tcp udp sctp] Protocol *string `json:"protocol"` // tags @@ -231,7 +231,7 @@ var writableServiceTypeProtocolPropEnum []interface{} func init() { var res []string - if err := json.Unmarshal([]byte(`["tcp","udp"]`), &res); err != nil { + if err := json.Unmarshal([]byte(`["tcp","udp","sctp"]`), &res); err != nil { panic(err) } for _, v := range res { @@ -246,6 +246,9 @@ const ( // WritableServiceProtocolUDP captures enum value "udp" WritableServiceProtocolUDP string = "udp" + + // WritableServiceProtocolSctp captures enum value "sctp" + WritableServiceProtocolSctp string = "sctp" ) // prop value enum diff --git a/netbox/models/writable_site.go b/netbox/models/writable_site.go index 089bc576..fcbe6b26 100644 --- a/netbox/models/writable_site.go +++ b/netbox/models/writable_site.go @@ -43,6 +43,10 @@ type WritableSite struct { // Minimum: 1 Asn *int64 `json:"asn,omitempty"` + // asns + // Unique: true + Asns []int64 `json:"asns"` + // Circuit count // Read Only: true CircuitCount int64 `json:"circuit_count,omitempty"` @@ -178,6 +182,10 @@ func (m *WritableSite) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateAsns(formats); err != nil { + res = append(res, err) + } + if err := m.validateContactEmail(formats); err != nil { res = append(res, err) } @@ -256,6 +264,18 @@ func (m *WritableSite) validateAsn(formats strfmt.Registry) error { return nil } +func (m *WritableSite) validateAsns(formats strfmt.Registry) error { + if swag.IsZero(m.Asns) { // not required + return nil + } + + if err := validate.UniqueItems("asns", "body", m.Asns); err != nil { + return err + } + + return nil +} + func (m *WritableSite) validateContactEmail(formats strfmt.Registry) error { if swag.IsZero(m.ContactEmail) { // not required return nil diff --git a/netbox/models/writable_site_group.go b/netbox/models/writable_site_group.go index ba0c443b..80f6e9bd 100644 --- a/netbox/models/writable_site_group.go +++ b/netbox/models/writable_site_group.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -83,6 +84,9 @@ type WritableSiteGroup struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Url // Read Only: true // Format: uri @@ -113,6 +117,10 @@ func (m *WritableSiteGroup) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -197,6 +205,32 @@ func (m *WritableSiteGroup) validateSlug(formats strfmt.Registry) error { return nil } +func (m *WritableSiteGroup) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *WritableSiteGroup) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -237,6 +271,10 @@ func (m *WritableSiteGroup) ContextValidate(ctx context.Context, formats strfmt. res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateURL(ctx, formats); err != nil { res = append(res, err) } @@ -301,6 +339,26 @@ func (m *WritableSiteGroup) contextValidateSiteCount(ctx context.Context, format return nil } +func (m *WritableSiteGroup) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *WritableSiteGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { diff --git a/netbox/models/writable_tenant_group.go b/netbox/models/writable_tenant_group.go index 667fb302..ebfe9b36 100644 --- a/netbox/models/writable_tenant_group.go +++ b/netbox/models/writable_tenant_group.go @@ -22,6 +22,7 @@ package models import ( "context" + "strconv" "github.com/go-openapi/errors" "github.com/go-openapi/strfmt" @@ -79,6 +80,9 @@ type WritableTenantGroup struct { // Pattern: ^[-a-zA-Z0-9_]+$ Slug *string `json:"slug"` + // tags + Tags []*NestedTag `json:"tags"` + // Tenant count // Read Only: true TenantCount int64 `json:"tenant_count,omitempty"` @@ -113,6 +117,10 @@ func (m *WritableTenantGroup) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + if err := m.validateURL(formats); err != nil { res = append(res, err) } @@ -197,6 +205,32 @@ func (m *WritableTenantGroup) validateSlug(formats strfmt.Registry) error { return nil } +func (m *WritableTenantGroup) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *WritableTenantGroup) validateURL(formats strfmt.Registry) error { if swag.IsZero(m.URL) { // not required return nil @@ -233,6 +267,10 @@ func (m *WritableTenantGroup) ContextValidate(ctx context.Context, formats strfm res = append(res, err) } + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateTenantCount(ctx, formats); err != nil { res = append(res, err) } @@ -292,6 +330,26 @@ func (m *WritableTenantGroup) contextValidateLastUpdated(ctx context.Context, fo return nil } +func (m *WritableTenantGroup) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + func (m *WritableTenantGroup) contextValidateTenantCount(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "tenant_count", "body", int64(m.TenantCount)); err != nil { diff --git a/netbox/models/writable_v_l_a_n.go b/netbox/models/writable_v_l_a_n.go index 38f3b7d2..c5d48793 100644 --- a/netbox/models/writable_v_l_a_n.go +++ b/netbox/models/writable_v_l_a_n.go @@ -53,7 +53,8 @@ type WritableVLAN struct { Display string `json:"display,omitempty"` // Group - Group *int64 `json:"group,omitempty"` + // Required: true + Group *int64 `json:"group"` // Id // Read Only: true @@ -114,6 +115,10 @@ func (m *WritableVLAN) Validate(formats strfmt.Registry) error { res = append(res, err) } + if err := m.validateGroup(formats); err != nil { + res = append(res, err) + } + if err := m.validateLastUpdated(formats); err != nil { res = append(res, err) } @@ -168,6 +173,15 @@ func (m *WritableVLAN) validateDescription(formats strfmt.Registry) error { return nil } +func (m *WritableVLAN) validateGroup(formats strfmt.Registry) error { + + if err := validate.Required("group", "body", m.Group); err != nil { + return err + } + + return nil +} + func (m *WritableVLAN) validateLastUpdated(formats strfmt.Registry) error { if swag.IsZero(m.LastUpdated) { // not required return nil diff --git a/netbox/models/writable_virtual_chassis.go b/netbox/models/writable_virtual_chassis.go index 60d728eb..494526ac 100644 --- a/netbox/models/writable_virtual_chassis.go +++ b/netbox/models/writable_virtual_chassis.go @@ -35,6 +35,11 @@ import ( // swagger:model WritableVirtualChassis type WritableVirtualChassis struct { + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + // Custom fields CustomFields interface{} `json:"custom_fields,omitempty"` @@ -50,6 +55,11 @@ type WritableVirtualChassis struct { // Read Only: true ID int64 `json:"id,omitempty"` + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + // Master Master *int64 `json:"master,omitempty"` @@ -76,10 +86,18 @@ type WritableVirtualChassis struct { func (m *WritableVirtualChassis) Validate(formats strfmt.Registry) error { var res []error + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + if err := m.validateDomain(formats); err != nil { res = append(res, err) } + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + if err := m.validateName(formats); err != nil { res = append(res, err) } @@ -98,6 +116,18 @@ func (m *WritableVirtualChassis) Validate(formats strfmt.Registry) error { return nil } +func (m *WritableVirtualChassis) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + func (m *WritableVirtualChassis) validateDomain(formats strfmt.Registry) error { if swag.IsZero(m.Domain) { // not required return nil @@ -110,6 +140,18 @@ func (m *WritableVirtualChassis) validateDomain(formats strfmt.Registry) error { return nil } +func (m *WritableVirtualChassis) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + func (m *WritableVirtualChassis) validateName(formats strfmt.Registry) error { if err := validate.Required("name", "body", m.Name); err != nil { @@ -169,6 +211,10 @@ func (m *WritableVirtualChassis) validateURL(formats strfmt.Registry) error { func (m *WritableVirtualChassis) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateDisplay(ctx, formats); err != nil { res = append(res, err) } @@ -177,6 +223,10 @@ func (m *WritableVirtualChassis) ContextValidate(ctx context.Context, formats st res = append(res, err) } + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateMemberCount(ctx, formats); err != nil { res = append(res, err) } @@ -195,6 +245,15 @@ func (m *WritableVirtualChassis) ContextValidate(ctx context.Context, formats st return nil } +func (m *WritableVirtualChassis) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + func (m *WritableVirtualChassis) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { @@ -213,6 +272,15 @@ func (m *WritableVirtualChassis) contextValidateID(ctx context.Context, formats return nil } +func (m *WritableVirtualChassis) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + func (m *WritableVirtualChassis) contextValidateMemberCount(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "member_count", "body", int64(m.MemberCount)); err != nil { diff --git a/netbox/models/writable_vm_interface.go b/netbox/models/writable_vm_interface.go index 122ce2c8..42659128 100644 --- a/netbox/models/writable_vm_interface.go +++ b/netbox/models/writable_vm_interface.go @@ -36,6 +36,13 @@ import ( // swagger:model WritableVMInterface type WritableVMInterface struct { + // Bridge interface + Bridge *int64 `json:"bridge,omitempty"` + + // Count fhrp groups + // Read Only: true + CountFhrpGroups int64 `json:"count_fhrp_groups,omitempty"` + // Count ipaddresses // Read Only: true CountIpaddresses int64 `json:"count_ipaddresses,omitempty"` @@ -336,6 +343,10 @@ func (m *WritableVMInterface) validateVirtualMachine(formats strfmt.Registry) er func (m *WritableVMInterface) ContextValidate(ctx context.Context, formats strfmt.Registry) error { var res []error + if err := m.contextValidateCountFhrpGroups(ctx, formats); err != nil { + res = append(res, err) + } + if err := m.contextValidateCountIpaddresses(ctx, formats); err != nil { res = append(res, err) } @@ -370,6 +381,15 @@ func (m *WritableVMInterface) ContextValidate(ctx context.Context, formats strfm return nil } +func (m *WritableVMInterface) contextValidateCountFhrpGroups(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "count_fhrp_groups", "body", int64(m.CountFhrpGroups)); err != nil { + return err + } + + return nil +} + func (m *WritableVMInterface) contextValidateCountIpaddresses(ctx context.Context, formats strfmt.Registry) error { if err := validate.ReadOnly(ctx, "count_ipaddresses", "body", int64(m.CountIpaddresses)); err != nil { diff --git a/netbox/models/writable_wireless_l_a_n.go b/netbox/models/writable_wireless_l_a_n.go new file mode 100644 index 00000000..8de42415 --- /dev/null +++ b/netbox/models/writable_wireless_l_a_n.go @@ -0,0 +1,454 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "encoding/json" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WritableWirelessLAN writable wireless l a n +// +// swagger:model WritableWirelessLAN +type WritableWirelessLAN struct { + + // Auth cipher + // Enum: [auto tkip aes] + AuthCipher string `json:"auth_cipher,omitempty"` + + // Pre-shared key + // Max Length: 64 + AuthPsk string `json:"auth_psk,omitempty"` + + // Auth type + // Enum: [open wep wpa-personal wpa-enterprise] + AuthType string `json:"auth_type,omitempty"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Group + Group *int64 `json:"group,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // SSID + // Required: true + // Max Length: 32 + // Min Length: 1 + Ssid *string `json:"ssid"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` + + // VLAN + Vlan *int64 `json:"vlan,omitempty"` +} + +// Validate validates this writable wireless l a n +func (m *WritableWirelessLAN) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAuthCipher(formats); err != nil { + res = append(res, err) + } + + if err := m.validateAuthPsk(formats); err != nil { + res = append(res, err) + } + + if err := m.validateAuthType(formats); err != nil { + res = append(res, err) + } + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSsid(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var writableWirelessLANTypeAuthCipherPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["auto","tkip","aes"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + writableWirelessLANTypeAuthCipherPropEnum = append(writableWirelessLANTypeAuthCipherPropEnum, v) + } +} + +const ( + + // WritableWirelessLANAuthCipherAuto captures enum value "auto" + WritableWirelessLANAuthCipherAuto string = "auto" + + // WritableWirelessLANAuthCipherTkip captures enum value "tkip" + WritableWirelessLANAuthCipherTkip string = "tkip" + + // WritableWirelessLANAuthCipherAes captures enum value "aes" + WritableWirelessLANAuthCipherAes string = "aes" +) + +// prop value enum +func (m *WritableWirelessLAN) validateAuthCipherEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, writableWirelessLANTypeAuthCipherPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WritableWirelessLAN) validateAuthCipher(formats strfmt.Registry) error { + if swag.IsZero(m.AuthCipher) { // not required + return nil + } + + // value enum + if err := m.validateAuthCipherEnum("auth_cipher", "body", m.AuthCipher); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLAN) validateAuthPsk(formats strfmt.Registry) error { + if swag.IsZero(m.AuthPsk) { // not required + return nil + } + + if err := validate.MaxLength("auth_psk", "body", m.AuthPsk, 64); err != nil { + return err + } + + return nil +} + +var writableWirelessLANTypeAuthTypePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["open","wep","wpa-personal","wpa-enterprise"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + writableWirelessLANTypeAuthTypePropEnum = append(writableWirelessLANTypeAuthTypePropEnum, v) + } +} + +const ( + + // WritableWirelessLANAuthTypeOpen captures enum value "open" + WritableWirelessLANAuthTypeOpen string = "open" + + // WritableWirelessLANAuthTypeWep captures enum value "wep" + WritableWirelessLANAuthTypeWep string = "wep" + + // WritableWirelessLANAuthTypeWpaDashPersonal captures enum value "wpa-personal" + WritableWirelessLANAuthTypeWpaDashPersonal string = "wpa-personal" + + // WritableWirelessLANAuthTypeWpaDashEnterprise captures enum value "wpa-enterprise" + WritableWirelessLANAuthTypeWpaDashEnterprise string = "wpa-enterprise" +) + +// prop value enum +func (m *WritableWirelessLAN) validateAuthTypeEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, writableWirelessLANTypeAuthTypePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WritableWirelessLAN) validateAuthType(formats strfmt.Registry) error { + if swag.IsZero(m.AuthType) { // not required + return nil + } + + // value enum + if err := m.validateAuthTypeEnum("auth_type", "body", m.AuthType); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLAN) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLAN) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLAN) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLAN) validateSsid(formats strfmt.Registry) error { + + if err := validate.Required("ssid", "body", m.Ssid); err != nil { + return err + } + + if err := validate.MinLength("ssid", "body", *m.Ssid, 1); err != nil { + return err + } + + if err := validate.MaxLength("ssid", "body", *m.Ssid, 32); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLAN) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableWirelessLAN) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this writable wireless l a n based on the context it is used +func (m *WritableWirelessLAN) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableWirelessLAN) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLAN) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLAN) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLAN) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLAN) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableWirelessLAN) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WritableWirelessLAN) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WritableWirelessLAN) UnmarshalBinary(b []byte) error { + var res WritableWirelessLAN + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/writable_wireless_l_a_n_group.go b/netbox/models/writable_wireless_l_a_n_group.go new file mode 100644 index 00000000..f7bdc5dc --- /dev/null +++ b/netbox/models/writable_wireless_l_a_n_group.go @@ -0,0 +1,401 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WritableWirelessLANGroup writable wireless l a n group +// +// swagger:model WritableWirelessLANGroup +type WritableWirelessLANGroup struct { + + // depth + // Read Only: true + Depth int64 `json:"_depth,omitempty"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // Name + // Required: true + // Max Length: 100 + // Min Length: 1 + Name *string `json:"name"` + + // Parent + // Required: true + Parent *int64 `json:"parent"` + + // Slug + // Required: true + // Max Length: 100 + // Min Length: 1 + // Pattern: ^[-a-zA-Z0-9_]+$ + Slug *string `json:"slug"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` + + // Wirelesslan count + // Read Only: true + WirelesslanCount int64 `json:"wirelesslan_count,omitempty"` +} + +// Validate validates this writable wireless l a n group +func (m *WritableWirelessLANGroup) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateName(formats); err != nil { + res = append(res, err) + } + + if err := m.validateParent(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSlug(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableWirelessLANGroup) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) validateName(formats strfmt.Registry) error { + + if err := validate.Required("name", "body", m.Name); err != nil { + return err + } + + if err := validate.MinLength("name", "body", *m.Name, 1); err != nil { + return err + } + + if err := validate.MaxLength("name", "body", *m.Name, 100); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) validateParent(formats strfmt.Registry) error { + + if err := validate.Required("parent", "body", m.Parent); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) validateSlug(formats strfmt.Registry) error { + + if err := validate.Required("slug", "body", m.Slug); err != nil { + return err + } + + if err := validate.MinLength("slug", "body", *m.Slug, 1); err != nil { + return err + } + + if err := validate.MaxLength("slug", "body", *m.Slug, 100); err != nil { + return err + } + + if err := validate.Pattern("slug", "body", *m.Slug, `^[-a-zA-Z0-9_]+$`); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableWirelessLANGroup) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this writable wireless l a n group based on the context it is used +func (m *WritableWirelessLANGroup) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateDepth(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateWirelesslanCount(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableWirelessLANGroup) contextValidateDepth(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "_depth", "body", int64(m.Depth)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableWirelessLANGroup) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLANGroup) contextValidateWirelesslanCount(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "wirelesslan_count", "body", int64(m.WirelesslanCount)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WritableWirelessLANGroup) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WritableWirelessLANGroup) UnmarshalBinary(b []byte) error { + var res WritableWirelessLANGroup + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/models/writable_wireless_link.go b/netbox/models/writable_wireless_link.go new file mode 100644 index 00000000..01d4e835 --- /dev/null +++ b/netbox/models/writable_wireless_link.go @@ -0,0 +1,528 @@ +// Code generated by go-swagger; DO NOT EDIT. + +// Copyright (c) 2020 Samuel Mutel <12967891+smutel@users.noreply.github.com> +// +// Permission to use, copy, modify, and distribute this software for any +// purpose with or without fee is hereby granted, provided that the above +// copyright notice and this permission notice appear in all copies. +// +// THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES +// WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF +// MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR +// ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES +// WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN +// ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF +// OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. +// + +package models + +// This file was generated by the swagger tool. +// Editing this file might prove futile when you re-run the swagger generate command + +import ( + "context" + "encoding/json" + "strconv" + + "github.com/go-openapi/errors" + "github.com/go-openapi/strfmt" + "github.com/go-openapi/swag" + "github.com/go-openapi/validate" +) + +// WritableWirelessLink writable wireless link +// +// swagger:model WritableWirelessLink +type WritableWirelessLink struct { + + // Auth cipher + // Enum: [auto tkip aes] + AuthCipher string `json:"auth_cipher,omitempty"` + + // Pre-shared key + // Max Length: 64 + AuthPsk string `json:"auth_psk,omitempty"` + + // Auth type + // Enum: [open wep wpa-personal wpa-enterprise] + AuthType string `json:"auth_type,omitempty"` + + // Created + // Read Only: true + // Format: date + Created strfmt.Date `json:"created,omitempty"` + + // Custom fields + CustomFields interface{} `json:"custom_fields,omitempty"` + + // Description + // Max Length: 200 + Description string `json:"description,omitempty"` + + // Display + // Read Only: true + Display string `json:"display,omitempty"` + + // Id + // Read Only: true + ID int64 `json:"id,omitempty"` + + // Interface a + // Required: true + Interfacea *int64 `json:"interface_a"` + + // Interface b + // Required: true + Interfaceb *int64 `json:"interface_b"` + + // Last updated + // Read Only: true + // Format: date-time + LastUpdated strfmt.DateTime `json:"last_updated,omitempty"` + + // SSID + // Max Length: 32 + Ssid string `json:"ssid,omitempty"` + + // Status + // Enum: [connected planned decommissioning] + Status string `json:"status,omitempty"` + + // tags + Tags []*NestedTag `json:"tags"` + + // Url + // Read Only: true + // Format: uri + URL strfmt.URI `json:"url,omitempty"` +} + +// Validate validates this writable wireless link +func (m *WritableWirelessLink) Validate(formats strfmt.Registry) error { + var res []error + + if err := m.validateAuthCipher(formats); err != nil { + res = append(res, err) + } + + if err := m.validateAuthPsk(formats); err != nil { + res = append(res, err) + } + + if err := m.validateAuthType(formats); err != nil { + res = append(res, err) + } + + if err := m.validateCreated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateDescription(formats); err != nil { + res = append(res, err) + } + + if err := m.validateInterfacea(formats); err != nil { + res = append(res, err) + } + + if err := m.validateInterfaceb(formats); err != nil { + res = append(res, err) + } + + if err := m.validateLastUpdated(formats); err != nil { + res = append(res, err) + } + + if err := m.validateSsid(formats); err != nil { + res = append(res, err) + } + + if err := m.validateStatus(formats); err != nil { + res = append(res, err) + } + + if err := m.validateTags(formats); err != nil { + res = append(res, err) + } + + if err := m.validateURL(formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +var writableWirelessLinkTypeAuthCipherPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["auto","tkip","aes"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + writableWirelessLinkTypeAuthCipherPropEnum = append(writableWirelessLinkTypeAuthCipherPropEnum, v) + } +} + +const ( + + // WritableWirelessLinkAuthCipherAuto captures enum value "auto" + WritableWirelessLinkAuthCipherAuto string = "auto" + + // WritableWirelessLinkAuthCipherTkip captures enum value "tkip" + WritableWirelessLinkAuthCipherTkip string = "tkip" + + // WritableWirelessLinkAuthCipherAes captures enum value "aes" + WritableWirelessLinkAuthCipherAes string = "aes" +) + +// prop value enum +func (m *WritableWirelessLink) validateAuthCipherEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, writableWirelessLinkTypeAuthCipherPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WritableWirelessLink) validateAuthCipher(formats strfmt.Registry) error { + if swag.IsZero(m.AuthCipher) { // not required + return nil + } + + // value enum + if err := m.validateAuthCipherEnum("auth_cipher", "body", m.AuthCipher); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) validateAuthPsk(formats strfmt.Registry) error { + if swag.IsZero(m.AuthPsk) { // not required + return nil + } + + if err := validate.MaxLength("auth_psk", "body", m.AuthPsk, 64); err != nil { + return err + } + + return nil +} + +var writableWirelessLinkTypeAuthTypePropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["open","wep","wpa-personal","wpa-enterprise"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + writableWirelessLinkTypeAuthTypePropEnum = append(writableWirelessLinkTypeAuthTypePropEnum, v) + } +} + +const ( + + // WritableWirelessLinkAuthTypeOpen captures enum value "open" + WritableWirelessLinkAuthTypeOpen string = "open" + + // WritableWirelessLinkAuthTypeWep captures enum value "wep" + WritableWirelessLinkAuthTypeWep string = "wep" + + // WritableWirelessLinkAuthTypeWpaDashPersonal captures enum value "wpa-personal" + WritableWirelessLinkAuthTypeWpaDashPersonal string = "wpa-personal" + + // WritableWirelessLinkAuthTypeWpaDashEnterprise captures enum value "wpa-enterprise" + WritableWirelessLinkAuthTypeWpaDashEnterprise string = "wpa-enterprise" +) + +// prop value enum +func (m *WritableWirelessLink) validateAuthTypeEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, writableWirelessLinkTypeAuthTypePropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WritableWirelessLink) validateAuthType(formats strfmt.Registry) error { + if swag.IsZero(m.AuthType) { // not required + return nil + } + + // value enum + if err := m.validateAuthTypeEnum("auth_type", "body", m.AuthType); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) validateCreated(formats strfmt.Registry) error { + if swag.IsZero(m.Created) { // not required + return nil + } + + if err := validate.FormatOf("created", "body", "date", m.Created.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) validateDescription(formats strfmt.Registry) error { + if swag.IsZero(m.Description) { // not required + return nil + } + + if err := validate.MaxLength("description", "body", m.Description, 200); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) validateInterfacea(formats strfmt.Registry) error { + + if err := validate.Required("interface_a", "body", m.Interfacea); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) validateInterfaceb(formats strfmt.Registry) error { + + if err := validate.Required("interface_b", "body", m.Interfaceb); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) validateLastUpdated(formats strfmt.Registry) error { + if swag.IsZero(m.LastUpdated) { // not required + return nil + } + + if err := validate.FormatOf("last_updated", "body", "date-time", m.LastUpdated.String(), formats); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) validateSsid(formats strfmt.Registry) error { + if swag.IsZero(m.Ssid) { // not required + return nil + } + + if err := validate.MaxLength("ssid", "body", m.Ssid, 32); err != nil { + return err + } + + return nil +} + +var writableWirelessLinkTypeStatusPropEnum []interface{} + +func init() { + var res []string + if err := json.Unmarshal([]byte(`["connected","planned","decommissioning"]`), &res); err != nil { + panic(err) + } + for _, v := range res { + writableWirelessLinkTypeStatusPropEnum = append(writableWirelessLinkTypeStatusPropEnum, v) + } +} + +const ( + + // WritableWirelessLinkStatusConnected captures enum value "connected" + WritableWirelessLinkStatusConnected string = "connected" + + // WritableWirelessLinkStatusPlanned captures enum value "planned" + WritableWirelessLinkStatusPlanned string = "planned" + + // WritableWirelessLinkStatusDecommissioning captures enum value "decommissioning" + WritableWirelessLinkStatusDecommissioning string = "decommissioning" +) + +// prop value enum +func (m *WritableWirelessLink) validateStatusEnum(path, location string, value string) error { + if err := validate.EnumCase(path, location, value, writableWirelessLinkTypeStatusPropEnum, true); err != nil { + return err + } + return nil +} + +func (m *WritableWirelessLink) validateStatus(formats strfmt.Registry) error { + if swag.IsZero(m.Status) { // not required + return nil + } + + // value enum + if err := m.validateStatusEnum("status", "body", m.Status); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) validateTags(formats strfmt.Registry) error { + if swag.IsZero(m.Tags) { // not required + return nil + } + + for i := 0; i < len(m.Tags); i++ { + if swag.IsZero(m.Tags[i]) { // not required + continue + } + + if m.Tags[i] != nil { + if err := m.Tags[i].Validate(formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableWirelessLink) validateURL(formats strfmt.Registry) error { + if swag.IsZero(m.URL) { // not required + return nil + } + + if err := validate.FormatOf("url", "body", "uri", m.URL.String(), formats); err != nil { + return err + } + + return nil +} + +// ContextValidate validate this writable wireless link based on the context it is used +func (m *WritableWirelessLink) ContextValidate(ctx context.Context, formats strfmt.Registry) error { + var res []error + + if err := m.contextValidateCreated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateDisplay(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateID(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateLastUpdated(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateTags(ctx, formats); err != nil { + res = append(res, err) + } + + if err := m.contextValidateURL(ctx, formats); err != nil { + res = append(res, err) + } + + if len(res) > 0 { + return errors.CompositeValidationError(res...) + } + return nil +} + +func (m *WritableWirelessLink) contextValidateCreated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "created", "body", strfmt.Date(m.Created)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) contextValidateDisplay(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "display", "body", string(m.Display)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) contextValidateID(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "id", "body", int64(m.ID)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) contextValidateLastUpdated(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "last_updated", "body", strfmt.DateTime(m.LastUpdated)); err != nil { + return err + } + + return nil +} + +func (m *WritableWirelessLink) contextValidateTags(ctx context.Context, formats strfmt.Registry) error { + + for i := 0; i < len(m.Tags); i++ { + + if m.Tags[i] != nil { + if err := m.Tags[i].ContextValidate(ctx, formats); err != nil { + if ve, ok := err.(*errors.Validation); ok { + return ve.ValidateName("tags" + "." + strconv.Itoa(i)) + } else if ce, ok := err.(*errors.CompositeError); ok { + return ce.ValidateName("tags" + "." + strconv.Itoa(i)) + } + return err + } + } + + } + + return nil +} + +func (m *WritableWirelessLink) contextValidateURL(ctx context.Context, formats strfmt.Registry) error { + + if err := validate.ReadOnly(ctx, "url", "body", strfmt.URI(m.URL)); err != nil { + return err + } + + return nil +} + +// MarshalBinary interface implementation +func (m *WritableWirelessLink) MarshalBinary() ([]byte, error) { + if m == nil { + return nil, nil + } + return swag.WriteJSON(m) +} + +// UnmarshalBinary interface implementation +func (m *WritableWirelessLink) UnmarshalBinary(b []byte) error { + var res WritableWirelessLink + if err := swag.ReadJSON(b, &res); err != nil { + return err + } + *m = res + return nil +} diff --git a/netbox/swagger-v3.0.11.json b/netbox/swagger-v3.1.11.json similarity index 83% rename from netbox/swagger-v3.0.11.json rename to netbox/swagger-v3.1.11.json index 1d1eb450..de399c7c 100644 --- a/netbox/swagger-v3.0.11.json +++ b/netbox/swagger-v3.1.11.json @@ -90,6 +90,74 @@ ], "type" : "object" }, + "ASN" : { + "properties" : { + "asn" : { + "description" : "32-bit autonomous system number", + "maximum" : 4294967295, + "minimum" : 1, + "title" : "ASN", + "type" : "integer" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "rir" : { + "title" : "RIR", + "type" : "integer" + }, + "site_count" : { + "readOnly" : true, + "title" : "Site count", + "type" : "integer" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "tenant" : { "$ref" : "#/definitions/NestedTenant" }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ + "asn", + "rir" + ], + "type" : "object" + }, "AvailableIP" : { "properties" : { "address" : { @@ -132,6 +200,12 @@ "title" : "Color", "type" : "string" }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "custom_fields" : { "default" : { }, "title" : "Custom fields", @@ -152,6 +226,12 @@ "title" : "Label", "type" : "string" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "length" : { "format" : "decimal", "title" : "Length", @@ -220,6 +300,7 @@ "items" : { "$ref" : "#/definitions/NestedTag" }, "type" : "array" }, + "tenant" : { "$ref" : "#/definitions/NestedTenant" }, "termination_a" : { "additionalProperties" : { "type" : "string", @@ -464,22 +545,13 @@ "CircuitTermination" : { "properties" : { "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { + "circuit" : { "$ref" : "#/definitions/NestedCircuit" }, + "created" : { + "format" : "date", "readOnly" : true, - "title" : "Cable peer type", + "title" : "Created", "type" : "string" }, - "circuit" : { "$ref" : "#/definitions/NestedCircuit" }, "description" : { "maxLength" : 200, "title" : "Description", @@ -495,6 +567,27 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -606,6 +699,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -742,6 +839,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -808,6 +909,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -945,21 +1050,308 @@ "ConsolePort" : { "properties" : { "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { + "connected_endpoint" : { "additionalProperties" : { "type" : "string", "x-nullable" : true }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", + "description" : "\nReturn the appropriate serializer for the type of connected object.\n", + "readOnly" : true, + "title" : "Connected endpoint", + "type" : "object" + }, + "connected_endpoint_reachable" : { + "readOnly" : true, + "title" : "Connected endpoint reachable", + "type" : "boolean" + }, + "connected_endpoint_type" : { + "readOnly" : true, + "title" : "Connected endpoint type", + "type" : "string" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "device" : { "$ref" : "#/definitions/NestedDevice" }, + "display" : { "readOnly" : true, - "title" : "Cable peer", + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "label" : { + "description" : "Physical label", + "maxLength" : 64, + "title" : "Label", + "type" : "string" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, + "mark_connected" : { + "description" : "Treat as if a cable is connected", + "title" : "Mark connected", + "type" : "boolean" + }, + "name" : { + "maxLength" : 64, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "speed" : { + "properties" : { + "label" : { + "enum" : [ + "1200 bps", + "2400 bps", + "4800 bps", + "9600 bps", + "19.2 kbps", + "38.4 kbps", + "57.6 kbps", + "115.2 kbps" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + 1200, + 2400, + 4800, + 9600, + 19200, + 38400, + 57600, + 115200 + ], + "type" : "integer" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Speed", + "type" : "object", + "x-nullable" : true + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "type" : { + "properties" : { + "label" : { + "enum" : [ + "DE-9", + "DB-25", + "RJ-11", + "RJ-12", + "RJ-45", + "Mini-DIN 8", + "USB Type A", + "USB Type B", + "USB Type C", + "USB Mini A", + "USB Mini B", + "USB Micro A", + "USB Micro B", + "USB Micro AB", + "Other" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "de-9", + "db-25", + "rj-11", + "rj-12", + "rj-45", + "mini-din-8", + "usb-a", + "usb-b", + "usb-c", + "usb-mini-a", + "usb-mini-b", + "usb-micro-a", + "usb-micro-b", + "usb-micro-ab", + "other" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Type", "type" : "object" }, - "cable_peer_type" : { + "url" : { + "format" : "uri", "readOnly" : true, - "title" : "Cable peer type", + "title" : "Url", "type" : "string" }, + "_occupied" : { + "readOnly" : true, + "title" : "occupied", + "type" : "boolean" + } + }, + "required" : [ + "device", + "name" + ], + "type" : "object" + }, + "ConsolePortTemplate" : { + "properties" : { + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "device_type" : { "$ref" : "#/definitions/NestedDeviceType" }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "label" : { + "description" : "Physical label", + "maxLength" : 64, + "title" : "Label", + "type" : "string" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "name" : { + "maxLength" : 64, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "type" : { + "properties" : { + "label" : { + "enum" : [ + "DE-9", + "DB-25", + "RJ-11", + "RJ-12", + "RJ-45", + "Mini-DIN 8", + "USB Type A", + "USB Type B", + "USB Type C", + "USB Mini A", + "USB Mini B", + "USB Micro A", + "USB Micro B", + "USB Micro AB", + "Other" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "de-9", + "db-25", + "rj-11", + "rj-12", + "rj-45", + "mini-din-8", + "usb-a", + "usb-b", + "usb-c", + "usb-mini-a", + "usb-mini-b", + "usb-micro-a", + "usb-micro-b", + "usb-micro-ab", + "other" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Type", + "type" : "object" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ + "device_type", + "name" + ], + "type" : "object" + }, + "ConsoleServerPort" : { + "properties" : { + "cable" : { "$ref" : "#/definitions/NestedCable" }, "connected_endpoint" : { "additionalProperties" : { "type" : "string", @@ -1019,6 +1411,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -1139,7 +1546,7 @@ ], "type" : "object" }, - "ConsolePortTemplate" : { + "ConsoleServerPortTemplate" : { "properties" : { "created" : { "format" : "date", @@ -1244,42 +1651,15 @@ ], "type" : "object" }, - "ConsoleServerPort" : { + "Contact" : { "properties" : { - "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", + "address" : { + "maxLength" : 200, + "title" : "Address", "type" : "string" }, - "connected_endpoint" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the type of connected object.\n", - "readOnly" : true, - "title" : "Connected endpoint", - "type" : "object" - }, - "connected_endpoint_reachable" : { - "readOnly" : true, - "title" : "Connected endpoint reachable", - "type" : "boolean" - }, - "connected_endpoint_type" : { - "readOnly" : true, - "title" : "Connected endpoint type", + "comments" : { + "title" : "Comments", "type" : "string" }, "created" : { @@ -1293,125 +1673,120 @@ "title" : "Custom fields", "type" : "object" }, - "description" : { - "maxLength" : 200, - "title" : "Description", - "type" : "string" - }, - "device" : { "$ref" : "#/definitions/NestedDevice" }, "display" : { "readOnly" : true, "title" : "Display", "type" : "string" }, + "email" : { + "format" : "email", + "maxLength" : 254, + "title" : "Email", + "type" : "string" + }, + "group" : { "$ref" : "#/definitions/NestedContactGroup" }, "id" : { "readOnly" : true, "title" : "Id", "type" : "integer" }, - "label" : { - "description" : "Physical label", - "maxLength" : 64, - "title" : "Label", - "type" : "string" - }, "last_updated" : { "format" : "date-time", "readOnly" : true, "title" : "Last updated", "type" : "string" }, - "mark_connected" : { - "description" : "Treat as if a cable is connected", - "title" : "Mark connected", - "type" : "boolean" - }, "name" : { - "maxLength" : 64, + "maxLength" : 100, "minLength" : 1, "title" : "Name", "type" : "string" }, - "speed" : { - "properties" : { - "label" : { - "enum" : [ - "1200 bps", - "2400 bps", - "4800 bps", - "9600 bps", - "19.2 kbps", - "38.4 kbps", - "57.6 kbps", - "115.2 kbps" - ], - "type" : "string" - }, - "value" : { - "enum" : [ - 1200, - 2400, - 4800, - 9600, - 19200, - 38400, - 57600, - 115200 - ], - "type" : "integer" - } - }, - "required" : [ - "label", - "value" - ], - "title" : "Speed", - "type" : "object", - "x-nullable" : true + "phone" : { + "maxLength" : 50, + "title" : "Phone", + "type" : "string" }, "tags" : { "items" : { "$ref" : "#/definitions/NestedTag" }, "type" : "array" }, - "type" : { + "title" : { + "maxLength" : 100, + "title" : "Title", + "type" : "string" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ "name" ], + "type" : "object" + }, + "ContactAssignment" : { + "properties" : { + "contact" : { "$ref" : "#/definitions/NestedContact" }, + "content_type" : { + "title" : "Content type", + "type" : "string" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "object" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "readOnly" : true, + "title" : "Object", + "type" : "object" + }, + "object_id" : { + "maximum" : 2147483647, + "minimum" : 0, + "title" : "Object id", + "type" : "integer" + }, + "priority" : { "properties" : { "label" : { "enum" : [ - "DE-9", - "DB-25", - "RJ-11", - "RJ-12", - "RJ-45", - "Mini-DIN 8", - "USB Type A", - "USB Type B", - "USB Type C", - "USB Mini A", - "USB Mini B", - "USB Micro A", - "USB Micro B", - "USB Micro AB", - "Other" + "Primary", + "Secondary", + "Tertiary", + "Inactive" ], "type" : "string" }, "value" : { "enum" : [ - "de-9", - "db-25", - "rj-11", - "rj-12", - "rj-45", - "mini-din-8", - "usb-a", - "usb-b", - "usb-c", - "usb-mini-a", - "usb-mini-b", - "usb-micro-a", - "usb-micro-b", - "usb-micro-ab", - "other" + "primary", + "secondary", + "tertiary", + "inactive" ], "type" : "string" } @@ -1420,41 +1795,47 @@ "label", "value" ], - "title" : "Type", + "title" : "Priority", "type" : "object" }, + "role" : { "$ref" : "#/definitions/NestedContactRole" }, "url" : { "format" : "uri", "readOnly" : true, "title" : "Url", "type" : "string" - }, - "_occupied" : { - "readOnly" : true, - "title" : "occupied", - "type" : "boolean" } }, "required" : [ - "device", - "name" + "content_type", + "object_id", + "contact" ], "type" : "object" }, - "ConsoleServerPortTemplate" : { + "ContactGroup" : { "properties" : { + "contact_count" : { + "readOnly" : true, + "title" : "Contact count", + "type" : "integer" + }, "created" : { "format" : "date", "readOnly" : true, "title" : "Created", "type" : "string" }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, "description" : { "maxLength" : 200, "title" : "Description", "type" : "string" }, - "device_type" : { "$ref" : "#/definitions/NestedDeviceType" }, "display" : { "readOnly" : true, "title" : "Display", @@ -1465,12 +1846,77 @@ "title" : "Id", "type" : "integer" }, - "label" : { - "description" : "Physical label", - "maxLength" : 64, - "title" : "Label", + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "name" : { + "maxLength" : 100, + "minLength" : 1, + "title" : "Name", "type" : "string" }, + "parent" : { "$ref" : "#/definitions/NestedContactGroup" }, + "slug" : { + "format" : "slug", + "maxLength" : 100, + "minLength" : 1, + "pattern" : "^[-a-zA-Z0-9_]+$", + "title" : "Slug", + "type" : "string" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + }, + "_depth" : { + "readOnly" : true, + "title" : "depth", + "type" : "integer" + } + }, + "required" : [ + "name", + "slug" + ], + "type" : "object" + }, + "ContactRole" : { + "properties" : { + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, "last_updated" : { "format" : "date-time", "readOnly" : true, @@ -1478,60 +1924,22 @@ "type" : "string" }, "name" : { - "maxLength" : 64, + "maxLength" : 100, "minLength" : 1, "title" : "Name", "type" : "string" }, - "type" : { - "properties" : { - "label" : { - "enum" : [ - "DE-9", - "DB-25", - "RJ-11", - "RJ-12", - "RJ-45", - "Mini-DIN 8", - "USB Type A", - "USB Type B", - "USB Type C", - "USB Mini A", - "USB Mini B", - "USB Micro A", - "USB Micro B", - "USB Micro AB", - "Other" - ], - "type" : "string" - }, - "value" : { - "enum" : [ - "de-9", - "db-25", - "rj-11", - "rj-12", - "rj-45", - "mini-din-8", - "usb-a", - "usb-b", - "usb-c", - "usb-mini-a", - "usb-mini-b", - "usb-micro-a", - "usb-micro-b", - "usb-micro-ab", - "other" - ], - "type" : "string" - } - }, - "required" : [ - "label", - "value" - ], - "title" : "Type", - "type" : "object" + "slug" : { + "format" : "slug", + "maxLength" : 100, + "minLength" : 1, + "pattern" : "^[-a-zA-Z0-9_]+$", + "title" : "Slug", + "type" : "string" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" }, "url" : { "format" : "uri", @@ -1541,8 +1949,8 @@ } }, "required" : [ - "device_type", - "name" + "name", + "slug" ], "type" : "object" }, @@ -1601,6 +2009,12 @@ "type" : "array", "uniqueItems" : true }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "default" : { "description" : "Default value for the field (must be a JSON value). Encapsulate strings with double quotes (e.g. \"Foo\").", "title" : "Default", @@ -1654,10 +2068,17 @@ "title" : "Label", "type" : "string" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "name" : { "description" : "Internal field name", "maxLength" : 50, "minLength" : 1, + "pattern" : "^[a-z0-9_]+$", "title" : "Name", "type" : "string" }, @@ -1671,10 +2092,12 @@ "label" : { "enum" : [ "Text", + "Text (long)", "Integer", "Boolean (true/false)", "Date", "URL", + "JSON", "Selection", "Multiple selection" ], @@ -1683,10 +2106,12 @@ "value" : { "enum" : [ "text", + "longtext", "integer", "boolean", "date", "url", + "json", "select", "multiselect" ], @@ -1709,7 +2134,7 @@ "validation_maximum" : { "description" : "Maximum allowed value (for numeric fields)", "maximum" : 2147483647, - "minimum" : 0, + "minimum" : -2147483648, "title" : "Maximum value", "type" : "integer", "x-nullable" : true @@ -1717,7 +2142,7 @@ "validation_minimum" : { "description" : "Minimum allowed value (for numeric fields)", "maximum" : 2147483647, - "minimum" : 0, + "minimum" : -2147483648, "title" : "Minimum value", "type" : "integer", "x-nullable" : true @@ -1769,6 +2194,12 @@ "title" : "Content type", "type" : "string" }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "display" : { "readOnly" : true, "title" : "Display", @@ -1785,6 +2216,12 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "link_text" : { "description" : "Jinja2 template code for link text", "maxLength" : 500, @@ -1833,6 +2270,38 @@ }, "Device" : { "properties" : { + "airflow" : { + "properties" : { + "label" : { + "enum" : [ + "Front to rear", + "Rear to front", + "Left to right", + "Right to left", + "Side to rear", + "Passive" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "front-to-rear", + "rear-to-front", + "left-to-right", + "right-to-left", + "side-to-rear", + "passive" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Airflow", + "type" : "object" + }, "asset_tag" : { "description" : "A unique tag used to identify this device", "maxLength" : 50, @@ -1913,8 +2382,6 @@ "parent_device" : { "$ref" : "#/definitions/NestedDevice" }, "platform" : { "$ref" : "#/definitions/NestedPlatform" }, "position" : { - "description" : "The lowest-numbered unit occupied by the device", - "maximum" : 32767, "minimum" : 1, "title" : "Position (U)", "type" : "integer", @@ -1992,6 +2459,7 @@ "virtual_chassis" : { "$ref" : "#/definitions/NestedVirtualChassis" } }, "required" : [ + "name", "device_type", "device_role", "site" @@ -2190,6 +2658,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -2215,6 +2687,38 @@ }, "DeviceType" : { "properties" : { + "airflow" : { + "properties" : { + "label" : { + "enum" : [ + "Front to rear", + "Rear to front", + "Left to right", + "Right to left", + "Side to rear", + "Passive" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "front-to-rear", + "rear-to-front", + "left-to-right", + "right-to-left", + "side-to-rear", + "passive" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Airflow", + "type" : "object" + }, "comments" : { "title" : "Comments", "type" : "string" @@ -2339,6 +2843,38 @@ }, "DeviceWithConfigContext" : { "properties" : { + "airflow" : { + "properties" : { + "label" : { + "enum" : [ + "Front to rear", + "Rear to front", + "Left to right", + "Right to left", + "Side to rear", + "Passive" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "front-to-rear", + "rear-to-front", + "left-to-right", + "right-to-left", + "side-to-rear", + "passive" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Airflow", + "type" : "object" + }, "asset_tag" : { "description" : "A unique tag used to identify this device", "maxLength" : 50, @@ -2424,8 +2960,6 @@ "parent_device" : { "$ref" : "#/definitions/NestedDevice" }, "platform" : { "$ref" : "#/definitions/NestedPlatform" }, "position" : { - "description" : "The lowest-numbered unit occupied by the device", - "maximum" : 32767, "minimum" : 1, "title" : "Position (U)", "type" : "integer", @@ -2503,6 +3037,7 @@ "virtual_chassis" : { "$ref" : "#/definitions/NestedVirtualChassis" } }, "required" : [ + "name", "device_type", "device_role", "site" @@ -2520,6 +3055,12 @@ "title" : "Content type", "type" : "string" }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "description" : { "maxLength" : 200, "title" : "Description", @@ -2541,6 +3082,12 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "mime_type" : { "description" : "Defaults to text/plain", "maxLength" : 50, @@ -2573,28 +3120,19 @@ ], "type" : "object" }, - "FrontPort" : { + "FHRPGroup" : { "properties" : { - "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", + "auth_key" : { + "maxLength" : 255, + "title" : "Authentication key", "type" : "string" }, - "color" : { - "maxLength" : 6, - "pattern" : "^[0-9a-f]{6}$", - "title" : "Color", + "auth_type" : { + "enum" : [ + "plaintext", + "md5" + ], + "title" : "Authentication type", "type" : "string" }, "created" : { @@ -2613,22 +3151,26 @@ "title" : "Description", "type" : "string" }, - "device" : { "$ref" : "#/definitions/NestedDevice" }, "display" : { "readOnly" : true, "title" : "Display", "type" : "string" }, + "group_id" : { + "maximum" : 32767, + "minimum" : 0, + "title" : "Group ID", + "type" : "integer" + }, "id" : { "readOnly" : true, "title" : "Id", "type" : "integer" }, - "label" : { - "description" : "Physical label", - "maxLength" : 64, - "title" : "Label", - "type" : "string" + "ip_addresses" : { + "items" : { "$ref" : "#/definitions/NestedIPAddress" }, + "readOnly" : true, + "type" : "array" }, "last_updated" : { "format" : "date-time", @@ -2636,165 +3178,86 @@ "title" : "Last updated", "type" : "string" }, - "mark_connected" : { - "description" : "Treat as if a cable is connected", - "title" : "Mark connected", - "type" : "boolean" - }, - "name" : { - "maxLength" : 64, - "minLength" : 1, - "title" : "Name", + "protocol" : { + "enum" : [ + "vrrp2", + "vrrp3", + "carp", + "clusterxl", + "hsrp", + "glbp", + "other" + ], + "title" : "Protocol", "type" : "string" }, - "rear_port" : { "$ref" : "#/definitions/FrontPortRearPort" }, - "rear_port_position" : { - "default" : 1, - "maximum" : 1024, - "minimum" : 1, - "title" : "Rear port position", - "type" : "integer" - }, "tags" : { "items" : { "$ref" : "#/definitions/NestedTag" }, "type" : "array" }, - "type" : { - "properties" : { - "label" : { - "enum" : [ - "8P8C", - "8P6C", - "8P4C", - "8P2C", - "6P6C", - "6P4C", - "6P2C", - "4P4C", - "4P2C", - "GG45", - "TERA 4P", - "TERA 2P", - "TERA 1P", - "110 Punch", - "BNC", - "F Connector", - "N Connector", - "MRJ21", - "FC", - "LC", - "LC/APC", - "LSH", - "LSH/APC", - "MPO", - "MTRJ", - "SC", - "SC/APC", - "ST", - "CS", - "SN", - "SMA 905", - "SMA 906", - "URM-P2", - "URM-P4", - "URM-P8", - "Splice" - ], - "type" : "string" - }, - "value" : { - "enum" : [ - "8p8c", - "8p6c", - "8p4c", - "8p2c", - "6p6c", - "6p4c", - "6p2c", - "4p4c", - "4p2c", - "gg45", - "tera-4p", - "tera-2p", - "tera-1p", - "110-punch", - "bnc", - "f", - "n", - "mrj21", - "fc", - "lc", - "lc-apc", - "lsh", - "lsh-apc", - "mpo", - "mtrj", - "sc", - "sc-apc", - "st", - "cs", - "sn", - "sma-905", - "sma-906", - "urm-p2", - "urm-p4", - "urm-p8", - "splice" - ], - "type" : "string" - } - }, - "required" : [ - "label", - "value" - ], - "title" : "Type", - "type" : "object" - }, "url" : { "format" : "uri", "readOnly" : true, "title" : "Url", "type" : "string" - }, - "_occupied" : { - "readOnly" : true, - "title" : "occupied", - "type" : "boolean" } }, "required" : [ - "device", - "name", - "type", - "rear_port" + "protocol", + "group_id" ], "type" : "object" }, - "FrontPortRearPort" : { + "FHRPGroupAssignment" : { "properties" : { + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "display" : { "readOnly" : true, "title" : "Display", "type" : "string" }, + "group" : { "$ref" : "#/definitions/NestedFHRPGroup" }, "id" : { "readOnly" : true, "title" : "Id", "type" : "integer" }, - "label" : { - "description" : "Physical label", - "maxLength" : 64, - "title" : "Label", + "interface" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "readOnly" : true, + "title" : "Interface", + "type" : "object" + }, + "interface_id" : { + "maximum" : 2147483647, + "minimum" : 0, + "title" : "Interface id", + "type" : "integer" + }, + "interface_type" : { + "title" : "Interface type", "type" : "string" }, - "name" : { - "maxLength" : 64, - "minLength" : 1, - "title" : "Name", + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", "type" : "string" }, + "priority" : { + "maximum" : 255, + "minimum" : 0, + "title" : "Priority", + "type" : "integer" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -2802,11 +3265,17 @@ "type" : "string" } }, - "required" : [ "name" ], + "required" : [ + "group", + "interface_type", + "interface_id", + "priority" + ], "type" : "object" }, - "FrontPortTemplate" : { + "FrontPort" : { "properties" : { + "cable" : { "$ref" : "#/definitions/NestedCable" }, "color" : { "maxLength" : 6, "pattern" : "^[0-9a-f]{6}$", @@ -2819,12 +3288,255 @@ "title" : "Created", "type" : "string" }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, "description" : { "maxLength" : 200, "title" : "Description", "type" : "string" }, - "device_type" : { "$ref" : "#/definitions/NestedDeviceType" }, + "device" : { "$ref" : "#/definitions/NestedDevice" }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "label" : { + "description" : "Physical label", + "maxLength" : 64, + "title" : "Label", + "type" : "string" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, + "mark_connected" : { + "description" : "Treat as if a cable is connected", + "title" : "Mark connected", + "type" : "boolean" + }, + "name" : { + "maxLength" : 64, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "rear_port" : { "$ref" : "#/definitions/FrontPortRearPort" }, + "rear_port_position" : { + "default" : 1, + "maximum" : 1024, + "minimum" : 1, + "title" : "Rear port position", + "type" : "integer" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "type" : { + "properties" : { + "label" : { + "enum" : [ + "8P8C", + "8P6C", + "8P4C", + "8P2C", + "6P6C", + "6P4C", + "6P2C", + "4P4C", + "4P2C", + "GG45", + "TERA 4P", + "TERA 2P", + "TERA 1P", + "110 Punch", + "BNC", + "F Connector", + "N Connector", + "MRJ21", + "FC", + "LC", + "LC/PC", + "LC/UPC", + "LC/APC", + "LSH", + "LSH/PC", + "LSH/UPC", + "LSH/APC", + "MPO", + "MTRJ", + "SC", + "SC/PC", + "SC/UPC", + "SC/APC", + "ST", + "CS", + "SN", + "SMA 905", + "SMA 906", + "URM-P2", + "URM-P4", + "URM-P8", + "Splice" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "8p8c", + "8p6c", + "8p4c", + "8p2c", + "6p6c", + "6p4c", + "6p2c", + "4p4c", + "4p2c", + "gg45", + "tera-4p", + "tera-2p", + "tera-1p", + "110-punch", + "bnc", + "f", + "n", + "mrj21", + "fc", + "lc", + "lc-pc", + "lc-upc", + "lc-apc", + "lsh", + "lsh-pc", + "lsh-upc", + "lsh-apc", + "mpo", + "mtrj", + "sc", + "sc-pc", + "sc-upc", + "sc-apc", + "st", + "cs", + "sn", + "sma-905", + "sma-906", + "urm-p2", + "urm-p4", + "urm-p8", + "splice" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Type", + "type" : "object" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + }, + "_occupied" : { + "readOnly" : true, + "title" : "occupied", + "type" : "boolean" + } + }, + "required" : [ + "device", + "name", + "type", + "rear_port" + ], + "type" : "object" + }, + "FrontPortRearPort" : { + "properties" : { + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "label" : { + "description" : "Physical label", + "maxLength" : 64, + "title" : "Label", + "type" : "string" + }, + "name" : { + "maxLength" : 64, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ "name" ], + "type" : "object" + }, + "FrontPortTemplate" : { + "properties" : { + "color" : { + "maxLength" : 6, + "pattern" : "^[0-9a-f]{6}$", + "title" : "Color", + "type" : "string" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "device_type" : { "$ref" : "#/definitions/NestedDeviceType" }, "display" : { "readOnly" : true, "title" : "Display", @@ -2885,12 +3597,18 @@ "MRJ21", "FC", "LC", + "LC/PC", + "LC/UPC", "LC/APC", "LSH", + "LSH/PC", + "LSH/UPC", "LSH/APC", "MPO", "MTRJ", "SC", + "SC/PC", + "SC/UPC", "SC/APC", "ST", "CS", @@ -2926,12 +3644,18 @@ "mrj21", "fc", "lc", + "lc-pc", + "lc-upc", "lc-apc", "lsh", + "lsh-pc", + "lsh-upc", "lsh-apc", "mpo", "mtrj", "sc", + "sc-pc", + "sc-upc", "sc-apc", "st", "cs", @@ -3041,6 +3765,12 @@ "title" : "Image width", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "name" : { "maxLength" : 50, "title" : "Name", @@ -3078,22 +3808,8 @@ }, "Interface" : { "properties" : { + "bridge" : { "$ref" : "#/definitions/NestedInterface" }, "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "connected_endpoint" : { "additionalProperties" : { "type" : "string", @@ -3114,6 +3830,11 @@ "title" : "Connected endpoint type", "type" : "string" }, + "count_fhrp_groups" : { + "readOnly" : true, + "title" : "Count fhrp groups", + "type" : "integer" + }, "count_ipaddresses" : { "readOnly" : true, "title" : "Count ipaddresses", @@ -3163,6 +3884,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mac_address" : { "title" : "MAC Address", "type" : "string", @@ -3218,6 +3954,456 @@ "type" : "string" }, "parent" : { "$ref" : "#/definitions/NestedInterface" }, + "rf_channel" : { + "properties" : { + "label" : { + "enum" : [ + "1 (2412 MHz)", + "2 (2417 MHz)", + "3 (2422 MHz)", + "4 (2427 MHz)", + "5 (2432 MHz)", + "6 (2437 MHz)", + "7 (2442 MHz)", + "8 (2447 MHz)", + "9 (2452 MHz)", + "10 (2457 MHz)", + "11 (2462 MHz)", + "12 (2467 MHz)", + "13 (2472 MHz)", + "32 (5160/20 MHz)", + "34 (5170/40 MHz)", + "36 (5180/20 MHz)", + "38 (5190/40 MHz)", + "40 (5200/20 MHz)", + "42 (5210/80 MHz)", + "44 (5220/20 MHz)", + "46 (5230/40 MHz)", + "48 (5240/20 MHz)", + "50 (5250/160 MHz)", + "52 (5260/20 MHz)", + "54 (5270/40 MHz)", + "56 (5280/20 MHz)", + "58 (5290/80 MHz)", + "60 (5300/20 MHz)", + "62 (5310/40 MHz)", + "64 (5320/20 MHz)", + "100 (5500/20 MHz)", + "102 (5510/40 MHz)", + "104 (5520/20 MHz)", + "106 (5530/80 MHz)", + "108 (5540/20 MHz)", + "110 (5550/40 MHz)", + "112 (5560/20 MHz)", + "114 (5570/160 MHz)", + "116 (5580/20 MHz)", + "118 (5590/40 MHz)", + "120 (5600/20 MHz)", + "122 (5610/80 MHz)", + "124 (5620/20 MHz)", + "126 (5630/40 MHz)", + "128 (5640/20 MHz)", + "132 (5660/20 MHz)", + "134 (5670/40 MHz)", + "136 (5680/20 MHz)", + "138 (5690/80 MHz)", + "140 (5700/20 MHz)", + "142 (5710/40 MHz)", + "144 (5720/20 MHz)", + "149 (5745/20 MHz)", + "151 (5755/40 MHz)", + "153 (5765/20 MHz)", + "155 (5775/80 MHz)", + "157 (5785/20 MHz)", + "159 (5795/40 MHz)", + "161 (5805/20 MHz)", + "163 (5815/160 MHz)", + "165 (5825/20 MHz)", + "167 (5835/40 MHz)", + "169 (5845/20 MHz)", + "171 (5855/80 MHz)", + "173 (5865/20 MHz)", + "175 (5875/40 MHz)", + "177 (5885/20 MHz)", + "1 (5955/20 MHz)", + "3 (5965/40 MHz)", + "5 (5975/20 MHz)", + "7 (5985/80 MHz)", + "9 (5995/20 MHz)", + "11 (6005/40 MHz)", + "13 (6015/20 MHz)", + "15 (6025/160 MHz)", + "17 (6035/20 MHz)", + "19 (6045/40 MHz)", + "21 (6055/20 MHz)", + "23 (6065/80 MHz)", + "25 (6075/20 MHz)", + "27 (6085/40 MHz)", + "29 (6095/20 MHz)", + "31 (6105/320 MHz)", + "33 (6115/20 MHz)", + "35 (6125/40 MHz)", + "37 (6135/20 MHz)", + "39 (6145/80 MHz)", + "41 (6155/20 MHz)", + "43 (6165/40 MHz)", + "45 (6175/20 MHz)", + "47 (6185/160 MHz)", + "49 (6195/20 MHz)", + "51 (6205/40 MHz)", + "53 (6215/20 MHz)", + "55 (6225/80 MHz)", + "57 (6235/20 MHz)", + "59 (6245/40 MHz)", + "61 (6255/20 MHz)", + "65 (6275/20 MHz)", + "67 (6285/40 MHz)", + "69 (6295/20 MHz)", + "71 (6305/80 MHz)", + "73 (6315/20 MHz)", + "75 (6325/40 MHz)", + "77 (6335/20 MHz)", + "79 (6345/160 MHz)", + "81 (6355/20 MHz)", + "83 (6365/40 MHz)", + "85 (6375/20 MHz)", + "87 (6385/80 MHz)", + "89 (6395/20 MHz)", + "91 (6405/40 MHz)", + "93 (6415/20 MHz)", + "95 (6425/320 MHz)", + "97 (6435/20 MHz)", + "99 (6445/40 MHz)", + "101 (6455/20 MHz)", + "103 (6465/80 MHz)", + "105 (6475/20 MHz)", + "107 (6485/40 MHz)", + "109 (6495/20 MHz)", + "111 (6505/160 MHz)", + "113 (6515/20 MHz)", + "115 (6525/40 MHz)", + "117 (6535/20 MHz)", + "119 (6545/80 MHz)", + "121 (6555/20 MHz)", + "123 (6565/40 MHz)", + "125 (6575/20 MHz)", + "129 (6595/20 MHz)", + "131 (6605/40 MHz)", + "133 (6615/20 MHz)", + "135 (6625/80 MHz)", + "137 (6635/20 MHz)", + "139 (6645/40 MHz)", + "141 (6655/20 MHz)", + "143 (6665/160 MHz)", + "145 (6675/20 MHz)", + "147 (6685/40 MHz)", + "149 (6695/20 MHz)", + "151 (6705/80 MHz)", + "153 (6715/20 MHz)", + "155 (6725/40 MHz)", + "157 (6735/20 MHz)", + "159 (6745/320 MHz)", + "161 (6755/20 MHz)", + "163 (6765/40 MHz)", + "165 (6775/20 MHz)", + "167 (6785/80 MHz)", + "169 (6795/20 MHz)", + "171 (6805/40 MHz)", + "173 (6815/20 MHz)", + "175 (6825/160 MHz)", + "177 (6835/20 MHz)", + "179 (6845/40 MHz)", + "181 (6855/20 MHz)", + "183 (6865/80 MHz)", + "185 (6875/20 MHz)", + "187 (6885/40 MHz)", + "189 (6895/20 MHz)", + "193 (6915/20 MHz)", + "195 (6925/40 MHz)", + "197 (6935/20 MHz)", + "199 (6945/80 MHz)", + "201 (6955/20 MHz)", + "203 (6965/40 MHz)", + "205 (6975/20 MHz)", + "207 (6985/160 MHz)", + "209 (6995/20 MHz)", + "211 (7005/40 MHz)", + "213 (7015/20 MHz)", + "215 (7025/80 MHz)", + "217 (7035/20 MHz)", + "219 (7045/40 MHz)", + "221 (7055/20 MHz)", + "225 (7075/20 MHz)", + "227 (7085/40 MHz)", + "229 (7095/20 MHz)", + "233 (7115/20 MHz)", + "1 (58.32/2.16 GHz)", + "2 (60.48/2.16 GHz)", + "3 (62.64/2.16 GHz)", + "4 (64.80/2.16 GHz)", + "5 (66.96/2.16 GHz)", + "6 (69.12/2.16 GHz)", + "9 (59.40/4.32 GHz)", + "10 (61.56/4.32 GHz)", + "11 (63.72/4.32 GHz)", + "12 (65.88/4.32 GHz)", + "13 (68.04/4.32 GHz)", + "17 (60.48/6.48 GHz)", + "18 (62.64/6.48 GHz)", + "19 (64.80/6.48 GHz)", + "20 (66.96/6.48 GHz)", + "25 (61.56/8.64 GHz)", + "26 (63.72/8.64 GHz)", + "27 (65.88/8.64 GHz)" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "2.4g-1-2412-22", + "2.4g-2-2417-22", + "2.4g-3-2422-22", + "2.4g-4-2427-22", + "2.4g-5-2432-22", + "2.4g-6-2437-22", + "2.4g-7-2442-22", + "2.4g-8-2447-22", + "2.4g-9-2452-22", + "2.4g-10-2457-22", + "2.4g-11-2462-22", + "2.4g-12-2467-22", + "2.4g-13-2472-22", + "5g-32-5160-20", + "5g-34-5170-40", + "5g-36-5180-20", + "5g-38-5190-40", + "5g-40-5200-20", + "5g-42-5210-80", + "5g-44-5220-20", + "5g-46-5230-40", + "5g-48-5240-20", + "5g-50-5250-160", + "5g-52-5260-20", + "5g-54-5270-40", + "5g-56-5280-20", + "5g-58-5290-80", + "5g-60-5300-20", + "5g-62-5310-40", + "5g-64-5320-20", + "5g-100-5500-20", + "5g-102-5510-40", + "5g-104-5520-20", + "5g-106-5530-80", + "5g-108-5540-20", + "5g-110-5550-40", + "5g-112-5560-20", + "5g-114-5570-160", + "5g-116-5580-20", + "5g-118-5590-40", + "5g-120-5600-20", + "5g-122-5610-80", + "5g-124-5620-20", + "5g-126-5630-40", + "5g-128-5640-20", + "5g-132-5660-20", + "5g-134-5670-40", + "5g-136-5680-20", + "5g-138-5690-80", + "5g-140-5700-20", + "5g-142-5710-40", + "5g-144-5720-20", + "5g-149-5745-20", + "5g-151-5755-40", + "5g-153-5765-20", + "5g-155-5775-80", + "5g-157-5785-20", + "5g-159-5795-40", + "5g-161-5805-20", + "5g-163-5815-160", + "5g-165-5825-20", + "5g-167-5835-40", + "5g-169-5845-20", + "5g-171-5855-80", + "5g-173-5865-20", + "5g-175-5875-40", + "5g-177-5885-20", + "6g-1-5955-20", + "6g-3-5965-40", + "6g-5-5975-20", + "6g-7-5985-80", + "6g-9-5995-20", + "6g-11-6005-40", + "6g-13-6015-20", + "6g-15-6025-160", + "6g-17-6035-20", + "6g-19-6045-40", + "6g-21-6055-20", + "6g-23-6065-80", + "6g-25-6075-20", + "6g-27-6085-40", + "6g-29-6095-20", + "6g-31-6105-320", + "6g-33-6115-20", + "6g-35-6125-40", + "6g-37-6135-20", + "6g-39-6145-80", + "6g-41-6155-20", + "6g-43-6165-40", + "6g-45-6175-20", + "6g-47-6185-160", + "6g-49-6195-20", + "6g-51-6205-40", + "6g-53-6215-20", + "6g-55-6225-80", + "6g-57-6235-20", + "6g-59-6245-40", + "6g-61-6255-20", + "6g-65-6275-20", + "6g-67-6285-40", + "6g-69-6295-20", + "6g-71-6305-80", + "6g-73-6315-20", + "6g-75-6325-40", + "6g-77-6335-20", + "6g-79-6345-160", + "6g-81-6355-20", + "6g-83-6365-40", + "6g-85-6375-20", + "6g-87-6385-80", + "6g-89-6395-20", + "6g-91-6405-40", + "6g-93-6415-20", + "6g-95-6425-320", + "6g-97-6435-20", + "6g-99-6445-40", + "6g-101-6455-20", + "6g-103-6465-80", + "6g-105-6475-20", + "6g-107-6485-40", + "6g-109-6495-20", + "6g-111-6505-160", + "6g-113-6515-20", + "6g-115-6525-40", + "6g-117-6535-20", + "6g-119-6545-80", + "6g-121-6555-20", + "6g-123-6565-40", + "6g-125-6575-20", + "6g-129-6595-20", + "6g-131-6605-40", + "6g-133-6615-20", + "6g-135-6625-80", + "6g-137-6635-20", + "6g-139-6645-40", + "6g-141-6655-20", + "6g-143-6665-160", + "6g-145-6675-20", + "6g-147-6685-40", + "6g-149-6695-20", + "6g-151-6705-80", + "6g-153-6715-20", + "6g-155-6725-40", + "6g-157-6735-20", + "6g-159-6745-320", + "6g-161-6755-20", + "6g-163-6765-40", + "6g-165-6775-20", + "6g-167-6785-80", + "6g-169-6795-20", + "6g-171-6805-40", + "6g-173-6815-20", + "6g-175-6825-160", + "6g-177-6835-20", + "6g-179-6845-40", + "6g-181-6855-20", + "6g-183-6865-80", + "6g-185-6875-20", + "6g-187-6885-40", + "6g-189-6895-20", + "6g-193-6915-20", + "6g-195-6925-40", + "6g-197-6935-20", + "6g-199-6945-80", + "6g-201-6955-20", + "6g-203-6965-40", + "6g-205-6975-20", + "6g-207-6985-160", + "6g-209-6995-20", + "6g-211-7005-40", + "6g-213-7015-20", + "6g-215-7025-80", + "6g-217-7035-20", + "6g-219-7045-40", + "6g-221-7055-20", + "6g-225-7075-20", + "6g-227-7085-40", + "6g-229-7095-20", + "6g-233-7115-20", + "60g-1-58320-2160", + "60g-2-60480-2160", + "60g-3-62640-2160", + "60g-4-64800-2160", + "60g-5-66960-2160", + "60g-6-69120-2160", + "60g-9-59400-4320", + "60g-10-61560-4320", + "60g-11-63720-4320", + "60g-12-65880-4320", + "60g-13-68040-4320", + "60g-17-60480-6480", + "60g-18-62640-6480", + "60g-19-64800-6480", + "60g-20-66960-6480", + "60g-25-61560-6480", + "60g-26-63720-6480", + "60g-27-65880-6480" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Rf channel", + "type" : "object" + }, + "rf_channel_frequency" : { + "format" : "decimal", + "title" : "Channel frequency (MHz)", + "type" : "number", + "x-nullable" : true + }, + "rf_channel_width" : { + "format" : "decimal", + "title" : "Channel width (MHz)", + "type" : "number", + "x-nullable" : true + }, + "rf_role" : { + "properties" : { + "label" : { + "enum" : [ + "Access point", + "Station" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "ap", + "station" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Rf role", + "type" : "object" + }, "tagged_vlans" : { "items" : { "$ref" : "#/definitions/NestedVLAN" }, "type" : "array", @@ -3227,11 +4413,19 @@ "items" : { "$ref" : "#/definitions/NestedTag" }, "type" : "array" }, + "tx_power" : { + "maximum" : 127, + "minimum" : 0, + "title" : "Transmit power (dBm)", + "type" : "integer", + "x-nullable" : true + }, "type" : { "properties" : { "label" : { "enum" : [ "Virtual", + "Bridge", "Link Aggregation Group (LAG)", "100BASE-TX (10/100ME)", "1000BASE-T (1GE)", @@ -3301,6 +4495,10 @@ "Cisco StackWise Plus", "Cisco FlexStack", "Cisco FlexStack Plus", + "Cisco StackWise-80", + "Cisco StackWise-160", + "Cisco StackWise-320", + "Cisco StackWise-480", "Juniper VCP", "Extreme SummitStack", "Extreme SummitStack-128", @@ -3313,6 +4511,7 @@ "value" : { "enum" : [ "virtual", + "bridge", "lag", "100base-tx", "1000base-t", @@ -3363,7 +4562,7 @@ "16gfc-sfpp", "32gfc-sfp28", "64gfc-qsfpp", - "128gfc-sfp28", + "128gfc-qsfp28", "infiniband-sdr", "infiniband-ddr", "infiniband-qdr", @@ -3382,6 +4581,10 @@ "cisco-stackwise-plus", "cisco-flexstack", "cisco-flexstack-plus", + "cisco-stackwise-80", + "cisco-stackwise-160", + "cisco-stackwise-320", + "cisco-stackwise-480", "juniper-vcp", "extreme-summitstack", "extreme-summitstack-128", @@ -3406,6 +4609,18 @@ "title" : "Url", "type" : "string" }, + "wireless_lans" : { + "items" : { "$ref" : "#/definitions/NestedWirelessLAN" }, + "type" : "array", + "uniqueItems" : true + }, + "wireless_link" : { "$ref" : "#/definitions/NestedWirelessLink" }, + "wwn" : { + "description" : "64-bit World Wide Name", + "title" : "WWN", + "type" : "string", + "x-nullable" : true + }, "_occupied" : { "readOnly" : true, "title" : "occupied", @@ -3470,6 +4685,7 @@ "label" : { "enum" : [ "Virtual", + "Bridge", "Link Aggregation Group (LAG)", "100BASE-TX (10/100ME)", "1000BASE-T (1GE)", @@ -3539,6 +4755,10 @@ "Cisco StackWise Plus", "Cisco FlexStack", "Cisco FlexStack Plus", + "Cisco StackWise-80", + "Cisco StackWise-160", + "Cisco StackWise-320", + "Cisco StackWise-480", "Juniper VCP", "Extreme SummitStack", "Extreme SummitStack-128", @@ -3551,6 +4771,7 @@ "value" : { "enum" : [ "virtual", + "bridge", "lag", "100base-tx", "1000base-t", @@ -3601,7 +4822,7 @@ "16gfc-sfpp", "32gfc-sfp28", "64gfc-qsfpp", - "128gfc-sfp28", + "128gfc-qsfp28", "infiniband-sdr", "infiniband-ddr", "infiniband-qdr", @@ -3620,6 +4841,10 @@ "cisco-stackwise-plus", "cisco-flexstack", "cisco-flexstack-plus", + "cisco-stackwise-80", + "cisco-stackwise-160", + "cisco-stackwise-320", + "cisco-stackwise-480", "juniper-vcp", "extreme-summitstack", "extreme-summitstack-128", @@ -3797,7 +5022,7 @@ "dns_name" : { "description" : "Hostname or FQDN (not case-sensitive)", "maxLength" : 255, - "pattern" : "^[0-9A-Za-z._-]+$", + "pattern" : "^([0-9A-Za-z_-]+|\\*)(\\.[0-9A-Za-z_-]+)*\\.?$", "title" : "DNS Name", "type" : "string" }, @@ -4285,6 +5510,11 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "tenant" : { "$ref" : "#/definitions/NestedTenant" }, "url" : { "format" : "uri", "readOnly" : true, @@ -4367,6 +5597,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -4380,6 +5614,35 @@ ], "type" : "object" }, + "NestedASN" : { + "properties" : { + "asn" : { + "description" : "32-bit autonomous system number", + "maximum" : 4294967295, + "minimum" : 1, + "title" : "ASN", + "type" : "integer" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ "asn" ], + "type" : "object" + }, "NestedCable" : { "properties" : { "display" : { @@ -4600,6 +5863,124 @@ ], "type" : "object" }, + "NestedContact" : { + "properties" : { + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "name" : { + "maxLength" : 100, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ "name" ], + "type" : "object" + }, + "NestedContactGroup" : { + "properties" : { + "contact_count" : { + "readOnly" : true, + "title" : "Contact count", + "type" : "integer" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "name" : { + "maxLength" : 100, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "slug" : { + "format" : "slug", + "maxLength" : 100, + "minLength" : 1, + "pattern" : "^[-a-zA-Z0-9_]+$", + "title" : "Slug", + "type" : "string" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + }, + "_depth" : { + "readOnly" : true, + "title" : "depth", + "type" : "integer" + } + }, + "required" : [ + "name", + "slug" + ], + "type" : "object", + "x-nullable" : true + }, + "NestedContactRole" : { + "properties" : { + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "name" : { + "maxLength" : 100, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "slug" : { + "format" : "slug", + "maxLength" : 100, + "minLength" : 1, + "pattern" : "^[-a-zA-Z0-9_]+$", + "title" : "Slug", + "type" : "string" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ + "name", + "slug" + ], + "type" : "object", + "x-nullable" : true + }, "NestedDevice" : { "properties" : { "display" : { @@ -4721,6 +6102,50 @@ ], "type" : "object" }, + "NestedFHRPGroup" : { + "properties" : { + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "group_id" : { + "maximum" : 32767, + "minimum" : 0, + "title" : "Group ID", + "type" : "integer" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "protocol" : { + "enum" : [ + "vrrp2", + "vrrp3", + "carp", + "clusterxl", + "hsrp", + "glbp", + "other" + ], + "title" : "Protocol", + "type" : "string" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ + "protocol", + "group_id" + ], + "type" : "object" + }, "NestedGroup" : { "properties" : { "display" : { @@ -5896,6 +7321,110 @@ "type" : "object", "x-nullable" : true }, + "NestedWirelessLAN" : { + "properties" : { + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "ssid" : { + "maxLength" : 32, + "minLength" : 1, + "title" : "SSID", + "type" : "string" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ "ssid" ], + "type" : "object" + }, + "NestedWirelessLANGroup" : { + "properties" : { + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "name" : { + "maxLength" : 100, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "slug" : { + "format" : "slug", + "maxLength" : 100, + "minLength" : 1, + "pattern" : "^[-a-zA-Z0-9_]+$", + "title" : "Slug", + "type" : "string" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + }, + "wirelesslan_count" : { + "readOnly" : true, + "title" : "Wirelesslan count", + "type" : "integer" + }, + "_depth" : { + "readOnly" : true, + "title" : "depth", + "type" : "integer" + } + }, + "required" : [ + "name", + "slug" + ], + "type" : "object", + "x-nullable" : true + }, + "NestedWirelessLink" : { + "properties" : { + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "ssid" : { + "maxLength" : 32, + "title" : "SSID", + "type" : "string" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "type" : "object" + }, "ObjectChange" : { "properties" : { "action" : { @@ -6133,6 +7662,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -6160,21 +7693,6 @@ "type" : "integer" }, "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "comments" : { "title" : "Comments", "type" : "string" @@ -6226,6 +7744,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -6393,21 +7926,6 @@ "PowerOutlet" : { "properties" : { "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "connected_endpoint" : { "additionalProperties" : { "type" : "string", @@ -6493,6 +8011,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -6571,6 +8104,7 @@ "NEMA L15-60R", "NEMA L21-20R", "NEMA L21-30R", + "NEMA L22-30R", "CS6360C", "CS6364C", "CS8164C", @@ -6588,6 +8122,7 @@ "ITA Type M (BS 546)", "ITA Type N", "ITA Type O", + "ITA Multistandard", "USB Type A", "USB Micro B", "USB Type C", @@ -6658,6 +8193,7 @@ "nema-l15-60r", "nema-l21-20r", "nema-l21-30r", + "nema-l22-30r", "CS6360C", "CS6364C", "CS8164C", @@ -6675,6 +8211,7 @@ "ita-m", "ita-n", "ita-o", + "ita-multistandard", "usb-a", "usb-micro-b", "usb-c", @@ -6842,6 +8379,7 @@ "NEMA L15-60R", "NEMA L21-20R", "NEMA L21-30R", + "NEMA L22-30R", "CS6360C", "CS6364C", "CS8164C", @@ -6859,6 +8397,7 @@ "ITA Type M (BS 546)", "ITA Type N", "ITA Type O", + "ITA Multistandard", "USB Type A", "USB Micro B", "USB Type C", @@ -6929,6 +8468,7 @@ "nema-l15-60r", "nema-l21-20r", "nema-l21-30r", + "nema-l22-30r", "CS6360C", "CS6364C", "CS8164C", @@ -6946,6 +8486,7 @@ "ita-m", "ita-n", "ita-o", + "ita-multistandard", "usb-a", "usb-micro-b", "usb-c", @@ -6979,6 +8520,12 @@ }, "PowerPanel" : { "properties" : { + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "custom_fields" : { "default" : { }, "title" : "Custom fields", @@ -6994,6 +8541,12 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "location" : { "$ref" : "#/definitions/NestedLocation" }, "name" : { "maxLength" : 100, @@ -7035,21 +8588,6 @@ "x-nullable" : true }, "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "connected_endpoint" : { "additionalProperties" : { "type" : "string", @@ -7109,6 +8647,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -7194,6 +8747,7 @@ "NEMA L15-60P", "NEMA L21-20P", "NEMA L21-30P", + "NEMA L22-30P", "CS6361C", "CS6365C", "CS8165C", @@ -7289,6 +8843,7 @@ "nema-l15-60p", "nema-l21-20p", "nema-l21-30p", + "nema-l22-30p", "cs6361c", "cs6365c", "cs8165c", @@ -7470,6 +9025,7 @@ "NEMA L15-60P", "NEMA L21-20P", "NEMA L21-30P", + "NEMA L22-30P", "CS6361C", "CS6365C", "CS8165C", @@ -7565,6 +9121,7 @@ "nema-l15-60p", "nema-l21-20p", "nema-l21-30p", + "nema-l22-30p", "cs6361c", "cs6365c", "cs8165c", @@ -7958,7 +9515,6 @@ "type" : "string" }, "facility_id" : { - "description" : "Locally-assigned identifier", "maxLength" : 50, "title" : "Facility ID", "type" : "string", @@ -8176,6 +9732,12 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "rack" : { "$ref" : "#/definitions/NestedRack" }, "tags" : { "items" : { "$ref" : "#/definitions/NestedTag" }, @@ -8267,6 +9829,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -8335,21 +9901,6 @@ "RearPort" : { "properties" : { "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "color" : { "maxLength" : 6, "pattern" : "^[0-9a-f]{6}$", @@ -8395,6 +9946,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -8440,12 +10006,18 @@ "MRJ21", "FC", "LC", + "LC/PC", + "LC/UPC", "LC/APC", "LSH", + "LSH/PC", + "LSH/UPC", "LSH/APC", "MPO", "MTRJ", "SC", + "SC/PC", + "SC/UPC", "SC/APC", "ST", "CS", @@ -8481,12 +10053,18 @@ "mrj21", "fc", "lc", + "lc-pc", + "lc-upc", "lc-apc", "lsh", + "lsh-pc", + "lsh-upc", "lsh-apc", "mpo", "mtrj", "sc", + "sc-pc", + "sc-upc", "sc-apc", "st", "cs", @@ -8605,12 +10183,18 @@ "MRJ21", "FC", "LC", + "LC/PC", + "LC/UPC", "LC/APC", "LSH", + "LSH/PC", + "LSH/UPC", "LSH/APC", "MPO", "MTRJ", "SC", + "SC/PC", + "SC/UPC", "SC/APC", "ST", "CS", @@ -8646,12 +10230,18 @@ "mrj21", "fc", "lc", + "lc-pc", + "lc-upc", "lc-apc", "lsh", + "lsh-pc", + "lsh-upc", "lsh-apc", "mpo", "mtrj", "sc", + "sc-pc", + "sc-upc", "sc-apc", "st", "cs", @@ -8741,6 +10331,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -8817,6 +10411,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -8883,6 +10481,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -9023,14 +10625,16 @@ "label" : { "enum" : [ "TCP", - "UDP" + "UDP", + "SCTP" ], "type" : "string" }, "value" : { "enum" : [ "tcp", - "udp" + "udp", + "sctp" ], "type" : "string" } @@ -9070,6 +10674,11 @@ "type" : "integer", "x-nullable" : true }, + "asns" : { + "items" : { "$ref" : "#/definitions/NestedASN" }, + "type" : "array", + "uniqueItems" : true + }, "circuit_count" : { "readOnly" : true, "title" : "Circuit count", @@ -9304,6 +10913,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -9331,6 +10944,12 @@ "title" : "Color", "type" : "string" }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "description" : { "maxLength" : 200, "title" : "Description", @@ -9346,6 +10965,12 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "name" : { "maxLength" : 100, "minLength" : 1, @@ -9547,6 +11172,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "tenant_count" : { "readOnly" : true, "title" : "Tenant count", @@ -9698,6 +11327,12 @@ }, "VirtualChassis" : { "properties" : { + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "custom_fields" : { "default" : { }, "title" : "Custom fields", @@ -9718,6 +11353,12 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "master" : { "$ref" : "#/definitions/NestedDevice" }, "member_count" : { "readOnly" : true, @@ -10015,7 +11656,6 @@ "type" : "string" }, "scope_id" : { - "minimum" : 0, "title" : "Scope id", "type" : "integer", "x-nullable" : true @@ -10032,6 +11672,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -10052,118 +11696,124 @@ }, "VMInterface" : { "properties" : { - "count_ipaddresses" : { + "bridge" : { "$ref" : "#/definitions/NestedVMInterface" }, + "count_fhrp_groups" : { "readOnly" : true, - "title" : "Count ipaddresses", + "title" : "Count fhrp groups", "type" : "integer" }, - "created" : { - "format" : "date", - "readOnly" : true, - "title" : "Created", - "type" : "string" - }, - "custom_fields" : { - "default" : { }, - "title" : "Custom fields", - "type" : "object" - }, - "description" : { - "maxLength" : 200, - "title" : "Description", - "type" : "string" - }, - "display" : { - "readOnly" : true, - "title" : "Display", - "type" : "string" - }, - "enabled" : { - "title" : "Enabled", - "type" : "boolean" - }, - "id" : { + "count_ipaddresses" : { "readOnly" : true, - "title" : "Id", + "title" : "Count ipaddresses", "type" : "integer" }, - "last_updated" : { - "format" : "date-time", - "readOnly" : true, - "title" : "Last updated", - "type" : "string" - }, - "mac_address" : { - "title" : "MAC Address", - "type" : "string", - "x-nullable" : true - }, - "mode" : { - "properties" : { - "label" : { - "enum" : [ - "Access", - "Tagged", - "Tagged (All)" - ], - "type" : "string" - }, - "value" : { - "enum" : [ - "access", - "tagged", - "tagged-all" - ], - "type" : "string" - } - }, - "required" : [ - "label", - "value" - ], - "title" : "Mode", - "type" : "object" - }, - "mtu" : { - "maximum" : 65536, - "minimum" : 1, - "title" : "MTU", - "type" : "integer", - "x-nullable" : true - }, - "name" : { - "maxLength" : 64, - "minLength" : 1, - "title" : "Name", - "type" : "string" - }, - "parent" : { "$ref" : "#/definitions/NestedVMInterface" }, - "tagged_vlans" : { - "items" : { "$ref" : "#/definitions/NestedVLAN" }, - "type" : "array", - "uniqueItems" : true - }, - "tags" : { - "items" : { "$ref" : "#/definitions/NestedTag" }, - "type" : "array" - }, - "untagged_vlan" : { "$ref" : "#/definitions/NestedVLAN" }, - "url" : { - "format" : "uri", - "readOnly" : true, - "title" : "Url", - "type" : "string" - }, - "virtual_machine" : { "$ref" : "#/definitions/NestedVirtualMachine" } - }, - "required" : [ - "virtual_machine", - "name" - ], - "type" : "object" - }, - "VRF" : { - "properties" : { + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "enabled" : { + "title" : "Enabled", + "type" : "boolean" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "mac_address" : { + "title" : "MAC Address", + "type" : "string", + "x-nullable" : true + }, + "mode" : { + "properties" : { + "label" : { + "enum" : [ + "Access", + "Tagged", + "Tagged (All)" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "access", + "tagged", + "tagged-all" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Mode", + "type" : "object" + }, + "mtu" : { + "maximum" : 65536, + "minimum" : 1, + "title" : "MTU", + "type" : "integer", + "x-nullable" : true + }, + "name" : { + "maxLength" : 64, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "parent" : { "$ref" : "#/definitions/NestedVMInterface" }, + "tagged_vlans" : { + "items" : { "$ref" : "#/definitions/NestedVLAN" }, + "type" : "array", + "uniqueItems" : true + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "untagged_vlan" : { "$ref" : "#/definitions/NestedVLAN" }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + }, + "virtual_machine" : { "$ref" : "#/definitions/NestedVirtualMachine" } + }, + "required" : [ + "virtual_machine", + "name" + ], + "type" : "object" + }, + "VRF" : { + "properties" : { "created" : { "format" : "date", "readOnly" : true, @@ -10268,11 +11918,23 @@ "type" : "string", "x-nullable" : true }, + "conditions" : { + "description" : "A set of conditions which determine whether the webhook will be generated.", + "title" : "Conditions", + "type" : "string", + "x-nullable" : true + }, "content_types" : { "items" : { "type" : "string" }, "type" : "array", "uniqueItems" : true }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "display" : { "readOnly" : true, "title" : "Display", @@ -10305,6 +11967,12 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "name" : { "maxLength" : 150, "minLength" : 1, @@ -10361,6 +12029,340 @@ ], "type" : "object" }, + "WirelessLAN" : { + "properties" : { + "auth_cipher" : { + "properties" : { + "label" : { + "enum" : [ + "Auto", + "TKIP", + "AES" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "auto", + "tkip", + "aes" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Auth cipher", + "type" : "object" + }, + "auth_psk" : { + "maxLength" : 64, + "title" : "Pre-shared key", + "type" : "string" + }, + "auth_type" : { + "properties" : { + "label" : { + "enum" : [ + "Open", + "WEP", + "WPA Personal (PSK)", + "WPA Enterprise" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "open", + "wep", + "wpa-personal", + "wpa-enterprise" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Auth type", + "type" : "object" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "group" : { "$ref" : "#/definitions/NestedWirelessLANGroup" }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "ssid" : { + "maxLength" : 32, + "minLength" : 1, + "title" : "SSID", + "type" : "string" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + }, + "vlan" : { "$ref" : "#/definitions/NestedVLAN" } + }, + "required" : [ "ssid" ], + "type" : "object" + }, + "WirelessLANGroup" : { + "properties" : { + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "name" : { + "maxLength" : 100, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "parent" : { "$ref" : "#/definitions/NestedWirelessLANGroup" }, + "slug" : { + "format" : "slug", + "maxLength" : 100, + "minLength" : 1, + "pattern" : "^[-a-zA-Z0-9_]+$", + "title" : "Slug", + "type" : "string" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + }, + "wirelesslan_count" : { + "readOnly" : true, + "title" : "Wirelesslan count", + "type" : "integer" + }, + "_depth" : { + "readOnly" : true, + "title" : "depth", + "type" : "integer" + } + }, + "required" : [ + "name", + "slug" + ], + "type" : "object" + }, + "WirelessLink" : { + "properties" : { + "auth_cipher" : { + "properties" : { + "label" : { + "enum" : [ + "Auto", + "TKIP", + "AES" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "auto", + "tkip", + "aes" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Auth cipher", + "type" : "object" + }, + "auth_psk" : { + "maxLength" : 64, + "title" : "Pre-shared key", + "type" : "string" + }, + "auth_type" : { + "properties" : { + "label" : { + "enum" : [ + "Open", + "WEP", + "WPA Personal (PSK)", + "WPA Enterprise" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "open", + "wep", + "wpa-personal", + "wpa-enterprise" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Auth type", + "type" : "object" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "interface_a" : { "$ref" : "#/definitions/NestedInterface" }, + "interface_b" : { "$ref" : "#/definitions/NestedInterface" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "ssid" : { + "maxLength" : 32, + "title" : "SSID", + "type" : "string" + }, + "status" : { + "properties" : { + "label" : { + "enum" : [ + "Connected", + "Planned", + "Decommissioning" + ], + "type" : "string" + }, + "value" : { + "enum" : [ + "connected", + "planned", + "decommissioning" + ], + "type" : "string" + } + }, + "required" : [ + "label", + "value" + ], + "title" : "Status", + "type" : "object" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ + "interface_a", + "interface_b" + ], + "type" : "object" + }, "WritableAggregate" : { "properties" : { "created" : { @@ -10436,6 +12438,94 @@ ], "type" : "object" }, + "WritableASN" : { + "properties" : { + "asn" : { + "description" : "32-bit autonomous system number", + "maximum" : 4294967295, + "minimum" : 1, + "title" : "ASN", + "type" : "integer" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "rir" : { + "title" : "RIR", + "type" : "integer" + }, + "site_count" : { + "readOnly" : true, + "title" : "Site count", + "type" : "integer" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "tenant" : { + "title" : "Tenant", + "type" : "integer", + "x-nullable" : true + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ + "asn", + "rir" + ], + "type" : "object" + }, + "WritableAvailableIP" : { + "properties" : { + "address" : { + "minLength" : 1, + "readOnly" : true, + "title" : "Address", + "type" : "string" + }, + "family" : { + "readOnly" : true, + "title" : "Family", + "type" : "integer" + } + }, + "type" : "object" + }, "WritableCable" : { "properties" : { "color" : { @@ -10444,6 +12534,12 @@ "title" : "Color", "type" : "string" }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "custom_fields" : { "default" : { }, "title" : "Custom fields", @@ -10464,6 +12560,12 @@ "title" : "Label", "type" : "string" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "length" : { "format" : "decimal", "title" : "Length", @@ -10495,6 +12597,11 @@ "items" : { "$ref" : "#/definitions/NestedTag" }, "type" : "array" }, + "tenant" : { + "title" : "Tenant", + "type" : "integer", + "x-nullable" : true + }, "termination_a" : { "additionalProperties" : { "type" : "string", @@ -10690,28 +12797,19 @@ "WritableCircuitTermination" : { "properties" : { "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "circuit" : { "title" : "Circuit", "type" : "integer" }, - "description" : { - "maxLength" : 200, - "title" : "Description", + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", "type" : "string" }, "display" : { @@ -10724,6 +12822,27 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -10871,7 +12990,9 @@ }, "required" : [ "name", - "type" + "type", + "group", + "site" ], "type" : "object" }, @@ -10999,21 +13120,6 @@ "WritableConsolePort" : { "properties" : { "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "connected_endpoint" : { "additionalProperties" : { "type" : "string", @@ -11076,6 +13182,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -11229,21 +13350,6 @@ "WritableConsoleServerPort" : { "properties" : { "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "connected_endpoint" : { "additionalProperties" : { "type" : "string", @@ -11306,6 +13412,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -11456,6 +13577,246 @@ ], "type" : "object" }, + "WritableContact" : { + "properties" : { + "address" : { + "maxLength" : 200, + "title" : "Address", + "type" : "string" + }, + "comments" : { + "title" : "Comments", + "type" : "string" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "email" : { + "format" : "email", + "maxLength" : 254, + "title" : "Email", + "type" : "string" + }, + "group" : { + "title" : "Group", + "type" : "integer", + "x-nullable" : true + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "name" : { + "maxLength" : 100, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "phone" : { + "maxLength" : 50, + "title" : "Phone", + "type" : "string" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "title" : { + "maxLength" : 100, + "title" : "Title", + "type" : "string" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ + "group", + "name" + ], + "type" : "object" + }, + "WritableContactAssignment" : { + "properties" : { + "contact" : { + "title" : "Contact", + "type" : "integer" + }, + "content_type" : { + "title" : "Content type", + "type" : "string" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "object" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "readOnly" : true, + "title" : "Object", + "type" : "object" + }, + "object_id" : { + "maximum" : 2147483647, + "minimum" : 0, + "title" : "Object id", + "type" : "integer" + }, + "priority" : { + "enum" : [ + "primary", + "secondary", + "tertiary", + "inactive" + ], + "title" : "Priority", + "type" : "string" + }, + "role" : { + "title" : "Role", + "type" : "integer" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ + "content_type", + "object_id", + "contact", + "role", + "priority" + ], + "type" : "object" + }, + "WritableContactGroup" : { + "properties" : { + "contact_count" : { + "readOnly" : true, + "title" : "Contact count", + "type" : "integer" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "name" : { + "maxLength" : 100, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "parent" : { + "title" : "Parent", + "type" : "integer", + "x-nullable" : true + }, + "slug" : { + "format" : "slug", + "maxLength" : 100, + "minLength" : 1, + "pattern" : "^[-a-zA-Z0-9_]+$", + "title" : "Slug", + "type" : "string" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + }, + "_depth" : { + "readOnly" : true, + "title" : "depth", + "type" : "integer" + } + }, + "required" : [ + "name", + "slug", + "parent" + ], + "type" : "object" + }, "WritableCustomField" : { "properties" : { "choices" : { @@ -11474,6 +13835,12 @@ "type" : "array", "uniqueItems" : true }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "default" : { "description" : "Default value for the field (must be a JSON value). Encapsulate strings with double quotes (e.g. \"Foo\").", "title" : "Default", @@ -11511,10 +13878,17 @@ "title" : "Label", "type" : "string" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "name" : { "description" : "Internal field name", "maxLength" : 50, "minLength" : 1, + "pattern" : "^[a-z0-9_]+$", "title" : "Name", "type" : "string" }, @@ -11526,10 +13900,12 @@ "type" : { "enum" : [ "text", + "longtext", "integer", "boolean", "date", "url", + "json", "select", "multiselect" ], @@ -11545,7 +13921,7 @@ "validation_maximum" : { "description" : "Maximum allowed value (for numeric fields)", "maximum" : 2147483647, - "minimum" : 0, + "minimum" : -2147483648, "title" : "Maximum value", "type" : "integer", "x-nullable" : true @@ -11553,7 +13929,7 @@ "validation_minimum" : { "description" : "Minimum allowed value (for numeric fields)", "maximum" : 2147483647, - "minimum" : 0, + "minimum" : -2147483648, "title" : "Minimum value", "type" : "integer", "x-nullable" : true @@ -11710,6 +14086,18 @@ }, "WritableDeviceType" : { "properties" : { + "airflow" : { + "enum" : [ + "front-to-rear", + "rear-to-front", + "left-to-right", + "right-to-left", + "side-to-rear", + "passive" + ], + "title" : "Airflow", + "type" : "string" + }, "comments" : { "title" : "Comments", "type" : "string" @@ -11822,6 +14210,18 @@ }, "WritableDeviceWithConfigContext" : { "properties" : { + "airflow" : { + "enum" : [ + "front-to-rear", + "rear-to-front", + "left-to-right", + "right-to-left", + "side-to-rear", + "passive" + ], + "title" : "Airflow", + "type" : "string" + }, "asset_tag" : { "description" : "A unique tag used to identify this device", "maxLength" : 50, @@ -11909,8 +14309,6 @@ "x-nullable" : true }, "position" : { - "description" : "The lowest-numbered unit occupied by the device", - "maximum" : 32767, "minimum" : 1, "title" : "Position (U)", "type" : "integer", @@ -11994,30 +14392,88 @@ } }, "required" : [ + "name", "device_type", "device_role", - "site" + "tenant", + "site", + "rack", + "face", + "virtual_chassis" ], "type" : "object" }, - "WritableFrontPort" : { + "WritableFHRPGroupAssignment" : { "properties" : { - "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "group" : { + "title" : "Group", + "type" : "integer" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "interface" : { "additionalProperties" : { "type" : "string", "x-nullable" : true }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", "readOnly" : true, - "title" : "Cable peer", + "title" : "Interface", "type" : "object" }, - "cable_peer_type" : { + "interface_id" : { + "maximum" : 2147483647, + "minimum" : 0, + "title" : "Interface id", + "type" : "integer" + }, + "interface_type" : { + "title" : "Interface type", + "type" : "string" + }, + "last_updated" : { + "format" : "date-time", "readOnly" : true, - "title" : "Cable peer type", + "title" : "Last updated", "type" : "string" }, + "priority" : { + "maximum" : 255, + "minimum" : 0, + "title" : "Priority", + "type" : "integer" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ + "group", + "interface_type", + "interface_id", + "priority" + ], + "type" : "object" + }, + "WritableFrontPort" : { + "properties" : { + "cable" : { "$ref" : "#/definitions/NestedCable" }, "color" : { "maxLength" : 6, "pattern" : "^[0-9a-f]{6}$", @@ -12066,6 +14522,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -12114,12 +14585,18 @@ "mrj21", "fc", "lc", + "lc-pc", + "lc-upc", "lc-apc", "lsh", + "lsh-pc", + "lsh-upc", "lsh-apc", "mpo", "mtrj", "sc", + "sc-pc", + "sc-upc", "sc-apc", "st", "cs", @@ -12238,12 +14715,18 @@ "mrj21", "fc", "lc", + "lc-pc", + "lc-upc", "lc-apc", "lsh", + "lsh-pc", + "lsh-upc", "lsh-apc", "mpo", "mtrj", "sc", + "sc-pc", + "sc-upc", "sc-apc", "st", "cs", @@ -12275,22 +14758,12 @@ }, "WritableInterface" : { "properties" : { - "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" + "bridge" : { + "title" : "Bridge interface", + "type" : "integer", + "x-nullable" : true }, + "cable" : { "$ref" : "#/definitions/NestedCable" }, "connected_endpoint" : { "additionalProperties" : { "type" : "string", @@ -12311,6 +14784,11 @@ "title" : "Connected endpoint type", "type" : "string" }, + "count_fhrp_groups" : { + "readOnly" : true, + "title" : "Count fhrp groups", + "type" : "integer" + }, "count_ipaddresses" : { "readOnly" : true, "title" : "Count ipaddresses", @@ -12367,6 +14845,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mac_address" : { "title" : "MAC Address", "type" : "string", @@ -12409,6 +14902,229 @@ "type" : "integer", "x-nullable" : true }, + "rf_channel" : { + "enum" : [ + "2.4g-1-2412-22", + "2.4g-2-2417-22", + "2.4g-3-2422-22", + "2.4g-4-2427-22", + "2.4g-5-2432-22", + "2.4g-6-2437-22", + "2.4g-7-2442-22", + "2.4g-8-2447-22", + "2.4g-9-2452-22", + "2.4g-10-2457-22", + "2.4g-11-2462-22", + "2.4g-12-2467-22", + "2.4g-13-2472-22", + "5g-32-5160-20", + "5g-34-5170-40", + "5g-36-5180-20", + "5g-38-5190-40", + "5g-40-5200-20", + "5g-42-5210-80", + "5g-44-5220-20", + "5g-46-5230-40", + "5g-48-5240-20", + "5g-50-5250-160", + "5g-52-5260-20", + "5g-54-5270-40", + "5g-56-5280-20", + "5g-58-5290-80", + "5g-60-5300-20", + "5g-62-5310-40", + "5g-64-5320-20", + "5g-100-5500-20", + "5g-102-5510-40", + "5g-104-5520-20", + "5g-106-5530-80", + "5g-108-5540-20", + "5g-110-5550-40", + "5g-112-5560-20", + "5g-114-5570-160", + "5g-116-5580-20", + "5g-118-5590-40", + "5g-120-5600-20", + "5g-122-5610-80", + "5g-124-5620-20", + "5g-126-5630-40", + "5g-128-5640-20", + "5g-132-5660-20", + "5g-134-5670-40", + "5g-136-5680-20", + "5g-138-5690-80", + "5g-140-5700-20", + "5g-142-5710-40", + "5g-144-5720-20", + "5g-149-5745-20", + "5g-151-5755-40", + "5g-153-5765-20", + "5g-155-5775-80", + "5g-157-5785-20", + "5g-159-5795-40", + "5g-161-5805-20", + "5g-163-5815-160", + "5g-165-5825-20", + "5g-167-5835-40", + "5g-169-5845-20", + "5g-171-5855-80", + "5g-173-5865-20", + "5g-175-5875-40", + "5g-177-5885-20", + "6g-1-5955-20", + "6g-3-5965-40", + "6g-5-5975-20", + "6g-7-5985-80", + "6g-9-5995-20", + "6g-11-6005-40", + "6g-13-6015-20", + "6g-15-6025-160", + "6g-17-6035-20", + "6g-19-6045-40", + "6g-21-6055-20", + "6g-23-6065-80", + "6g-25-6075-20", + "6g-27-6085-40", + "6g-29-6095-20", + "6g-31-6105-320", + "6g-33-6115-20", + "6g-35-6125-40", + "6g-37-6135-20", + "6g-39-6145-80", + "6g-41-6155-20", + "6g-43-6165-40", + "6g-45-6175-20", + "6g-47-6185-160", + "6g-49-6195-20", + "6g-51-6205-40", + "6g-53-6215-20", + "6g-55-6225-80", + "6g-57-6235-20", + "6g-59-6245-40", + "6g-61-6255-20", + "6g-65-6275-20", + "6g-67-6285-40", + "6g-69-6295-20", + "6g-71-6305-80", + "6g-73-6315-20", + "6g-75-6325-40", + "6g-77-6335-20", + "6g-79-6345-160", + "6g-81-6355-20", + "6g-83-6365-40", + "6g-85-6375-20", + "6g-87-6385-80", + "6g-89-6395-20", + "6g-91-6405-40", + "6g-93-6415-20", + "6g-95-6425-320", + "6g-97-6435-20", + "6g-99-6445-40", + "6g-101-6455-20", + "6g-103-6465-80", + "6g-105-6475-20", + "6g-107-6485-40", + "6g-109-6495-20", + "6g-111-6505-160", + "6g-113-6515-20", + "6g-115-6525-40", + "6g-117-6535-20", + "6g-119-6545-80", + "6g-121-6555-20", + "6g-123-6565-40", + "6g-125-6575-20", + "6g-129-6595-20", + "6g-131-6605-40", + "6g-133-6615-20", + "6g-135-6625-80", + "6g-137-6635-20", + "6g-139-6645-40", + "6g-141-6655-20", + "6g-143-6665-160", + "6g-145-6675-20", + "6g-147-6685-40", + "6g-149-6695-20", + "6g-151-6705-80", + "6g-153-6715-20", + "6g-155-6725-40", + "6g-157-6735-20", + "6g-159-6745-320", + "6g-161-6755-20", + "6g-163-6765-40", + "6g-165-6775-20", + "6g-167-6785-80", + "6g-169-6795-20", + "6g-171-6805-40", + "6g-173-6815-20", + "6g-175-6825-160", + "6g-177-6835-20", + "6g-179-6845-40", + "6g-181-6855-20", + "6g-183-6865-80", + "6g-185-6875-20", + "6g-187-6885-40", + "6g-189-6895-20", + "6g-193-6915-20", + "6g-195-6925-40", + "6g-197-6935-20", + "6g-199-6945-80", + "6g-201-6955-20", + "6g-203-6965-40", + "6g-205-6975-20", + "6g-207-6985-160", + "6g-209-6995-20", + "6g-211-7005-40", + "6g-213-7015-20", + "6g-215-7025-80", + "6g-217-7035-20", + "6g-219-7045-40", + "6g-221-7055-20", + "6g-225-7075-20", + "6g-227-7085-40", + "6g-229-7095-20", + "6g-233-7115-20", + "60g-1-58320-2160", + "60g-2-60480-2160", + "60g-3-62640-2160", + "60g-4-64800-2160", + "60g-5-66960-2160", + "60g-6-69120-2160", + "60g-9-59400-4320", + "60g-10-61560-4320", + "60g-11-63720-4320", + "60g-12-65880-4320", + "60g-13-68040-4320", + "60g-17-60480-6480", + "60g-18-62640-6480", + "60g-19-64800-6480", + "60g-20-66960-6480", + "60g-25-61560-6480", + "60g-26-63720-6480", + "60g-27-65880-6480" + ], + "title" : "Wireless channel", + "type" : "string" + }, + "rf_channel_frequency" : { + "format" : "decimal", + "title" : "Channel frequency (MHz)", + "type" : "number", + "x-nullable" : true + }, + "rf_channel_width" : { + "format" : "decimal", + "title" : "Channel width (MHz)", + "type" : "number", + "x-nullable" : true + }, + "rf_role" : { + "enum" : [ + "ap", + "station" + ], + "title" : "Wireless role", + "type" : "string" + }, "tagged_vlans" : { "items" : { "title" : "Tagged VLANs", @@ -12421,9 +15137,17 @@ "items" : { "$ref" : "#/definitions/NestedTag" }, "type" : "array" }, + "tx_power" : { + "maximum" : 127, + "minimum" : 0, + "title" : "Transmit power (dBm)", + "type" : "integer", + "x-nullable" : true + }, "type" : { "enum" : [ "virtual", + "bridge", "lag", "100base-tx", "1000base-t", @@ -12474,7 +15198,7 @@ "16gfc-sfpp", "32gfc-sfp28", "64gfc-qsfpp", - "128gfc-sfp28", + "128gfc-qsfp28", "infiniband-sdr", "infiniband-ddr", "infiniband-qdr", @@ -12493,6 +15217,10 @@ "cisco-stackwise-plus", "cisco-flexstack", "cisco-flexstack-plus", + "cisco-stackwise-80", + "cisco-stackwise-160", + "cisco-stackwise-320", + "cisco-stackwise-480", "juniper-vcp", "extreme-summitstack", "extreme-summitstack-128", @@ -12514,6 +15242,25 @@ "title" : "Url", "type" : "string" }, + "wireless_lans" : { + "items" : { + "title" : "Wireless LANs", + "type" : "integer" + }, + "type" : "array", + "uniqueItems" : true + }, + "wireless_link" : { + "title" : "Wireless link", + "type" : "integer", + "x-nullable" : true + }, + "wwn" : { + "description" : "64-bit World Wide Name", + "title" : "WWN", + "type" : "string", + "x-nullable" : true + }, "_occupied" : { "readOnly" : true, "title" : "occupied", @@ -12579,6 +15326,7 @@ "type" : { "enum" : [ "virtual", + "bridge", "lag", "100base-tx", "1000base-t", @@ -12629,7 +15377,7 @@ "16gfc-sfpp", "32gfc-sfp28", "64gfc-qsfpp", - "128gfc-sfp28", + "128gfc-qsfp28", "infiniband-sdr", "infiniband-ddr", "infiniband-qdr", @@ -12648,6 +15396,10 @@ "cisco-stackwise-plus", "cisco-flexstack", "cisco-flexstack-plus", + "cisco-stackwise-80", + "cisco-stackwise-160", + "cisco-stackwise-320", + "cisco-stackwise-480", "juniper-vcp", "extreme-summitstack", "extreme-summitstack-128", @@ -12829,7 +15581,7 @@ "dns_name" : { "description" : "Hostname or FQDN (not case-sensitive)", "maxLength" : 255, - "pattern" : "^[0-9A-Za-z._-]+$", + "pattern" : "^([0-9A-Za-z_-]+|\\*)(\\.[0-9A-Za-z_-]+)*\\.?$", "title" : "DNS Name", "type" : "string" }, @@ -13151,6 +15903,15 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "tenant" : { + "title" : "Tenant", + "type" : "integer", + "x-nullable" : true + }, "url" : { "format" : "uri", "readOnly" : true, @@ -13313,6 +16074,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -13340,21 +16105,6 @@ "type" : "integer" }, "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "comments" : { "title" : "Comments", "type" : "string" @@ -13406,6 +16156,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -13498,21 +16263,6 @@ "WritablePowerOutlet" : { "properties" : { "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "connected_endpoint" : { "additionalProperties" : { "type" : "string", @@ -13585,6 +16335,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -13666,6 +16431,7 @@ "nema-l15-60r", "nema-l21-20r", "nema-l21-30r", + "nema-l22-30r", "CS6360C", "CS6364C", "CS8164C", @@ -13683,6 +16449,7 @@ "ita-m", "ita-n", "ita-o", + "ita-multistandard", "usb-a", "usb-micro-b", "usb-c", @@ -13832,6 +16599,7 @@ "nema-l15-60r", "nema-l21-20r", "nema-l21-30r", + "nema-l22-30r", "CS6360C", "CS6364C", "CS8164C", @@ -13849,6 +16617,7 @@ "ita-m", "ita-n", "ita-o", + "ita-multistandard", "usb-a", "usb-micro-b", "usb-c", @@ -13875,6 +16644,12 @@ }, "WritablePowerPanel" : { "properties" : { + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "custom_fields" : { "default" : { }, "title" : "Custom fields", @@ -13890,6 +16665,12 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "location" : { "title" : "Location", "type" : "integer", @@ -13938,21 +16719,6 @@ "x-nullable" : true }, "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "connected_endpoint" : { "additionalProperties" : { "type" : "string", @@ -14015,6 +16781,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -14099,6 +16880,7 @@ "nema-l15-60p", "nema-l21-20p", "nema-l21-30p", + "nema-l22-30p", "cs6361c", "cs6365c", "cs8165c", @@ -14274,6 +17056,7 @@ "nema-l15-60p", "nema-l21-20p", "nema-l21-30p", + "nema-l22-30p", "cs6361c", "cs6365c", "cs8165c", @@ -14543,7 +17326,6 @@ "type" : "string" }, "facility_id" : { - "description" : "Locally-assigned identifier", "maxLength" : 50, "title" : "Facility ID", "type" : "string", @@ -14673,7 +17455,8 @@ }, "required" : [ "name", - "site" + "site", + "location" ], "type" : "object" }, @@ -14706,6 +17489,12 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "rack" : { "title" : "Rack", "type" : "integer" @@ -14750,21 +17539,6 @@ "WritableRearPort" : { "properties" : { "cable" : { "$ref" : "#/definitions/NestedCable" }, - "cable_peer" : { - "additionalProperties" : { - "type" : "string", - "x-nullable" : true - }, - "description" : "\nReturn the appropriate serializer for the cable termination model.\n", - "readOnly" : true, - "title" : "Cable peer", - "type" : "object" - }, - "cable_peer_type" : { - "readOnly" : true, - "title" : "Cable peer type", - "type" : "string" - }, "color" : { "maxLength" : 6, "pattern" : "^[0-9a-f]{6}$", @@ -14813,6 +17587,21 @@ "title" : "Last updated", "type" : "string" }, + "link_peer" : { + "additionalProperties" : { + "type" : "string", + "x-nullable" : true + }, + "description" : "\nReturn the appropriate serializer for the link termination model.\n", + "readOnly" : true, + "title" : "Link peer", + "type" : "object" + }, + "link_peer_type" : { + "readOnly" : true, + "title" : "Link peer type", + "type" : "string" + }, "mark_connected" : { "description" : "Treat as if a cable is connected", "title" : "Mark connected", @@ -14856,12 +17645,18 @@ "mrj21", "fc", "lc", + "lc-pc", + "lc-upc", "lc-apc", "lsh", + "lsh-pc", + "lsh-upc", "lsh-apc", "mpo", "mtrj", "sc", + "sc-pc", + "sc-upc", "sc-apc", "st", "cs", @@ -14974,12 +17769,18 @@ "mrj21", "fc", "lc", + "lc-pc", + "lc-upc", "lc-apc", "lsh", + "lsh-pc", + "lsh-upc", "lsh-apc", "mpo", "mtrj", "sc", + "sc-pc", + "sc-upc", "sc-apc", "st", "cs", @@ -15066,6 +17867,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -15209,7 +18014,8 @@ "protocol" : { "enum" : [ "tcp", - "udp" + "udp", + "sctp" ], "title" : "Protocol", "type" : "string" @@ -15247,6 +18053,11 @@ "type" : "integer", "x-nullable" : true }, + "asns" : { + "items" : { "type" : "integer" }, + "type" : "array", + "uniqueItems" : true + }, "circuit_count" : { "readOnly" : true, "title" : "Circuit count", @@ -15478,6 +18289,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "url" : { "format" : "uri", "readOnly" : true, @@ -15673,6 +18488,10 @@ "title" : "Slug", "type" : "string" }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, "tenant_count" : { "readOnly" : true, "title" : "Tenant count", @@ -15831,6 +18650,12 @@ }, "WritableVirtualChassis" : { "properties" : { + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, "custom_fields" : { "default" : { }, "title" : "Custom fields", @@ -15851,6 +18676,12 @@ "title" : "Id", "type" : "integer" }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, "master" : { "title" : "Master", "type" : "integer", @@ -16111,6 +18942,7 @@ } }, "required" : [ + "group", "vid", "name" ], @@ -16118,6 +18950,16 @@ }, "WritableVMInterface" : { "properties" : { + "bridge" : { + "title" : "Bridge interface", + "type" : "integer", + "x-nullable" : true + }, + "count_fhrp_groups" : { + "readOnly" : true, + "title" : "Count fhrp groups", + "type" : "integer" + }, "count_ipaddresses" : { "readOnly" : true, "title" : "Count ipaddresses", @@ -16315,6 +19157,272 @@ }, "required" : [ "name" ], "type" : "object" + }, + "WritableWirelessLAN" : { + "properties" : { + "auth_cipher" : { + "enum" : [ + "auto", + "tkip", + "aes" + ], + "title" : "Auth cipher", + "type" : "string" + }, + "auth_psk" : { + "maxLength" : 64, + "title" : "Pre-shared key", + "type" : "string" + }, + "auth_type" : { + "enum" : [ + "open", + "wep", + "wpa-personal", + "wpa-enterprise" + ], + "title" : "Auth type", + "type" : "string" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "group" : { + "title" : "Group", + "type" : "integer", + "x-nullable" : true + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "ssid" : { + "maxLength" : 32, + "minLength" : 1, + "title" : "SSID", + "type" : "string" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + }, + "vlan" : { + "title" : "VLAN", + "type" : "integer", + "x-nullable" : true + } + }, + "required" : [ "ssid" ], + "type" : "object" + }, + "WritableWirelessLANGroup" : { + "properties" : { + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "name" : { + "maxLength" : 100, + "minLength" : 1, + "title" : "Name", + "type" : "string" + }, + "parent" : { + "title" : "Parent", + "type" : "integer", + "x-nullable" : true + }, + "slug" : { + "format" : "slug", + "maxLength" : 100, + "minLength" : 1, + "pattern" : "^[-a-zA-Z0-9_]+$", + "title" : "Slug", + "type" : "string" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + }, + "wirelesslan_count" : { + "readOnly" : true, + "title" : "Wirelesslan count", + "type" : "integer" + }, + "_depth" : { + "readOnly" : true, + "title" : "depth", + "type" : "integer" + } + }, + "required" : [ + "name", + "slug", + "parent" + ], + "type" : "object" + }, + "WritableWirelessLink" : { + "properties" : { + "auth_cipher" : { + "enum" : [ + "auto", + "tkip", + "aes" + ], + "title" : "Auth cipher", + "type" : "string" + }, + "auth_psk" : { + "maxLength" : 64, + "title" : "Pre-shared key", + "type" : "string" + }, + "auth_type" : { + "enum" : [ + "open", + "wep", + "wpa-personal", + "wpa-enterprise" + ], + "title" : "Auth type", + "type" : "string" + }, + "created" : { + "format" : "date", + "readOnly" : true, + "title" : "Created", + "type" : "string" + }, + "custom_fields" : { + "default" : { }, + "title" : "Custom fields", + "type" : "object" + }, + "description" : { + "maxLength" : 200, + "title" : "Description", + "type" : "string" + }, + "display" : { + "readOnly" : true, + "title" : "Display", + "type" : "string" + }, + "id" : { + "readOnly" : true, + "title" : "Id", + "type" : "integer" + }, + "interface_a" : { + "title" : "Interface a", + "type" : "integer" + }, + "interface_b" : { + "title" : "Interface b", + "type" : "integer" + }, + "last_updated" : { + "format" : "date-time", + "readOnly" : true, + "title" : "Last updated", + "type" : "string" + }, + "ssid" : { + "maxLength" : 32, + "title" : "SSID", + "type" : "string" + }, + "status" : { + "enum" : [ + "connected", + "planned", + "decommissioning" + ], + "title" : "Status", + "type" : "string" + }, + "tags" : { + "items" : { "$ref" : "#/definitions/NestedTag" }, + "type" : "array" + }, + "url" : { + "format" : "uri", + "readOnly" : true, + "title" : "Url", + "type" : "string" + } + }, + "required" : [ + "interface_a", + "interface_b" + ], + "type" : "object" } }, "host" : "127.0.0.1:8000", @@ -16323,7 +19431,7 @@ "license" : { "name" : "Apache v2 License" }, "termsOfService" : "https://github.com/netbox-community/netbox", "title" : "NetBox API", - "version" : "3.0" + "version" : "3.1" }, "paths" : { "/circuits/circuit-terminations/" : { @@ -16373,6 +19481,13 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "description", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -16639,6 +19754,76 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "description__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -16866,6 +20051,13 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "description", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -16915,6 +20107,13 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -16974,1130 +20173,8167 @@ { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/CircuitType" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "circuits" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "circuits_circuit-types_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/CircuitType" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CircuitType" } + } }, + "tags" : [ "circuits" ] + }, + "post" : { + "description" : "", + "operationId" : "circuits_circuit-types_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/CircuitType" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CircuitType" } + } }, + "tags" : [ "circuits" ] + }, + "put" : { + "description" : "", + "operationId" : "circuits_circuit-types_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/CircuitType" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CircuitType" } + } }, + "tags" : [ "circuits" ] + } + }, + "/circuits/circuit-types/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "circuits_circuit-types_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "circuits" ] + }, + "get" : { + "description" : "", + "operationId" : "circuits_circuit-types_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CircuitType" } + } }, + "tags" : [ "circuits" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this circuit type.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "circuits_circuit-types_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/CircuitType" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CircuitType" } + } }, + "tags" : [ "circuits" ] + }, + "put" : { + "description" : "", + "operationId" : "circuits_circuit-types_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/CircuitType" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CircuitType" } + } }, + "tags" : [ "circuits" ] + } + }, + "/circuits/circuits/" : { + "delete" : { + "description" : "", + "operationId" : "circuits_circuits_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "circuits" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "circuits_circuits_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cid", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "install_date", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "commit_rate", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact_role", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "provider_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "provider", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "provider_network_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "status", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cid__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cid__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cid__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cid__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cid__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cid__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cid__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cid__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cid__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cid__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "install_date__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "install_date__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "install_date__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "install_date__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "install_date__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "commit_rate__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "commit_rate__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "commit_rate__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "commit_rate__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "commit_rate__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact_role__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "provider_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "provider__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "provider_network_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "status__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/Circuit" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "circuits" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "circuits_circuits_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCircuit" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Circuit" } + } }, + "tags" : [ "circuits" ] + }, + "post" : { + "description" : "", + "operationId" : "circuits_circuits_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCircuit" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Circuit" } + } }, + "tags" : [ "circuits" ] + }, + "put" : { + "description" : "", + "operationId" : "circuits_circuits_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCircuit" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Circuit" } + } }, + "tags" : [ "circuits" ] + } + }, + "/circuits/circuits/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "circuits_circuits_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "circuits" ] + }, + "get" : { + "description" : "", + "operationId" : "circuits_circuits_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Circuit" } + } }, + "tags" : [ "circuits" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this circuit.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "circuits_circuits_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCircuit" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Circuit" } + } }, + "tags" : [ "circuits" ] + }, + "put" : { + "description" : "", + "operationId" : "circuits_circuits_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCircuit" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Circuit" } + } }, + "tags" : [ "circuits" ] + } + }, + "/circuits/provider-networks/" : { + "delete" : { + "description" : "", + "operationId" : "circuits_provider-networks_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "circuits" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "circuits_provider-networks_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "provider_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "provider", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "provider_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "provider__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/ProviderNetwork" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "circuits" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "circuits_provider-networks_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableProviderNetwork" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + } }, + "tags" : [ "circuits" ] + }, + "post" : { + "description" : "", + "operationId" : "circuits_provider-networks_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableProviderNetwork" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + } }, + "tags" : [ "circuits" ] + }, + "put" : { + "description" : "", + "operationId" : "circuits_provider-networks_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableProviderNetwork" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + } }, + "tags" : [ "circuits" ] + } + }, + "/circuits/provider-networks/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "circuits_provider-networks_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "circuits" ] + }, + "get" : { + "description" : "", + "operationId" : "circuits_provider-networks_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + } }, + "tags" : [ "circuits" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this provider network.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "circuits_provider-networks_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableProviderNetwork" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + } }, + "tags" : [ "circuits" ] + }, + "put" : { + "description" : "", + "operationId" : "circuits_provider-networks_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableProviderNetwork" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + } }, + "tags" : [ "circuits" ] + } + }, + "/circuits/providers/" : { + "delete" : { + "description" : "", + "operationId" : "circuits_providers_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "circuits" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "circuits_providers_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "asn", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "account", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact_role", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "asn__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "asn__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "asn__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "asn__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "asn__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "account__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "account__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "account__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "account__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "account__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "account__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "account__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "account__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "account__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "account__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact_role__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/Provider" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "circuits" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "circuits_providers_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/Provider" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Provider" } + } }, + "tags" : [ "circuits" ] + }, + "post" : { + "description" : "", + "operationId" : "circuits_providers_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/Provider" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Provider" } + } }, + "tags" : [ "circuits" ] + }, + "put" : { + "description" : "", + "operationId" : "circuits_providers_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/Provider" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Provider" } + } }, + "tags" : [ "circuits" ] + } + }, + "/circuits/providers/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "circuits_providers_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "circuits" ] + }, + "get" : { + "description" : "", + "operationId" : "circuits_providers_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Provider" } + } }, + "tags" : [ "circuits" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this provider.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "circuits_providers_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/Provider" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Provider" } + } }, + "tags" : [ "circuits" ] + }, + "put" : { + "description" : "", + "operationId" : "circuits_providers_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/Provider" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Provider" } + } }, + "tags" : [ "circuits" ] + } + }, + "/dcim/cables/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_cables_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_cables_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "length", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "length_unit", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_a_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_b_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_a_type", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_b_type", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "status", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "rack_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "rack", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "length__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "length__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "length__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "length__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "length__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "length_unit__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_a_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_a_id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_a_id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_a_id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_a_id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_b_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_b_id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_b_id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_b_id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_b_id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_a_type__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "termination_b_type__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "status__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/Cable" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_cables_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCable" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Cable" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_cables_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCable" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Cable" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_cables_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCable" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Cable" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/cables/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_cables_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_cables_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Cable" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this cable.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_cables_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCable" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Cable" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_cables_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCable" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Cable" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/connected-device/" : { + "get" : { + "description" : "This endpoint allows a user to determine what device (if any) is connected to a given peer device and peer\ninterface. This is useful in a situation where a device boots with no configuration, but can detect its neighbors\nvia a protocol such as LLDP. Two query parameters must be included in the request:\n\n* `peer_device`: The name of the peer device\n* `peer_interface`: The name of the peer interface", + "operationId" : "dcim_connected-device_list", + "parameters" : [ + { + "description" : "The name of the peer device", + "in" : "query", + "name" : "peer_device", + "required" : true, + "type" : "string" + }, + { + "description" : "The name of the peer interface", + "in" : "query", + "name" : "peer_interface", + "required" : true, + "type" : "string" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Device" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ] + }, + "/dcim/console-port-templates/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_console-port-templates_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_console-port-templates_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "devicetype_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "devicetype_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/ConsolePortTemplate" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_console-port-templates_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsolePortTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_console-port-templates_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsolePortTemplate" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_console-port-templates_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsolePortTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/console-port-templates/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_console-port-templates_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_console-port-templates_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this console port template.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_console-port-templates_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsolePortTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_console-port-templates_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsolePortTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/console-ports/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_console-ports_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_console-ports_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cabled", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "connected", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/ConsolePort" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_console-ports_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsolePort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePort" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_console-ports_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsolePort" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePort" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_console-ports_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsolePort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePort" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/console-ports/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_console-ports_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_console-ports_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePort" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this console port.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_console-ports_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsolePort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePort" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_console-ports_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsolePort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePort" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/console-ports/{id}/trace/" : { + "get" : { + "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", + "operationId" : "dcim_console-ports_trace", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsolePort" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this console port.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] + }, + "/dcim/console-server-port-templates/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_console-server-port-templates_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_console-server-port-templates_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "devicetype_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "devicetype_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_console-server-port-templates_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsoleServerPortTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_console-server-port-templates_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsoleServerPortTemplate" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_console-server-port-templates_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsoleServerPortTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/console-server-port-templates/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_console-server-port-templates_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_console-server-port-templates_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this console server port template.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_console-server-port-templates_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsoleServerPortTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_console-server-port-templates_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsoleServerPortTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/console-server-ports/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_console-server-ports_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_console-server-ports_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cabled", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "connected", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/ConsoleServerPort" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_console-server-ports_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsoleServerPort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_console-server-ports_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsoleServerPort" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_console-server-ports_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsoleServerPort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/console-server-ports/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_console-server-ports_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_console-server-ports_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this console server port.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_console-server-ports_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsoleServerPort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_console-server-ports_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableConsoleServerPort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/console-server-ports/{id}/trace/" : { + "get" : { + "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", + "operationId" : "dcim_console-server-ports_trace", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this console server port.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] + }, + "/dcim/device-bay-templates/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_device-bay-templates_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_device-bay-templates_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "devicetype_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "devicetype_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/DeviceBayTemplate" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_device-bay-templates_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceBayTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_device-bay-templates_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceBayTemplate" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_device-bay-templates_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceBayTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/device-bay-templates/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_device-bay-templates_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_device-bay-templates_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this device bay template.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_device-bay-templates_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceBayTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_device-bay-templates_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceBayTemplate" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/device-bays/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_device-bays_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_device-bays_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "label__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/DeviceBay" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_device-bays_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceBay" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBay" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_device-bays_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceBay" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBay" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_device-bays_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceBay" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBay" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/device-bays/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_device-bays_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_device-bays_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBay" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this device bay.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_device-bays_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceBay" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBay" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_device-bays_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceBay" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceBay" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/device-roles/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_device-roles_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_device-roles_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "vm_role", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "color__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/DeviceRole" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_device-roles_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/DeviceRole" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceRole" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_device-roles_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/DeviceRole" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceRole" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_device-roles_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/DeviceRole" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceRole" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/device-roles/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_device-roles_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_device-roles_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceRole" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this device role.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_device-roles_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/DeviceRole" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceRole" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_device-roles_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/DeviceRole" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceRole" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/device-types/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_device-types_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_device-types_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "part_number", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "u_height", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "is_full_depth", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "subdevice_role", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "airflow", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "manufacturer_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "manufacturer", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "console_ports", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "console_server_ports", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "power_ports", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "power_outlets", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "interfaces", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "pass_through_ports", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_bays", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "id__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "part_number__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "part_number__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "part_number__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "part_number__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "part_number__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "part_number__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "part_number__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "part_number__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "part_number__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "part_number__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "u_height__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "u_height__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "u_height__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "u_height__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "u_height__gt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "subdevice_role__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "airflow__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "manufacturer_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "manufacturer__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/DeviceType" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_device-types_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceType" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceType" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_device-types_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceType" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceType" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_device-types_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceType" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceType" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/device-types/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_device-types_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_device-types_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceType" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this device type.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_device-types_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceType" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceType" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_device-types_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableDeviceType" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceType" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/devices/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_devices_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_devices_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "asset_tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "face", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "position", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "airflow", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "vc_position", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "vc_priority", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "last_updated__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "last_updated__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "tenant_group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "tenant_group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "tenant_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "tenant", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "contact", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__n", + "name" : "contact_role", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__ic", + "name" : "local_context_data", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nic", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__iew", + "name" : "manufacturer_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__niew", + "name" : "manufacturer", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__isw", + "name" : "device_type_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nisw", + "name" : "role_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__ie", + "name" : "role", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nie", + "name" : "parent_device_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__empty", + "name" : "platform_id", "required" : false, "type" : "string" }, { - "description" : "Number of results to return per page.", + "description" : "", "in" : "query", - "name" : "limit", + "name" : "platform", "required" : false, - "type" : "integer" + "type" : "string" }, { - "description" : "The initial index from which to return the results.", + "description" : "", "in" : "query", - "name" : "offset", + "name" : "region_id", "required" : false, - "type" : "integer" - } - ], - "responses" : { "200" : { - "description" : "", - "schema" : { - "properties" : { - "count" : { "type" : "integer" }, - "next" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "previous" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "results" : { - "items" : { "$ref" : "#/definitions/CircuitType" }, - "type" : "array" - } - }, - "required" : [ - "count", - "results" - ], - "type" : "object" - } - } }, - "tags" : [ "circuits" ] - }, - "parameters" : [ ], - "patch" : { - "description" : "", - "operationId" : "circuits_circuit-types_bulk_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/CircuitType" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/CircuitType" } - } }, - "tags" : [ "circuits" ] - }, - "post" : { - "description" : "", - "operationId" : "circuits_circuit-types_create", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/CircuitType" } - } ], - "responses" : { "201" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/CircuitType" } - } }, - "tags" : [ "circuits" ] - }, - "put" : { - "description" : "", - "operationId" : "circuits_circuit-types_bulk_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/CircuitType" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/CircuitType" } - } }, - "tags" : [ "circuits" ] - } - }, - "/circuits/circuit-types/{id}/" : { - "delete" : { - "description" : "", - "operationId" : "circuits_circuit-types_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "circuits" ] - }, - "get" : { - "description" : "", - "operationId" : "circuits_circuit-types_read", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/CircuitType" } - } }, - "tags" : [ "circuits" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this circuit type.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ], - "patch" : { - "description" : "", - "operationId" : "circuits_circuit-types_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/CircuitType" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/CircuitType" } - } }, - "tags" : [ "circuits" ] - }, - "put" : { - "description" : "", - "operationId" : "circuits_circuit-types_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/CircuitType" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/CircuitType" } - } }, - "tags" : [ "circuits" ] - } - }, - "/circuits/circuits/" : { - "delete" : { - "description" : "", - "operationId" : "circuits_circuits_bulk_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "circuits" ] - }, - "get" : { - "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "circuits_circuits_list", - "parameters" : [ + "type" : "string" + }, { "description" : "", "in" : "query", - "name" : "id", + "name" : "region", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cid", + "name" : "site_group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "install_date", + "name" : "site_group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "commit_rate", + "name" : "site_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "site", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "location_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "rack_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "cluster_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "model", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "status", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group_id", + "name" : "is_full_depth", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group", + "name" : "mac_address", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_id", + "name" : "serial", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant", + "name" : "has_primary_ip", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "virtual_chassis_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "provider_id", + "name" : "virtual_chassis_member", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "provider", + "name" : "console_ports", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "provider_network_id", + "name" : "console_server_ports", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type_id", + "name" : "power_ports", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type", + "name" : "power_outlets", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "status", + "name" : "interfaces", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id", + "name" : "pass_through_ports", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region", + "name" : "device_bays", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id", + "name" : "tag", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cid__n", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cid__ic", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cid__nic", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cid__iew", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cid__niew", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cid__isw", + "name" : "name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cid__nisw", + "name" : "asset_tag__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cid__ie", + "name" : "asset_tag__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cid__nie", + "name" : "asset_tag__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cid__empty", + "name" : "asset_tag__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "install_date__n", + "name" : "asset_tag__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "install_date__lte", + "name" : "asset_tag__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "install_date__lt", + "name" : "asset_tag__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "install_date__gte", + "name" : "asset_tag__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "install_date__gt", + "name" : "asset_tag__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "commit_rate__n", + "name" : "asset_tag__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "commit_rate__lte", + "name" : "face__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "commit_rate__lt", + "name" : "position__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "commit_rate__gte", + "name" : "position__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "commit_rate__gt", + "name" : "position__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group_id__n", + "name" : "position__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group__n", + "name" : "position__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_id__n", + "name" : "airflow__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant__n", + "name" : "vc_position__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "provider_id__n", + "name" : "vc_position__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "provider__n", + "name" : "vc_position__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "provider_network_id__n", + "name" : "vc_position__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type_id__n", + "name" : "vc_position__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "vc_priority__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "status__n", + "name" : "vc_priority__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "vc_priority__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "vc_priority__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "vc_priority__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "tenant_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "tenant_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "tenant_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag__n", + "name" : "tenant__n", "required" : false, "type" : "string" }, { - "description" : "Number of results to return per page.", + "description" : "", "in" : "query", - "name" : "limit", + "name" : "contact__n", "required" : false, - "type" : "integer" + "type" : "string" }, { - "description" : "The initial index from which to return the results.", + "description" : "", "in" : "query", - "name" : "offset", + "name" : "contact_role__n", "required" : false, - "type" : "integer" - } - ], - "responses" : { "200" : { - "description" : "", - "schema" : { - "properties" : { - "count" : { "type" : "integer" }, - "next" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "previous" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "results" : { - "items" : { "$ref" : "#/definitions/Circuit" }, - "type" : "array" - } - }, - "required" : [ - "count", - "results" - ], - "type" : "object" - } - } }, - "tags" : [ "circuits" ] - }, - "parameters" : [ ], - "patch" : { - "description" : "", - "operationId" : "circuits_circuits_bulk_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableCircuit" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Circuit" } - } }, - "tags" : [ "circuits" ] - }, - "post" : { - "description" : "", - "operationId" : "circuits_circuits_create", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableCircuit" } - } ], - "responses" : { "201" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Circuit" } - } }, - "tags" : [ "circuits" ] - }, - "put" : { - "description" : "", - "operationId" : "circuits_circuits_bulk_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableCircuit" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Circuit" } - } }, - "tags" : [ "circuits" ] - } - }, - "/circuits/circuits/{id}/" : { - "delete" : { - "description" : "", - "operationId" : "circuits_circuits_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "circuits" ] - }, - "get" : { - "description" : "", - "operationId" : "circuits_circuits_read", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Circuit" } - } }, - "tags" : [ "circuits" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this circuit.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ], - "patch" : { - "description" : "", - "operationId" : "circuits_circuits_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableCircuit" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Circuit" } - } }, - "tags" : [ "circuits" ] - }, - "put" : { - "description" : "", - "operationId" : "circuits_circuits_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableCircuit" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Circuit" } - } }, - "tags" : [ "circuits" ] - } - }, - "/circuits/provider-networks/" : { - "delete" : { - "description" : "", - "operationId" : "circuits_provider-networks_bulk_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "circuits" ] - }, - "get" : { - "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "circuits_provider-networks_list", - "parameters" : [ + "type" : "string" + }, { "description" : "", "in" : "query", - "name" : "id", + "name" : "manufacturer_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name", + "name" : "manufacturer__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "device_type_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "role_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "role__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "parent_device_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "platform_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "platform__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "region_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "provider_id", + "name" : "region__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "provider", + "name" : "site_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag", + "name" : "site_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "site_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "site__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "location_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "rack_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "cluster_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "model__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "status__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "mac_address__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "mac_address__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "mac_address__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "mac_address__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "mac_address__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "mac_address__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "mac_address__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "mac_address__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "provider_id__n", + "name" : "mac_address__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "provider__n", + "name" : "virtual_chassis_id__n", "required" : false, "type" : "string" }, @@ -18139,7 +28375,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/ProviderNetwork" }, + "items" : { "$ref" : "#/definitions/DeviceWithConfigContext" }, "type" : "array" } }, @@ -18150,75 +28386,75 @@ "type" : "object" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "circuits_provider-networks_bulk_partial_update", + "operationId" : "dcim_devices_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableProviderNetwork" } + "schema" : { "$ref" : "#/definitions/WritableDeviceWithConfigContext" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "circuits_provider-networks_create", + "operationId" : "dcim_devices_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableProviderNetwork" } + "schema" : { "$ref" : "#/definitions/WritableDeviceWithConfigContext" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "circuits_provider-networks_bulk_update", + "operationId" : "dcim_devices_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableProviderNetwork" } + "schema" : { "$ref" : "#/definitions/WritableDeviceWithConfigContext" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] } }, - "/circuits/provider-networks/{id}/" : { + "/dcim/devices/{id}/" : { "delete" : { "description" : "", - "operationId" : "circuits_provider-networks_delete", + "operationId" : "dcim_devices_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "circuits_provider-networks_read", + "operationId" : "dcim_devices_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this provider network.", + "description" : "A unique integer value identifying this device.", "in" : "path", "name" : "id", "required" : true, @@ -18226,46 +28462,70 @@ } ], "patch" : { "description" : "", - "operationId" : "circuits_provider-networks_partial_update", + "operationId" : "dcim_devices_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableProviderNetwork" } + "schema" : { "$ref" : "#/definitions/WritableDeviceWithConfigContext" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "circuits_provider-networks_update", + "operationId" : "dcim_devices_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableProviderNetwork" } + "schema" : { "$ref" : "#/definitions/WritableDeviceWithConfigContext" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ProviderNetwork" } + "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] } }, - "/circuits/providers/" : { + "/dcim/devices/{id}/napalm/" : { + "get" : { + "description" : "Execute a NAPALM method on a Device", + "operationId" : "dcim_devices_napalm", + "parameters" : [ { + "in" : "query", + "name" : "method", + "required" : true, + "type" : "string" + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/DeviceNAPALM" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this device.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] + }, + "/dcim/front-port-templates/" : { "delete" : { "description" : "", - "operationId" : "circuits_providers_bulk_delete", + "operationId" : "dcim_front-port-templates_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "circuits_providers_list", + "operationId" : "dcim_front-port-templates_list", "parameters" : [ { "description" : "", @@ -18284,21 +28544,14 @@ { "description" : "", "in" : "query", - "name" : "slug", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "asn", + "name" : "type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "account", + "name" : "color", "required" : false, "type" : "string" }, @@ -18354,49 +28607,7 @@ { "description" : "", "in" : "query", - "name" : "region_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "region", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_group_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_group", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "tag", + "name" : "devicetype_id", "required" : false, "type" : "string" }, @@ -18508,224 +28719,84 @@ { "description" : "", "in" : "query", - "name" : "slug__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__ic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__nic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__iew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__niew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__isw", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__nisw", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__ie", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__nie", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__empty", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "asn__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "asn__lte", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "asn__lt", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "asn__gte", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "asn__gt", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "account__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "account__ic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "account__nic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "account__iew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "account__niew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "account__isw", + "name" : "type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "account__nisw", + "name" : "color__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "account__ie", + "name" : "color__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "account__nie", + "name" : "color__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "account__empty", + "name" : "color__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "color__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "color__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "color__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "color__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "color__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "color__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag__n", + "name" : "devicetype_id__n", "required" : false, "type" : "string" }, @@ -18760,7 +28831,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/Provider" }, + "items" : { "$ref" : "#/definitions/FrontPortTemplate" }, "type" : "array" } }, @@ -18771,75 +28842,75 @@ "type" : "object" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "circuits_providers_bulk_partial_update", + "operationId" : "dcim_front-port-templates_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/Provider" } + "schema" : { "$ref" : "#/definitions/WritableFrontPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Provider" } + "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "circuits_providers_create", + "operationId" : "dcim_front-port-templates_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/Provider" } + "schema" : { "$ref" : "#/definitions/WritableFrontPortTemplate" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Provider" } + "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "circuits_providers_bulk_update", + "operationId" : "dcim_front-port-templates_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/Provider" } + "schema" : { "$ref" : "#/definitions/WritableFrontPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Provider" } + "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] } }, - "/circuits/providers/{id}/" : { + "/dcim/front-port-templates/{id}/" : { "delete" : { "description" : "", - "operationId" : "circuits_providers_delete", + "operationId" : "dcim_front-port-templates_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "circuits_providers_read", + "operationId" : "dcim_front-port-templates_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Provider" } + "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this provider.", + "description" : "A unique integer value identifying this front port template.", "in" : "path", "name" : "id", "required" : true, @@ -18847,46 +28918,46 @@ } ], "patch" : { "description" : "", - "operationId" : "circuits_providers_partial_update", + "operationId" : "dcim_front-port-templates_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/Provider" } + "schema" : { "$ref" : "#/definitions/WritableFrontPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Provider" } + "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "circuits_providers_update", + "operationId" : "dcim_front-port-templates_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/Provider" } + "schema" : { "$ref" : "#/definitions/WritableFrontPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Provider" } + "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } } }, - "tags" : [ "circuits" ] + "tags" : [ "dcim" ] } }, - "/dcim/cables/" : { + "/dcim/front-ports/" : { "delete" : { "description" : "", - "operationId" : "dcim_cables_bulk_delete", + "operationId" : "dcim_front-ports_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_cables_list", + "operationId" : "dcim_front-ports_list", "parameters" : [ { "description" : "", @@ -18898,35 +28969,35 @@ { "description" : "", "in" : "query", - "name" : "label", + "name" : "name", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "length", + "name" : "label", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "length_unit", + "name" : "type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_a_id", + "name" : "color", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_b_id", + "name" : "description", "required" : false, "type" : "string" }, @@ -18982,98 +29053,98 @@ { "description" : "", "in" : "query", - "name" : "termination_a_type", + "name" : "region_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_b_type", + "name" : "region", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type", + "name" : "site_group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "status", + "name" : "site_group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color", + "name" : "site_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id", + "name" : "site", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device", + "name" : "location_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "rack_id", + "name" : "location", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "rack", + "name" : "device_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id", + "name" : "device", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site", + "name" : "virtual_chassis_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_id", + "name" : "virtual_chassis", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant", + "name" : "tag", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag", + "name" : "cabled", "required" : false, "type" : "string" }, @@ -19112,6 +29183,76 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "name__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -19185,147 +29326,231 @@ { "description" : "", "in" : "query", - "name" : "length__n", + "name" : "type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "length__lte", + "name" : "color__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "length__lt", + "name" : "color__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "length__gte", + "name" : "color__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "length__gt", + "name" : "color__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "length_unit__n", + "name" : "color__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_a_id__n", + "name" : "color__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_a_id__lte", + "name" : "color__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_a_id__lt", + "name" : "color__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_a_id__gte", + "name" : "color__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_a_id__gt", + "name" : "color__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_b_id__n", + "name" : "description__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_b_id__lte", + "name" : "description__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_b_id__lt", + "name" : "description__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_b_id__gte", + "name" : "description__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_b_id__gt", + "name" : "description__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_a_type__n", + "name" : "description__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "termination_b_type__n", + "name" : "description__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "description__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "status__n", + "name" : "description__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__n", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis__n", "required" : false, "type" : "string" }, @@ -19367,7 +29592,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/Cable" }, + "items" : { "$ref" : "#/definitions/FrontPort" }, "type" : "array" } }, @@ -19383,70 +29608,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_cables_bulk_partial_update", + "operationId" : "dcim_front-ports_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableCable" } + "schema" : { "$ref" : "#/definitions/WritableFrontPort" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Cable" } + "schema" : { "$ref" : "#/definitions/FrontPort" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_cables_create", + "operationId" : "dcim_front-ports_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableCable" } + "schema" : { "$ref" : "#/definitions/WritableFrontPort" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Cable" } + "schema" : { "$ref" : "#/definitions/FrontPort" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_cables_bulk_update", + "operationId" : "dcim_front-ports_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableCable" } + "schema" : { "$ref" : "#/definitions/WritableFrontPort" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Cable" } + "schema" : { "$ref" : "#/definitions/FrontPort" } } }, "tags" : [ "dcim" ] } }, - "/dcim/cables/{id}/" : { + "/dcim/front-ports/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_cables_delete", + "operationId" : "dcim_front-ports_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_cables_read", + "operationId" : "dcim_front-ports_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Cable" } + "schema" : { "$ref" : "#/definitions/FrontPort" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this cable.", + "description" : "A unique integer value identifying this front port.", "in" : "path", "name" : "id", "required" : true, @@ -19454,74 +29679,65 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_cables_partial_update", + "operationId" : "dcim_front-ports_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableCable" } + "schema" : { "$ref" : "#/definitions/WritableFrontPort" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Cable" } + "schema" : { "$ref" : "#/definitions/FrontPort" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_cables_update", + "operationId" : "dcim_front-ports_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableCable" } + "schema" : { "$ref" : "#/definitions/WritableFrontPort" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Cable" } + "schema" : { "$ref" : "#/definitions/FrontPort" } } }, "tags" : [ "dcim" ] } }, - "/dcim/connected-device/" : { + "/dcim/front-ports/{id}/paths/" : { "get" : { - "description" : "This endpoint allows a user to determine what device (if any) is connected to a given peer device and peer\ninterface. This is useful in a situation where a device boots with no configuration, but can detect its neighbors\nvia a protocol such as LLDP. Two query parameters must be included in the request:\n\n* `peer_device`: The name of the peer device\n* `peer_interface`: The name of the peer interface", - "operationId" : "dcim_connected-device_list", - "parameters" : [ - { - "description" : "The name of the peer device", - "in" : "query", - "name" : "peer_device", - "required" : true, - "type" : "string" - }, - { - "description" : "The name of the peer interface", - "in" : "query", - "name" : "peer_interface", - "required" : true, - "type" : "string" - } - ], + "description" : "Return all CablePaths which traverse a given pass-through port.", + "operationId" : "dcim_front-ports_paths", + "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Device" } + "schema" : { "$ref" : "#/definitions/FrontPort" } } }, "tags" : [ "dcim" ] }, - "parameters" : [ ] + "parameters" : [ { + "description" : "A unique integer value identifying this front port.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] }, - "/dcim/console-port-templates/" : { + "/dcim/interface-templates/" : { "delete" : { "description" : "", - "operationId" : "dcim_console-port-templates_bulk_delete", + "operationId" : "dcim_interface-templates_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_console-port-templates_list", + "operationId" : "dcim_interface-templates_list", "parameters" : [ { "description" : "", @@ -19544,6 +29760,13 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "mgmt_only", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -19750,7 +29973,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/ConsolePortTemplate" }, + "items" : { "$ref" : "#/definitions/InterfaceTemplate" }, "type" : "array" } }, @@ -19766,70 +29989,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_console-port-templates_bulk_partial_update", + "operationId" : "dcim_interface-templates_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsolePortTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInterfaceTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_console-port-templates_create", + "operationId" : "dcim_interface-templates_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsolePortTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInterfaceTemplate" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_console-port-templates_bulk_update", + "operationId" : "dcim_interface-templates_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsolePortTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInterfaceTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } } }, "tags" : [ "dcim" ] } }, - "/dcim/console-port-templates/{id}/" : { + "/dcim/interface-templates/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_console-port-templates_delete", + "operationId" : "dcim_interface-templates_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_console-port-templates_read", + "operationId" : "dcim_interface-templates_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this console port template.", + "description" : "A unique integer value identifying this interface template.", "in" : "path", "name" : "id", "required" : true, @@ -19837,46 +30060,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_console-port-templates_partial_update", + "operationId" : "dcim_interface-templates_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsolePortTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInterfaceTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_console-port-templates_update", + "operationId" : "dcim_interface-templates_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsolePortTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInterfaceTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePortTemplate" } + "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } } }, "tags" : [ "dcim" ] } }, - "/dcim/console-ports/" : { + "/dcim/interfaces/" : { "delete" : { "description" : "", - "operationId" : "dcim_console-ports_bulk_delete", + "operationId" : "dcim_interfaces_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_console-ports_list", + "operationId" : "dcim_interfaces_list", "parameters" : [ { "description" : "", @@ -19899,6 +30122,76 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "type", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "enabled", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "mtu", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "mgmt_only", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "mode", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "rf_role", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "rf_channel", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "rf_channel_frequency", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "rf_channel_width", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tx_power", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -20063,7 +30356,56 @@ { "description" : "", "in" : "query", - "name" : "type", + "name" : "kind", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "parent_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "bridge_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "lag_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "mac_address", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "wwn", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "vlan_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "vlan", "required" : false, "type" : "string" }, @@ -20245,542 +30587,462 @@ { "description" : "", "in" : "query", - "name" : "description__n", + "name" : "type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ic", + "name" : "mtu__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nic", + "name" : "mtu__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__iew", + "name" : "mtu__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__niew", + "name" : "mtu__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__isw", + "name" : "mtu__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nisw", + "name" : "mode__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ie", + "name" : "rf_role__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nie", + "name" : "rf_channel__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__empty", + "name" : "rf_channel_frequency__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "rf_channel_frequency__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "rf_channel_frequency__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "rf_channel_frequency__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "rf_channel_frequency__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "rf_channel_width__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "rf_channel_width__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id__n", + "name" : "rf_channel_width__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location__n", + "name" : "rf_channel_width__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id__n", + "name" : "rf_channel_width__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device__n", + "name" : "tx_power__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id__n", + "name" : "tx_power__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis__n", + "name" : "tx_power__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag__n", + "name" : "tx_power__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "tx_power__gt", "required" : false, "type" : "string" }, { - "description" : "Number of results to return per page.", + "description" : "", "in" : "query", - "name" : "limit", + "name" : "description__n", "required" : false, - "type" : "integer" + "type" : "string" }, { - "description" : "The initial index from which to return the results.", + "description" : "", "in" : "query", - "name" : "offset", + "name" : "description__ic", "required" : false, - "type" : "integer" - } - ], - "responses" : { "200" : { - "description" : "", - "schema" : { - "properties" : { - "count" : { "type" : "integer" }, - "next" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "previous" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "results" : { - "items" : { "$ref" : "#/definitions/ConsolePort" }, - "type" : "array" - } - }, - "required" : [ - "count", - "results" - ], - "type" : "object" - } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ ], - "patch" : { - "description" : "", - "operationId" : "dcim_console-ports_bulk_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsolePort" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePort" } - } }, - "tags" : [ "dcim" ] - }, - "post" : { - "description" : "", - "operationId" : "dcim_console-ports_create", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsolePort" } - } ], - "responses" : { "201" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePort" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_console-ports_bulk_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsolePort" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePort" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/console-ports/{id}/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_console-ports_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "", - "operationId" : "dcim_console-ports_read", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePort" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this console port.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ], - "patch" : { - "description" : "", - "operationId" : "dcim_console-ports_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsolePort" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePort" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_console-ports_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsolePort" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePort" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/console-ports/{id}/trace/" : { - "get" : { - "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", - "operationId" : "dcim_console-ports_trace", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsolePort" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this console port.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ] - }, - "/dcim/console-server-port-templates/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_console-server-port-templates_bulk_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_console-server-port-templates_list", - "parameters" : [ + "type" : "string" + }, { "description" : "", "in" : "query", - "name" : "id", + "name" : "description__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name", + "name" : "description__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type", + "name" : "description__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "description__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "description__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "description__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "description__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "description__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "region_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "region__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "devicetype_id", + "name" : "site_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "site_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "site_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "site__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "location_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "location__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "virtual_chassis_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "virtual_chassis__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "tag__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "parent_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "bridge_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "lag_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "mac_address__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "mac_address__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "mac_address__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "mac_address__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "mac_address__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "devicetype_id__n", + "name" : "mac_address__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "mac_address__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "mac_address__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "mac_address__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "wwn__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "wwn__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "wwn__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "wwn__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "wwn__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "wwn__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "wwn__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "wwn__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "wwn__nie", "required" : false, "type" : "string" }, @@ -20815,7 +31077,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" }, + "items" : { "$ref" : "#/definitions/Interface" }, "type" : "array" } }, @@ -20831,70 +31093,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_console-server-port-templates_bulk_partial_update", + "operationId" : "dcim_interfaces_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsoleServerPortTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInterface" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + "schema" : { "$ref" : "#/definitions/Interface" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_console-server-port-templates_create", + "operationId" : "dcim_interfaces_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsoleServerPortTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInterface" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + "schema" : { "$ref" : "#/definitions/Interface" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_console-server-port-templates_bulk_update", + "operationId" : "dcim_interfaces_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsoleServerPortTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInterface" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + "schema" : { "$ref" : "#/definitions/Interface" } } }, "tags" : [ "dcim" ] } }, - "/dcim/console-server-port-templates/{id}/" : { + "/dcim/interfaces/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_console-server-port-templates_delete", + "operationId" : "dcim_interfaces_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_console-server-port-templates_read", + "operationId" : "dcim_interfaces_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + "schema" : { "$ref" : "#/definitions/Interface" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this console server port template.", + "description" : "A unique integer value identifying this interface.", "in" : "path", "name" : "id", "required" : true, @@ -20902,46 +31164,65 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_console-server-port-templates_partial_update", + "operationId" : "dcim_interfaces_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsoleServerPortTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInterface" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + "schema" : { "$ref" : "#/definitions/Interface" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_console-server-port-templates_update", + "operationId" : "dcim_interfaces_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsoleServerPortTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInterface" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPortTemplate" } + "schema" : { "$ref" : "#/definitions/Interface" } } }, "tags" : [ "dcim" ] } }, - "/dcim/console-server-ports/" : { + "/dcim/interfaces/{id}/trace/" : { + "get" : { + "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", + "operationId" : "dcim_interfaces_trace", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/Interface" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this interface.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] + }, + "/dcim/inventory-items/" : { "delete" : { "description" : "", - "operationId" : "dcim_console-server-ports_bulk_delete", + "operationId" : "dcim_inventory-items_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_console-server-ports_list", + "operationId" : "dcim_inventory-items_list", "parameters" : [ { "description" : "", @@ -20967,7 +31248,21 @@ { "description" : "", "in" : "query", - "name" : "description", + "name" : "part_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "asset_tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "discovered", "required" : false, "type" : "string" }, @@ -21114,21 +31409,28 @@ { "description" : "", "in" : "query", - "name" : "cabled", + "name" : "parent_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "connected", + "name" : "manufacturer_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type", + "name" : "manufacturer", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "serial", "required" : false, "type" : "string" }, @@ -21310,528 +31612,252 @@ { "description" : "", "in" : "query", - "name" : "description__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "description__ic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "description__nic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "description__iew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "description__niew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "description__isw", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "description__nisw", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "description__ie", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "description__nie", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "description__empty", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "region_id__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "region__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_group_id__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_group__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_id__n", + "name" : "part_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "part_id__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id__n", + "name" : "part_id__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location__n", + "name" : "part_id__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id__n", + "name" : "part_id__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device__n", + "name" : "part_id__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id__n", + "name" : "part_id__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis__n", + "name" : "part_id__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag__n", + "name" : "part_id__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "part_id__empty", "required" : false, "type" : "string" }, - { - "description" : "Number of results to return per page.", - "in" : "query", - "name" : "limit", - "required" : false, - "type" : "integer" - }, - { - "description" : "The initial index from which to return the results.", - "in" : "query", - "name" : "offset", - "required" : false, - "type" : "integer" - } - ], - "responses" : { "200" : { - "description" : "", - "schema" : { - "properties" : { - "count" : { "type" : "integer" }, - "next" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "previous" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "results" : { - "items" : { "$ref" : "#/definitions/ConsoleServerPort" }, - "type" : "array" - } - }, - "required" : [ - "count", - "results" - ], - "type" : "object" - } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ ], - "patch" : { - "description" : "", - "operationId" : "dcim_console-server-ports_bulk_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsoleServerPort" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } - } }, - "tags" : [ "dcim" ] - }, - "post" : { - "description" : "", - "operationId" : "dcim_console-server-ports_create", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsoleServerPort" } - } ], - "responses" : { "201" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_console-server-ports_bulk_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsoleServerPort" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/console-server-ports/{id}/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_console-server-ports_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "", - "operationId" : "dcim_console-server-ports_read", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this console server port.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ], - "patch" : { - "description" : "", - "operationId" : "dcim_console-server-ports_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsoleServerPort" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_console-server-ports_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableConsoleServerPort" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/console-server-ports/{id}/trace/" : { - "get" : { - "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", - "operationId" : "dcim_console-server-ports_trace", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/ConsoleServerPort" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this console server port.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ] - }, - "/dcim/device-bay-templates/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_device-bay-templates_bulk_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_device-bay-templates_list", - "parameters" : [ { "description" : "", "in" : "query", - "name" : "id", + "name" : "asset_tag__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name", + "name" : "asset_tag__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "asset_tag__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "asset_tag__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "asset_tag__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "asset_tag__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "asset_tag__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "asset_tag__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "asset_tag__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "devicetype_id", + "name" : "asset_tag__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "region_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "region__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "site_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "site_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "site_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "site__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "location_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "location__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "device_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "device__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "virtual_chassis_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "virtual_chassis__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "tag__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "parent_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "manufacturer_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "devicetype_id__n", + "name" : "manufacturer__n", "required" : false, "type" : "string" }, @@ -21866,7 +31892,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/DeviceBayTemplate" }, + "items" : { "$ref" : "#/definitions/InventoryItem" }, "type" : "array" } }, @@ -21882,70 +31908,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_device-bay-templates_bulk_partial_update", + "operationId" : "dcim_inventory-items_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceBayTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInventoryItem" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + "schema" : { "$ref" : "#/definitions/InventoryItem" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_device-bay-templates_create", + "operationId" : "dcim_inventory-items_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceBayTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInventoryItem" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + "schema" : { "$ref" : "#/definitions/InventoryItem" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_device-bay-templates_bulk_update", + "operationId" : "dcim_inventory-items_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceBayTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInventoryItem" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + "schema" : { "$ref" : "#/definitions/InventoryItem" } } }, "tags" : [ "dcim" ] } }, - "/dcim/device-bay-templates/{id}/" : { + "/dcim/inventory-items/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_device-bay-templates_delete", + "operationId" : "dcim_inventory-items_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_device-bay-templates_read", + "operationId" : "dcim_inventory-items_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + "schema" : { "$ref" : "#/definitions/InventoryItem" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this device bay template.", + "description" : "A unique integer value identifying this inventory item.", "in" : "path", "name" : "id", "required" : true, @@ -21953,46 +31979,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_device-bay-templates_partial_update", + "operationId" : "dcim_inventory-items_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceBayTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInventoryItem" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + "schema" : { "$ref" : "#/definitions/InventoryItem" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_device-bay-templates_update", + "operationId" : "dcim_inventory-items_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceBayTemplate" } + "schema" : { "$ref" : "#/definitions/WritableInventoryItem" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBayTemplate" } + "schema" : { "$ref" : "#/definitions/InventoryItem" } } }, "tags" : [ "dcim" ] } }, - "/dcim/device-bays/" : { + "/dcim/locations/" : { "delete" : { "description" : "", - "operationId" : "dcim_device-bays_bulk_delete", + "operationId" : "dcim_locations_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_device-bays_list", + "operationId" : "dcim_locations_list", "parameters" : [ { "description" : "", @@ -22011,7 +32037,7 @@ { "description" : "", "in" : "query", - "name" : "label", + "name" : "slug", "required" : false, "type" : "string" }, @@ -22025,133 +32051,147 @@ { "description" : "", "in" : "query", - "name" : "created", + "name" : "tenant_group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "tenant_group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "tenant_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "tenant", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "contact", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "contact_role", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "created", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id", + "name" : "created__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region", + "name" : "created__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id", + "name" : "last_updated", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group", + "name" : "last_updated__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id", + "name" : "last_updated__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id", + "name" : "region_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location", + "name" : "region", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id", + "name" : "site_group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device", + "name" : "site_group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id", + "name" : "site_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis", + "name" : "site", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "parent_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "parent", "required" : false, "type" : "string" }, @@ -22270,70 +32310,70 @@ { "description" : "", "in" : "query", - "name" : "label__n", + "name" : "slug__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__ic", + "name" : "slug__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nic", + "name" : "slug__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__iew", + "name" : "slug__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__niew", + "name" : "slug__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__isw", + "name" : "slug__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nisw", + "name" : "slug__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__ie", + "name" : "slug__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nie", + "name" : "slug__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__empty", + "name" : "slug__empty", "required" : false, "type" : "string" }, @@ -22407,6 +32447,48 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact_role__n", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -22452,42 +32534,14 @@ { "description" : "", "in" : "query", - "name" : "location_id__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "location__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "device_id__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "device__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "virtual_chassis_id__n", + "name" : "parent_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis__n", + "name" : "parent__n", "required" : false, "type" : "string" }, @@ -22529,7 +32583,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/DeviceBay" }, + "items" : { "$ref" : "#/definitions/Location" }, "type" : "array" } }, @@ -22545,70 +32599,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_device-bays_bulk_partial_update", + "operationId" : "dcim_locations_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceBay" } + "schema" : { "$ref" : "#/definitions/WritableLocation" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBay" } + "schema" : { "$ref" : "#/definitions/Location" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_device-bays_create", + "operationId" : "dcim_locations_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceBay" } + "schema" : { "$ref" : "#/definitions/WritableLocation" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBay" } + "schema" : { "$ref" : "#/definitions/Location" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_device-bays_bulk_update", + "operationId" : "dcim_locations_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceBay" } + "schema" : { "$ref" : "#/definitions/WritableLocation" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBay" } + "schema" : { "$ref" : "#/definitions/Location" } } }, "tags" : [ "dcim" ] } }, - "/dcim/device-bays/{id}/" : { + "/dcim/locations/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_device-bays_delete", + "operationId" : "dcim_locations_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_device-bays_read", + "operationId" : "dcim_locations_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBay" } + "schema" : { "$ref" : "#/definitions/Location" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this device bay.", + "description" : "A unique integer value identifying this location.", "in" : "path", "name" : "id", "required" : true, @@ -22616,46 +32670,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_device-bays_partial_update", + "operationId" : "dcim_locations_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceBay" } + "schema" : { "$ref" : "#/definitions/WritableLocation" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBay" } + "schema" : { "$ref" : "#/definitions/Location" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_device-bays_update", + "operationId" : "dcim_locations_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceBay" } + "schema" : { "$ref" : "#/definitions/WritableLocation" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceBay" } + "schema" : { "$ref" : "#/definitions/Location" } } }, "tags" : [ "dcim" ] } }, - "/dcim/device-roles/" : { + "/dcim/manufacturers/" : { "delete" : { "description" : "", - "operationId" : "dcim_device-roles_bulk_delete", + "operationId" : "dcim_manufacturers_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_device-roles_list", + "operationId" : "dcim_manufacturers_list", "parameters" : [ { "description" : "", @@ -22681,14 +32735,7 @@ { "description" : "", "in" : "query", - "name" : "color", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "vm_role", + "name" : "description", "required" : false, "type" : "string" }, @@ -22741,6 +32788,27 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "contact", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact_role", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -22919,70 +32987,91 @@ { "description" : "", "in" : "query", - "name" : "color__n", + "name" : "description__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__ic", + "name" : "description__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nic", + "name" : "description__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__iew", + "name" : "description__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__niew", + "name" : "description__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__isw", + "name" : "description__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nisw", + "name" : "description__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__ie", + "name" : "description__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nie", + "name" : "description__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__empty", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact_role__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", "required" : false, "type" : "string" }, @@ -23017,7 +33106,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/DeviceRole" }, + "items" : { "$ref" : "#/definitions/Manufacturer" }, "type" : "array" } }, @@ -23033,70 +33122,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_device-roles_bulk_partial_update", + "operationId" : "dcim_manufacturers_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/DeviceRole" } + "schema" : { "$ref" : "#/definitions/Manufacturer" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceRole" } + "schema" : { "$ref" : "#/definitions/Manufacturer" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_device-roles_create", + "operationId" : "dcim_manufacturers_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/DeviceRole" } + "schema" : { "$ref" : "#/definitions/Manufacturer" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceRole" } + "schema" : { "$ref" : "#/definitions/Manufacturer" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_device-roles_bulk_update", + "operationId" : "dcim_manufacturers_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/DeviceRole" } + "schema" : { "$ref" : "#/definitions/Manufacturer" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceRole" } + "schema" : { "$ref" : "#/definitions/Manufacturer" } } }, "tags" : [ "dcim" ] } }, - "/dcim/device-roles/{id}/" : { + "/dcim/manufacturers/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_device-roles_delete", + "operationId" : "dcim_manufacturers_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_device-roles_read", + "operationId" : "dcim_manufacturers_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceRole" } + "schema" : { "$ref" : "#/definitions/Manufacturer" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this device role.", + "description" : "A unique integer value identifying this manufacturer.", "in" : "path", "name" : "id", "required" : true, @@ -23104,46 +33193,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_device-roles_partial_update", + "operationId" : "dcim_manufacturers_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/DeviceRole" } + "schema" : { "$ref" : "#/definitions/Manufacturer" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceRole" } + "schema" : { "$ref" : "#/definitions/Manufacturer" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_device-roles_update", + "operationId" : "dcim_manufacturers_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/DeviceRole" } + "schema" : { "$ref" : "#/definitions/Manufacturer" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceRole" } + "schema" : { "$ref" : "#/definitions/Manufacturer" } } }, "tags" : [ "dcim" ] } }, - "/dcim/device-types/" : { + "/dcim/platforms/" : { "delete" : { "description" : "", - "operationId" : "dcim_device-types_bulk_delete", + "operationId" : "dcim_platforms_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_device-types_list", + "operationId" : "dcim_platforms_list", "parameters" : [ { "description" : "", @@ -23155,7 +33244,7 @@ { "description" : "", "in" : "query", - "name" : "model", + "name" : "name", "required" : false, "type" : "string" }, @@ -23169,28 +33258,14 @@ { "description" : "", "in" : "query", - "name" : "part_number", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "u_height", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "is_full_depth", + "name" : "napalm_driver", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "subdevice_role", + "name" : "description", "required" : false, "type" : "string" }, @@ -23257,55 +33332,6 @@ "required" : false, "type" : "string" }, - { - "description" : "", - "in" : "query", - "name" : "console_ports", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "console_server_ports", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "power_ports", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "power_outlets", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "interfaces", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "pass_through_ports", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "device_bays", - "required" : false, - "type" : "string" - }, { "description" : "", "in" : "query", @@ -23351,70 +33377,70 @@ { "description" : "", "in" : "query", - "name" : "model__n", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "model__ic", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "model__nic", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "model__iew", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "model__niew", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "model__isw", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "model__nisw", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "model__ie", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "model__nie", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "model__empty", + "name" : "name__empty", "required" : false, "type" : "string" }, @@ -23491,112 +33517,140 @@ { "description" : "", "in" : "query", - "name" : "part_number__n", + "name" : "napalm_driver__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_number__ic", + "name" : "napalm_driver__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_number__nic", + "name" : "napalm_driver__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_number__iew", + "name" : "napalm_driver__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_number__niew", + "name" : "napalm_driver__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_number__isw", + "name" : "napalm_driver__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_number__nisw", + "name" : "napalm_driver__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_number__ie", + "name" : "napalm_driver__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_number__nie", + "name" : "napalm_driver__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_number__empty", + "name" : "napalm_driver__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "u_height__n", + "name" : "description__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "u_height__lte", + "name" : "description__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "u_height__lt", + "name" : "description__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "u_height__gte", + "name" : "description__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "u_height__gt", + "name" : "description__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "subdevice_role__n", + "name" : "description__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__empty", "required" : false, "type" : "string" }, @@ -23652,7 +33706,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/DeviceType" }, + "items" : { "$ref" : "#/definitions/Platform" }, "type" : "array" } }, @@ -23668,70 +33722,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_device-types_bulk_partial_update", + "operationId" : "dcim_platforms_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceType" } + "schema" : { "$ref" : "#/definitions/WritablePlatform" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceType" } + "schema" : { "$ref" : "#/definitions/Platform" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_device-types_create", + "operationId" : "dcim_platforms_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceType" } + "schema" : { "$ref" : "#/definitions/WritablePlatform" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceType" } + "schema" : { "$ref" : "#/definitions/Platform" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_device-types_bulk_update", + "operationId" : "dcim_platforms_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceType" } + "schema" : { "$ref" : "#/definitions/WritablePlatform" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceType" } + "schema" : { "$ref" : "#/definitions/Platform" } } }, "tags" : [ "dcim" ] } }, - "/dcim/device-types/{id}/" : { + "/dcim/platforms/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_device-types_delete", + "operationId" : "dcim_platforms_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_device-types_read", + "operationId" : "dcim_platforms_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceType" } + "schema" : { "$ref" : "#/definitions/Platform" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this device type.", + "description" : "A unique integer value identifying this platform.", "in" : "path", "name" : "id", "required" : true, @@ -23739,46 +33793,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_device-types_partial_update", + "operationId" : "dcim_platforms_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceType" } + "schema" : { "$ref" : "#/definitions/WritablePlatform" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceType" } + "schema" : { "$ref" : "#/definitions/Platform" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_device-types_update", + "operationId" : "dcim_platforms_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceType" } + "schema" : { "$ref" : "#/definitions/WritablePlatform" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceType" } + "schema" : { "$ref" : "#/definitions/Platform" } } }, "tags" : [ "dcim" ] } }, - "/dcim/devices/" : { + "/dcim/power-feeds/" : { "delete" : { "description" : "", - "operationId" : "dcim_devices_bulk_delete", + "operationId" : "dcim_power-feeds_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_devices_list", + "operationId" : "dcim_power-feeds_list", "parameters" : [ { "description" : "", @@ -23797,112 +33851,105 @@ { "description" : "", "in" : "query", - "name" : "asset_tag", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "face", + "name" : "status", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "position", + "name" : "type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_position", + "name" : "supply", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_priority", + "name" : "phase", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "voltage", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "amperage", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "max_utilization", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "created", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "created__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "created__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group_id", + "name" : "last_updated", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group", + "name" : "last_updated__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_id", + "name" : "last_updated__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant", + "name" : "cabled", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "local_context_data", + "name" : "connected", "required" : false, "type" : "string" }, @@ -23913,55 +33960,6 @@ "required" : false, "type" : "string" }, - { - "description" : "", - "in" : "query", - "name" : "manufacturer_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "manufacturer", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "device_type_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "role_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "role", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "platform_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "platform", - "required" : false, - "type" : "string" - }, { "description" : "", "in" : "query", @@ -24007,7 +34005,7 @@ { "description" : "", "in" : "query", - "name" : "location_id", + "name" : "power_panel_id", "required" : false, "type" : "string" }, @@ -24018,118 +34016,6 @@ "required" : false, "type" : "string" }, - { - "description" : "", - "in" : "query", - "name" : "cluster_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "model", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "status", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "is_full_depth", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "mac_address", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "serial", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "has_primary_ip", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "virtual_chassis_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "virtual_chassis_member", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "console_ports", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "console_server_ports", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "power_ports", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "power_outlets", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "interfaces", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "pass_through_ports", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "device_bays", - "required" : false, - "type" : "string" - }, { "description" : "", "in" : "query", @@ -24245,413 +34131,584 @@ { "description" : "", "in" : "query", - "name" : "asset_tag__n", + "name" : "status__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__ic", + "name" : "type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__nic", + "name" : "supply__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__iew", + "name" : "phase__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__niew", + "name" : "voltage__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__isw", + "name" : "voltage__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__nisw", + "name" : "voltage__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__ie", + "name" : "voltage__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__nie", + "name" : "voltage__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__empty", + "name" : "amperage__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "face__n", + "name" : "amperage__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "position__n", + "name" : "amperage__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "position__lte", + "name" : "amperage__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "position__lt", + "name" : "amperage__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "position__gte", + "name" : "max_utilization__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "position__gt", + "name" : "max_utilization__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_position__n", + "name" : "max_utilization__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_position__lte", + "name" : "max_utilization__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_position__lt", + "name" : "max_utilization__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_position__gte", + "name" : "region_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_position__gt", + "name" : "region__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_priority__n", + "name" : "site_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_priority__lte", + "name" : "site_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_priority__lt", + "name" : "site_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_priority__gte", + "name" : "site__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vc_priority__gt", + "name" : "power_panel_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group_id__n", + "name" : "rack_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group__n", + "name" : "tag__n", "required" : false, "type" : "string" }, { - "description" : "", + "description" : "Number of results to return per page.", "in" : "query", - "name" : "tenant_id__n", + "name" : "limit", "required" : false, - "type" : "string" + "type" : "integer" }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/PowerFeed" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_power-feeds_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerFeed" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerFeed" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_power-feeds_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerFeed" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerFeed" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_power-feeds_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerFeed" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerFeed" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/power-feeds/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_power-feeds_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_power-feeds_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerFeed" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this power feed.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_power-feeds_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerFeed" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerFeed" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_power-feeds_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerFeed" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerFeed" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/power-feeds/{id}/trace/" : { + "get" : { + "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", + "operationId" : "dcim_power-feeds_trace", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerFeed" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this power feed.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] + }, + "/dcim/power-outlet-templates/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_power-outlet-templates_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_power-outlet-templates_list", + "parameters" : [ { "description" : "", "in" : "query", - "name" : "tenant__n", + "name" : "id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "manufacturer_id__n", + "name" : "name", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "manufacturer__n", + "name" : "type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_type_id__n", + "name" : "feed_leg", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "role_id__n", + "name" : "created", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "role__n", + "name" : "created__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "platform_id__n", + "name" : "created__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "platform__n", + "name" : "last_updated", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "last_updated__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "last_updated__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "devicetype_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id__n", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "rack_id__n", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cluster_id__n", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "model__n", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "status__n", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__n", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__ic", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__nic", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__iew", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__niew", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__isw", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__nisw", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__ie", + "name" : "name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__nie", + "name" : "type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id__n", + "name" : "feed_leg__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag__n", + "name" : "devicetype_id__n", "required" : false, "type" : "string" }, @@ -24686,7 +34743,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/DeviceWithConfigContext" }, + "items" : { "$ref" : "#/definitions/PowerOutletTemplate" }, "type" : "array" } }, @@ -24702,70 +34759,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_devices_bulk_partial_update", + "operationId" : "dcim_power-outlet-templates_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceWithConfigContext" } + "schema" : { "$ref" : "#/definitions/WritablePowerOutletTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } + "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_devices_create", + "operationId" : "dcim_power-outlet-templates_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceWithConfigContext" } + "schema" : { "$ref" : "#/definitions/WritablePowerOutletTemplate" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } + "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_devices_bulk_update", + "operationId" : "dcim_power-outlet-templates_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceWithConfigContext" } + "schema" : { "$ref" : "#/definitions/WritablePowerOutletTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } + "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } } }, "tags" : [ "dcim" ] } }, - "/dcim/devices/{id}/" : { + "/dcim/power-outlet-templates/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_devices_delete", + "operationId" : "dcim_power-outlet-templates_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_devices_read", + "operationId" : "dcim_power-outlet-templates_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } + "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this device.", + "description" : "A unique integer value identifying this power outlet template.", "in" : "path", "name" : "id", "required" : true, @@ -24773,70 +34830,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_devices_partial_update", + "operationId" : "dcim_power-outlet-templates_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceWithConfigContext" } + "schema" : { "$ref" : "#/definitions/WritablePowerOutletTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } + "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_devices_update", + "operationId" : "dcim_power-outlet-templates_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableDeviceWithConfigContext" } + "schema" : { "$ref" : "#/definitions/WritablePowerOutletTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceWithConfigContext" } + "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } } }, "tags" : [ "dcim" ] } }, - "/dcim/devices/{id}/napalm/" : { - "get" : { - "description" : "Execute a NAPALM method on a Device", - "operationId" : "dcim_devices_napalm", - "parameters" : [ { - "in" : "query", - "name" : "method", - "required" : true, - "type" : "string" - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/DeviceNAPALM" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this device.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ] - }, - "/dcim/front-port-templates/" : { + "/dcim/power-outlets/" : { "delete" : { "description" : "", - "operationId" : "dcim_front-port-templates_bulk_delete", + "operationId" : "dcim_power-outlets_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_front-port-templates_list", + "operationId" : "dcim_power-outlets_list", "parameters" : [ { "description" : "", @@ -24855,14 +34888,21 @@ { "description" : "", "in" : "query", - "name" : "type", + "name" : "label", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color", + "name" : "feed_leg", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description", "required" : false, "type" : "string" }, @@ -24918,7 +34958,112 @@ { "description" : "", "in" : "query", - "name" : "devicetype_id", + "name" : "region_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cabled", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "connected", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type", "required" : false, "type" : "string" }, @@ -25030,84 +35175,245 @@ { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "label__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__n", + "name" : "label__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__ic", + "name" : "label__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nic", + "name" : "label__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__iew", + "name" : "label__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__niew", + "name" : "label__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__isw", + "name" : "label__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nisw", + "name" : "label__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__ie", + "name" : "label__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nie", + "name" : "label__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__empty", + "name" : "feed_leg__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "devicetype_id__n", + "name" : "description__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "location__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "virtual_chassis__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "type__n", "required" : false, "type" : "string" }, @@ -25142,7 +35448,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/FrontPortTemplate" }, + "items" : { "$ref" : "#/definitions/PowerOutlet" }, "type" : "array" } }, @@ -25158,70 +35464,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_front-port-templates_bulk_partial_update", + "operationId" : "dcim_power-outlets_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableFrontPortTemplate" } + "schema" : { "$ref" : "#/definitions/WritablePowerOutlet" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } + "schema" : { "$ref" : "#/definitions/PowerOutlet" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_front-port-templates_create", + "operationId" : "dcim_power-outlets_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableFrontPortTemplate" } + "schema" : { "$ref" : "#/definitions/WritablePowerOutlet" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } + "schema" : { "$ref" : "#/definitions/PowerOutlet" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_front-port-templates_bulk_update", + "operationId" : "dcim_power-outlets_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableFrontPortTemplate" } + "schema" : { "$ref" : "#/definitions/WritablePowerOutlet" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } + "schema" : { "$ref" : "#/definitions/PowerOutlet" } } }, "tags" : [ "dcim" ] } }, - "/dcim/front-port-templates/{id}/" : { + "/dcim/power-outlets/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_front-port-templates_delete", + "operationId" : "dcim_power-outlets_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_front-port-templates_read", + "operationId" : "dcim_power-outlets_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } + "schema" : { "$ref" : "#/definitions/PowerOutlet" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this front port template.", + "description" : "A unique integer value identifying this power outlet.", "in" : "path", "name" : "id", "required" : true, @@ -25229,46 +35535,65 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_front-port-templates_partial_update", + "operationId" : "dcim_power-outlets_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableFrontPortTemplate" } + "schema" : { "$ref" : "#/definitions/WritablePowerOutlet" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } + "schema" : { "$ref" : "#/definitions/PowerOutlet" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_front-port-templates_update", + "operationId" : "dcim_power-outlets_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableFrontPortTemplate" } + "schema" : { "$ref" : "#/definitions/WritablePowerOutlet" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPortTemplate" } + "schema" : { "$ref" : "#/definitions/PowerOutlet" } } }, "tags" : [ "dcim" ] } }, - "/dcim/front-ports/" : { + "/dcim/power-outlets/{id}/trace/" : { + "get" : { + "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", + "operationId" : "dcim_power-outlets_trace", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerOutlet" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this power outlet.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] + }, + "/dcim/power-panels/" : { "delete" : { "description" : "", - "operationId" : "dcim_front-ports_bulk_delete", + "operationId" : "dcim_power-panels_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_front-ports_list", + "operationId" : "dcim_power-panels_list", "parameters" : [ { "description" : "", @@ -25287,70 +35612,56 @@ { "description" : "", "in" : "query", - "name" : "label", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "type", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "color", + "name" : "created", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description", + "name" : "created__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "created__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "last_updated", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "last_updated__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "last_updated__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "contact", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "contact_role", "required" : false, "type" : "string" }, @@ -25413,462 +35724,621 @@ { "description" : "", "in" : "query", - "name" : "location", + "name" : "tag", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cabled", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "contact__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "contact_role__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "region_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "region__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "site_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "site_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__n", + "name" : "site_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__ic", + "name" : "site__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nic", + "name" : "location_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__iew", + "name" : "tag__n", "required" : false, "type" : "string" }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/PowerPanel" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_power-panels_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerPanel" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPanel" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_power-panels_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerPanel" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPanel" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_power-panels_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerPanel" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPanel" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/power-panels/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_power-panels_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_power-panels_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPanel" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this power panel.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_power-panels_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerPanel" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPanel" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_power-panels_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerPanel" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPanel" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/power-port-templates/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_power-port-templates_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_power-port-templates_list", + "parameters" : [ { "description" : "", "in" : "query", - "name" : "label__niew", + "name" : "id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__isw", + "name" : "name", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nisw", + "name" : "type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__ie", + "name" : "maximum_draw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nie", + "name" : "allocated_draw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__empty", + "name" : "created", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "created__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__n", + "name" : "created__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__ic", + "name" : "last_updated", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nic", + "name" : "last_updated__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__iew", + "name" : "last_updated__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__niew", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__isw", + "name" : "devicetype_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nisw", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__ie", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nie", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__empty", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__n", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ic", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nic", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__iew", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__niew", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__isw", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nisw", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ie", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nie", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__empty", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "maximum_draw__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "maximum_draw__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "maximum_draw__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "maximum_draw__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id__n", + "name" : "maximum_draw__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location__n", + "name" : "allocated_draw__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id__n", + "name" : "allocated_draw__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device__n", + "name" : "allocated_draw__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id__n", + "name" : "allocated_draw__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis__n", + "name" : "allocated_draw__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag__n", + "name" : "devicetype_id__n", "required" : false, "type" : "string" }, @@ -25903,7 +36373,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/FrontPort" }, + "items" : { "$ref" : "#/definitions/PowerPortTemplate" }, "type" : "array" } }, @@ -25919,70 +36389,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_front-ports_bulk_partial_update", + "operationId" : "dcim_power-port-templates_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableFrontPort" } + "schema" : { "$ref" : "#/definitions/WritablePowerPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPort" } + "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_front-ports_create", + "operationId" : "dcim_power-port-templates_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableFrontPort" } + "schema" : { "$ref" : "#/definitions/WritablePowerPortTemplate" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPort" } + "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_front-ports_bulk_update", + "operationId" : "dcim_power-port-templates_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableFrontPort" } + "schema" : { "$ref" : "#/definitions/WritablePowerPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPort" } + "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } } }, "tags" : [ "dcim" ] } }, - "/dcim/front-ports/{id}/" : { + "/dcim/power-port-templates/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_front-ports_delete", + "operationId" : "dcim_power-port-templates_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_front-ports_read", + "operationId" : "dcim_power-port-templates_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPort" } + "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this front port.", + "description" : "A unique integer value identifying this power port template.", "in" : "path", "name" : "id", "required" : true, @@ -25990,91 +36460,86 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_front-ports_partial_update", + "operationId" : "dcim_power-port-templates_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableFrontPort" } + "schema" : { "$ref" : "#/definitions/WritablePowerPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPort" } + "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_front-ports_update", + "operationId" : "dcim_power-port-templates_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableFrontPort" } + "schema" : { "$ref" : "#/definitions/WritablePowerPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPort" } + "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } } }, "tags" : [ "dcim" ] } }, - "/dcim/front-ports/{id}/paths/" : { - "get" : { - "description" : "Return all CablePaths which traverse a given pass-through port.", - "operationId" : "dcim_front-ports_paths", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/FrontPort" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this front port.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ] - }, - "/dcim/interface-templates/" : { + "/dcim/power-ports/" : { "delete" : { "description" : "", - "operationId" : "dcim_interface-templates_bulk_delete", + "operationId" : "dcim_power-ports_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_interface-templates_list", + "operationId" : "dcim_power-ports_list", "parameters" : [ { "description" : "", "in" : "query", - "name" : "id", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name", + "name" : "label", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type", + "name" : "maximum_draw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mgmt_only", + "name" : "allocated_draw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description", "required" : false, "type" : "string" }, @@ -26130,992 +36595,1039 @@ { "description" : "", "in" : "query", - "name" : "devicetype_id", + "name" : "region_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "region", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "site_group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "site_group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "site_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "site", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "location_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "location", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "device_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "device", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "virtual_chassis_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "virtual_chassis", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "tag", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "cabled", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "connected", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "devicetype_id__n", + "name" : "id__lte", "required" : false, "type" : "string" }, { - "description" : "Number of results to return per page.", + "description" : "", "in" : "query", - "name" : "limit", + "name" : "id__lt", "required" : false, - "type" : "integer" + "type" : "string" }, { - "description" : "The initial index from which to return the results.", + "description" : "", "in" : "query", - "name" : "offset", + "name" : "id__gte", "required" : false, - "type" : "integer" - } - ], - "responses" : { "200" : { - "description" : "", - "schema" : { - "properties" : { - "count" : { "type" : "integer" }, - "next" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "previous" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "results" : { - "items" : { "$ref" : "#/definitions/InterfaceTemplate" }, - "type" : "array" - } - }, - "required" : [ - "count", - "results" - ], - "type" : "object" - } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ ], - "patch" : { - "description" : "", - "operationId" : "dcim_interface-templates_bulk_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInterfaceTemplate" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } - } }, - "tags" : [ "dcim" ] - }, - "post" : { - "description" : "", - "operationId" : "dcim_interface-templates_create", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInterfaceTemplate" } - } ], - "responses" : { "201" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_interface-templates_bulk_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInterfaceTemplate" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/interface-templates/{id}/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_interface-templates_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "", - "operationId" : "dcim_interface-templates_read", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this interface template.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ], - "patch" : { - "description" : "", - "operationId" : "dcim_interface-templates_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInterfaceTemplate" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_interface-templates_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInterfaceTemplate" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/InterfaceTemplate" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/interfaces/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_interfaces_bulk_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_interfaces_list", - "parameters" : [ + "type" : "string" + }, { "description" : "", "in" : "query", - "name" : "id", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "enabled", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mtu", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mgmt_only", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mode", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "label__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "label__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "label__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "label__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "label__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id", + "name" : "label__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region", + "name" : "label__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id", + "name" : "label__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group", + "name" : "label__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id", + "name" : "label__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site", + "name" : "maximum_draw__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id", + "name" : "maximum_draw__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location", + "name" : "maximum_draw__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id", + "name" : "maximum_draw__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device", + "name" : "maximum_draw__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id", + "name" : "allocated_draw__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis", + "name" : "allocated_draw__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag", + "name" : "allocated_draw__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cabled", + "name" : "allocated_draw__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "connected", + "name" : "allocated_draw__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "kind", + "name" : "description__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "parent_id", + "name" : "description__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "lag_id", + "name" : "description__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address", + "name" : "description__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vlan_id", + "name" : "description__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "vlan", + "name" : "description__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "description__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "description__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "description__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "description__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "region_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "region__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "site_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "site_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "site_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "site__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "location_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "location__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "device_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "device__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "virtual_chassis_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__n", + "name" : "virtual_chassis__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__ic", + "name" : "tag__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nic", + "name" : "type__n", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/PowerPort" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "dcim_power-ports_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerPort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPort" } + } }, + "tags" : [ "dcim" ] + }, + "post" : { + "description" : "", + "operationId" : "dcim_power-ports_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerPort" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPort" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_power-ports_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerPort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPort" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/power-ports/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_power-ports_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "", + "operationId" : "dcim_power-ports_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPort" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this power port.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "dcim_power-ports_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerPort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPort" } + } }, + "tags" : [ "dcim" ] + }, + "put" : { + "description" : "", + "operationId" : "dcim_power-ports_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritablePowerPort" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPort" } + } }, + "tags" : [ "dcim" ] + } + }, + "/dcim/power-ports/{id}/trace/" : { + "get" : { + "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", + "operationId" : "dcim_power-ports_trace", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/PowerPort" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this power port.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] + }, + "/dcim/rack-reservations/" : { + "delete" : { + "description" : "", + "operationId" : "dcim_rack-reservations_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "dcim" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "dcim_rack-reservations_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "created", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__iew", + "name" : "description", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__niew", + "name" : "created__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__isw", + "name" : "created__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nisw", + "name" : "last_updated", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__ie", + "name" : "last_updated__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nie", + "name" : "last_updated__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__empty", + "name" : "tenant_group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "tenant_group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mtu__n", + "name" : "tenant_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mtu__lte", + "name" : "tenant", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mtu__lt", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mtu__gte", + "name" : "rack_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mtu__gt", + "name" : "site_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mode__n", + "name" : "site", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__n", + "name" : "location_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ic", + "name" : "location", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nic", + "name" : "user_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__iew", + "name" : "user", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__niew", + "name" : "tag", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__isw", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nisw", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ie", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nie", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__empty", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "description__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "description__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "description__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "description__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "description__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "description__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id__n", + "name" : "description__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location__n", + "name" : "description__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id__n", + "name" : "description__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis__n", + "name" : "description__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag__n", + "name" : "tenant_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "parent_id__n", + "name" : "tenant_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "lag_id__n", + "name" : "tenant_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__n", + "name" : "tenant__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__ic", + "name" : "rack_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__nic", + "name" : "site_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__iew", + "name" : "site__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__niew", + "name" : "location_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__isw", + "name" : "location__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__nisw", + "name" : "user_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__ie", + "name" : "user__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "mac_address__nie", + "name" : "tag__n", "required" : false, "type" : "string" }, @@ -27150,7 +37662,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/Interface" }, + "items" : { "$ref" : "#/definitions/RackReservation" }, "type" : "array" } }, @@ -27166,70 +37678,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_interfaces_bulk_partial_update", + "operationId" : "dcim_rack-reservations_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInterface" } + "schema" : { "$ref" : "#/definitions/WritableRackReservation" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Interface" } + "schema" : { "$ref" : "#/definitions/RackReservation" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_interfaces_create", + "operationId" : "dcim_rack-reservations_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInterface" } + "schema" : { "$ref" : "#/definitions/WritableRackReservation" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Interface" } + "schema" : { "$ref" : "#/definitions/RackReservation" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_interfaces_bulk_update", + "operationId" : "dcim_rack-reservations_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInterface" } + "schema" : { "$ref" : "#/definitions/WritableRackReservation" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Interface" } + "schema" : { "$ref" : "#/definitions/RackReservation" } } }, "tags" : [ "dcim" ] } }, - "/dcim/interfaces/{id}/" : { + "/dcim/rack-reservations/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_interfaces_delete", + "operationId" : "dcim_rack-reservations_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_interfaces_read", + "operationId" : "dcim_rack-reservations_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Interface" } + "schema" : { "$ref" : "#/definitions/RackReservation" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this interface.", + "description" : "A unique integer value identifying this rack reservation.", "in" : "path", "name" : "id", "required" : true, @@ -27237,65 +37749,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_interfaces_partial_update", + "operationId" : "dcim_rack-reservations_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInterface" } + "schema" : { "$ref" : "#/definitions/WritableRackReservation" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Interface" } + "schema" : { "$ref" : "#/definitions/RackReservation" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_interfaces_update", + "operationId" : "dcim_rack-reservations_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInterface" } + "schema" : { "$ref" : "#/definitions/WritableRackReservation" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Interface" } + "schema" : { "$ref" : "#/definitions/RackReservation" } } }, "tags" : [ "dcim" ] } }, - "/dcim/interfaces/{id}/trace/" : { - "get" : { - "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", - "operationId" : "dcim_interfaces_trace", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Interface" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this interface.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ] - }, - "/dcim/inventory-items/" : { + "/dcim/rack-roles/" : { "delete" : { "description" : "", - "operationId" : "dcim_inventory-items_bulk_delete", + "operationId" : "dcim_rack-roles_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_inventory-items_list", + "operationId" : "dcim_rack-roles_list", "parameters" : [ { "description" : "", @@ -27314,28 +37807,21 @@ { "description" : "", "in" : "query", - "name" : "label", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "part_id", + "name" : "slug", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag", + "name" : "color", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "discovered", + "name" : "description", "required" : false, "type" : "string" }, @@ -27388,90 +37874,6 @@ "required" : false, "type" : "string" }, - { - "description" : "", - "in" : "query", - "name" : "region_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "region", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_group_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_group", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "location_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "location", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "device_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "device", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "virtual_chassis_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "virtual_chassis", - "required" : false, - "type" : "string" - }, { "description" : "", "in" : "query", @@ -27479,34 +37881,6 @@ "required" : false, "type" : "string" }, - { - "description" : "", - "in" : "query", - "name" : "parent_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "manufacturer_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "manufacturer", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "serial", - "required" : false, - "type" : "string" - }, { "description" : "", "in" : "query", @@ -27615,294 +37989,210 @@ { "description" : "", "in" : "query", - "name" : "label__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "label__ic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "label__nic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "label__iew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "label__niew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "label__isw", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "label__nisw", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "label__ie", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "label__nie", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "label__empty", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "part_id__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "part_id__ic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "part_id__nic", + "name" : "slug__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_id__iew", + "name" : "slug__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_id__niew", + "name" : "slug__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_id__isw", + "name" : "slug__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_id__nisw", + "name" : "slug__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_id__ie", + "name" : "slug__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_id__nie", + "name" : "slug__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "part_id__empty", + "name" : "slug__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__n", + "name" : "slug__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__ic", + "name" : "slug__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__nic", + "name" : "color__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__iew", + "name" : "color__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__niew", + "name" : "color__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__isw", + "name" : "color__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__nisw", + "name" : "color__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__ie", + "name" : "color__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__nie", + "name" : "color__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__empty", + "name" : "color__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "color__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "color__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "description__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "description__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "description__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "description__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id__n", + "name" : "description__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location__n", + "name" : "description__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id__n", + "name" : "description__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device__n", + "name" : "description__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id__n", + "name" : "description__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis__n", + "name" : "description__empty", "required" : false, "type" : "string" }, @@ -27913,27 +38203,6 @@ "required" : false, "type" : "string" }, - { - "description" : "", - "in" : "query", - "name" : "parent_id__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "manufacturer_id__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "manufacturer__n", - "required" : false, - "type" : "string" - }, { "description" : "Number of results to return per page.", "in" : "query", @@ -27965,7 +38234,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/InventoryItem" }, + "items" : { "$ref" : "#/definitions/RackRole" }, "type" : "array" } }, @@ -27981,70 +38250,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_inventory-items_bulk_partial_update", + "operationId" : "dcim_rack-roles_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInventoryItem" } + "schema" : { "$ref" : "#/definitions/RackRole" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/InventoryItem" } + "schema" : { "$ref" : "#/definitions/RackRole" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_inventory-items_create", + "operationId" : "dcim_rack-roles_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInventoryItem" } + "schema" : { "$ref" : "#/definitions/RackRole" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/InventoryItem" } + "schema" : { "$ref" : "#/definitions/RackRole" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_inventory-items_bulk_update", + "operationId" : "dcim_rack-roles_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInventoryItem" } + "schema" : { "$ref" : "#/definitions/RackRole" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/InventoryItem" } + "schema" : { "$ref" : "#/definitions/RackRole" } } }, "tags" : [ "dcim" ] } }, - "/dcim/inventory-items/{id}/" : { + "/dcim/rack-roles/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_inventory-items_delete", + "operationId" : "dcim_rack-roles_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_inventory-items_read", + "operationId" : "dcim_rack-roles_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/InventoryItem" } + "schema" : { "$ref" : "#/definitions/RackRole" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this inventory item.", + "description" : "A unique integer value identifying this rack role.", "in" : "path", "name" : "id", "required" : true, @@ -28052,46 +38321,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_inventory-items_partial_update", + "operationId" : "dcim_rack-roles_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInventoryItem" } + "schema" : { "$ref" : "#/definitions/RackRole" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/InventoryItem" } + "schema" : { "$ref" : "#/definitions/RackRole" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_inventory-items_update", + "operationId" : "dcim_rack-roles_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableInventoryItem" } + "schema" : { "$ref" : "#/definitions/RackRole" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/InventoryItem" } + "schema" : { "$ref" : "#/definitions/RackRole" } } }, "tags" : [ "dcim" ] } }, - "/dcim/locations/" : { + "/dcim/racks/" : { "delete" : { "description" : "", - "operationId" : "dcim_locations_bulk_delete", + "operationId" : "dcim_racks_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_locations_list", + "operationId" : "dcim_racks_list", "parameters" : [ { "description" : "", @@ -28103,908 +38372,749 @@ { "description" : "", "in" : "query", - "name" : "name", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "description", + "name" : "name", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "facility_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "asset_tag", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "u_height", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "desc_units", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "outer_width", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "outer_depth", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "outer_unit", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id", + "name" : "created", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region", + "name" : "created__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id", + "name" : "created__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group", + "name" : "last_updated", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id", + "name" : "last_updated__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site", + "name" : "last_updated__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "parent_id", + "name" : "tenant_group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "parent", + "name" : "tenant_group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "tenant_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "tenant", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "contact", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "contact_role", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "region_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "region", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "site_group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "site_group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "site_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "site", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "location_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "location", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "status", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__n", + "name" : "width", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__ic", + "name" : "role_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nic", + "name" : "role", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__iew", + "name" : "serial", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__niew", + "name" : "tag", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__isw", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nisw", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__ie", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nie", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__empty", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__n", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ic", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nic", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__iew", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__niew", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__isw", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nisw", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ie", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nie", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__empty", + "name" : "name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "facility_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "facility_id__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "facility_id__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "facility_id__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "facility_id__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "facility_id__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "parent_id__n", + "name" : "facility_id__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "parent__n", + "name" : "facility_id__ie", "required" : false, "type" : "string" }, { - "description" : "Number of results to return per page.", + "description" : "", "in" : "query", - "name" : "limit", + "name" : "facility_id__nie", "required" : false, - "type" : "integer" + "type" : "string" }, { - "description" : "The initial index from which to return the results.", + "description" : "", "in" : "query", - "name" : "offset", + "name" : "facility_id__empty", "required" : false, - "type" : "integer" - } - ], - "responses" : { "200" : { - "description" : "", - "schema" : { - "properties" : { - "count" : { "type" : "integer" }, - "next" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "previous" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "results" : { - "items" : { "$ref" : "#/definitions/Location" }, - "type" : "array" - } - }, - "required" : [ - "count", - "results" - ], - "type" : "object" - } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ ], - "patch" : { - "description" : "", - "operationId" : "dcim_locations_bulk_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableLocation" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Location" } - } }, - "tags" : [ "dcim" ] - }, - "post" : { - "description" : "", - "operationId" : "dcim_locations_create", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableLocation" } - } ], - "responses" : { "201" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Location" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_locations_bulk_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableLocation" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Location" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/locations/{id}/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_locations_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "", - "operationId" : "dcim_locations_read", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Location" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this location.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ], - "patch" : { - "description" : "", - "operationId" : "dcim_locations_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableLocation" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Location" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_locations_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableLocation" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Location" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/manufacturers/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_manufacturers_bulk_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_manufacturers_list", - "parameters" : [ + "type" : "string" + }, { "description" : "", "in" : "query", - "name" : "id", + "name" : "asset_tag__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name", + "name" : "asset_tag__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug", + "name" : "asset_tag__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description", + "name" : "asset_tag__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "asset_tag__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "asset_tag__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "asset_tag__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "asset_tag__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "asset_tag__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "asset_tag__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "u_height__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "u_height__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "u_height__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "u_height__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "u_height__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "outer_width__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "outer_width__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "outer_width__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "outer_width__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "outer_width__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "outer_depth__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "outer_depth__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "outer_depth__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "outer_depth__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "outer_depth__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "outer_unit__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__n", + "name" : "tenant_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__ic", + "name" : "tenant_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nic", + "name" : "tenant_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__iew", + "name" : "tenant__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__niew", + "name" : "contact__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__isw", + "name" : "contact_role__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nisw", + "name" : "region_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__ie", + "name" : "region__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nie", + "name" : "site_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__empty", + "name" : "site_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__n", + "name" : "site_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ic", + "name" : "site__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nic", + "name" : "location_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__iew", + "name" : "location__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__niew", + "name" : "status__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__isw", + "name" : "type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nisw", + "name" : "width__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ie", + "name" : "role_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nie", + "name" : "role__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__empty", + "name" : "tag__n", "required" : false, "type" : "string" }, @@ -29039,7 +39149,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/Manufacturer" }, + "items" : { "$ref" : "#/definitions/Rack" }, "type" : "array" } }, @@ -29055,70 +39165,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_manufacturers_bulk_partial_update", + "operationId" : "dcim_racks_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/Manufacturer" } + "schema" : { "$ref" : "#/definitions/WritableRack" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Manufacturer" } + "schema" : { "$ref" : "#/definitions/Rack" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_manufacturers_create", + "operationId" : "dcim_racks_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/Manufacturer" } + "schema" : { "$ref" : "#/definitions/WritableRack" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Manufacturer" } + "schema" : { "$ref" : "#/definitions/Rack" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_manufacturers_bulk_update", + "operationId" : "dcim_racks_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/Manufacturer" } + "schema" : { "$ref" : "#/definitions/WritableRack" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Manufacturer" } + "schema" : { "$ref" : "#/definitions/Rack" } } }, "tags" : [ "dcim" ] } }, - "/dcim/manufacturers/{id}/" : { + "/dcim/racks/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_manufacturers_delete", + "operationId" : "dcim_racks_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_manufacturers_read", + "operationId" : "dcim_racks_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Manufacturer" } + "schema" : { "$ref" : "#/definitions/Rack" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this manufacturer.", + "description" : "A unique integer value identifying this rack.", "in" : "path", "name" : "id", "required" : true, @@ -29126,46 +39236,139 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_manufacturers_partial_update", + "operationId" : "dcim_racks_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/Manufacturer" } + "schema" : { "$ref" : "#/definitions/WritableRack" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Manufacturer" } + "schema" : { "$ref" : "#/definitions/Rack" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_manufacturers_update", + "operationId" : "dcim_racks_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/Manufacturer" } + "schema" : { "$ref" : "#/definitions/WritableRack" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Manufacturer" } + "schema" : { "$ref" : "#/definitions/Rack" } } }, "tags" : [ "dcim" ] } }, - "/dcim/platforms/" : { + "/dcim/racks/{id}/elevation/" : { + "get" : { + "description" : "Rack elevation representing the list of rack units. Also supports rendering the elevation as an SVG.", + "operationId" : "dcim_racks_elevation", + "parameters" : [ + { + "in" : "query", + "minLength" : 1, + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "default" : "front", + "enum" : [ + "front", + "rear" + ], + "in" : "query", + "name" : "face", + "required" : false, + "type" : "string" + }, + { + "default" : "json", + "enum" : [ + "json", + "svg" + ], + "in" : "query", + "name" : "render", + "required" : false, + "type" : "string" + }, + { + "default" : 220, + "in" : "query", + "name" : "unit_width", + "required" : false, + "type" : "integer" + }, + { + "default" : 22, + "in" : "query", + "name" : "unit_height", + "required" : false, + "type" : "integer" + }, + { + "default" : 30, + "in" : "query", + "name" : "legend_width", + "required" : false, + "type" : "integer" + }, + { + "in" : "query", + "name" : "exclude", + "required" : false, + "type" : "integer" + }, + { + "default" : true, + "in" : "query", + "name" : "expand_devices", + "required" : false, + "type" : "boolean" + }, + { + "default" : true, + "in" : "query", + "name" : "include_images", + "required" : false, + "type" : "boolean" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "items" : { "$ref" : "#/definitions/RackUnit" }, + "type" : "array" + } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this rack.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] + }, + "/dcim/rear-port-templates/" : { "delete" : { "description" : "", - "operationId" : "dcim_platforms_bulk_delete", + "operationId" : "dcim_rear-port-templates_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_platforms_list", + "operationId" : "dcim_rear-port-templates_list", "parameters" : [ { "description" : "", @@ -29184,21 +39387,21 @@ { "description" : "", "in" : "query", - "name" : "slug", + "name" : "type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "napalm_driver", + "name" : "color", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description", + "name" : "positions", "required" : false, "type" : "string" }, @@ -29254,14 +39457,7 @@ { "description" : "", "in" : "query", - "name" : "manufacturer_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "manufacturer", + "name" : "devicetype_id", "required" : false, "type" : "string" }, @@ -29373,224 +39569,119 @@ { "description" : "", "in" : "query", - "name" : "slug__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__ic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__nic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__iew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__niew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__isw", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__nisw", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__ie", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__nie", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug__empty", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "napalm_driver__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "napalm_driver__ic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "napalm_driver__nic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "napalm_driver__iew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "napalm_driver__niew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "napalm_driver__isw", + "name" : "type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "napalm_driver__nisw", + "name" : "color__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "napalm_driver__ie", + "name" : "color__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "napalm_driver__nie", + "name" : "color__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "napalm_driver__empty", + "name" : "color__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__n", + "name" : "color__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ic", + "name" : "color__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nic", + "name" : "color__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__iew", + "name" : "color__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__niew", + "name" : "color__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__isw", + "name" : "color__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nisw", + "name" : "positions__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ie", + "name" : "positions__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nie", + "name" : "positions__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__empty", + "name" : "positions__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "manufacturer_id__n", + "name" : "positions__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "manufacturer__n", + "name" : "devicetype_id__n", "required" : false, "type" : "string" }, @@ -29625,7 +39716,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/Platform" }, + "items" : { "$ref" : "#/definitions/RearPortTemplate" }, "type" : "array" } }, @@ -29641,70 +39732,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_platforms_bulk_partial_update", + "operationId" : "dcim_rear-port-templates_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePlatform" } + "schema" : { "$ref" : "#/definitions/WritableRearPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Platform" } + "schema" : { "$ref" : "#/definitions/RearPortTemplate" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_platforms_create", + "operationId" : "dcim_rear-port-templates_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePlatform" } + "schema" : { "$ref" : "#/definitions/WritableRearPortTemplate" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Platform" } + "schema" : { "$ref" : "#/definitions/RearPortTemplate" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_platforms_bulk_update", + "operationId" : "dcim_rear-port-templates_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePlatform" } + "schema" : { "$ref" : "#/definitions/WritableRearPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Platform" } + "schema" : { "$ref" : "#/definitions/RearPortTemplate" } } }, "tags" : [ "dcim" ] } }, - "/dcim/platforms/{id}/" : { + "/dcim/rear-port-templates/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_platforms_delete", + "operationId" : "dcim_rear-port-templates_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_platforms_read", + "operationId" : "dcim_rear-port-templates_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Platform" } + "schema" : { "$ref" : "#/definitions/RearPortTemplate" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this platform.", + "description" : "A unique integer value identifying this rear port template.", "in" : "path", "name" : "id", "required" : true, @@ -29712,46 +39803,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_platforms_partial_update", + "operationId" : "dcim_rear-port-templates_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePlatform" } + "schema" : { "$ref" : "#/definitions/WritableRearPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Platform" } + "schema" : { "$ref" : "#/definitions/RearPortTemplate" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_platforms_update", + "operationId" : "dcim_rear-port-templates_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePlatform" } + "schema" : { "$ref" : "#/definitions/WritableRearPortTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Platform" } + "schema" : { "$ref" : "#/definitions/RearPortTemplate" } } }, "tags" : [ "dcim" ] } }, - "/dcim/power-feeds/" : { + "/dcim/rear-ports/" : { "delete" : { "description" : "", - "operationId" : "dcim_power-feeds_bulk_delete", + "operationId" : "dcim_rear-ports_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_power-feeds_list", + "operationId" : "dcim_rear-ports_list", "parameters" : [ { "description" : "", @@ -29770,7 +39861,7 @@ { "description" : "", "in" : "query", - "name" : "status", + "name" : "label", "required" : false, "type" : "string" }, @@ -29784,35 +39875,21 @@ { "description" : "", "in" : "query", - "name" : "supply", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "phase", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "voltage", + "name" : "color", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "amperage", + "name" : "positions", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "max_utilization", + "name" : "description", "required" : false, "type" : "string" }, @@ -29858,20 +39935,6 @@ "required" : false, "type" : "string" }, - { - "description" : "", - "in" : "query", - "name" : "cabled", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "connected", - "required" : false, - "type" : "string" - }, { "description" : "", "in" : "query", @@ -29896,738 +39959,532 @@ { "description" : "", "in" : "query", - "name" : "site_group_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_group", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "power_panel_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "rack_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "tag", + "name" : "site_group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "site_group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "site_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "site", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "location_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "location", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "device_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "device", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "virtual_chassis_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "virtual_chassis", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "tag", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "cabled", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "status__n", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "supply__n", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "phase__n", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "voltage__n", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "voltage__lte", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "voltage__lt", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "voltage__gte", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "voltage__gt", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "amperage__n", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "amperage__lte", + "name" : "name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "amperage__lt", + "name" : "label__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "amperage__gte", + "name" : "label__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "amperage__gt", + "name" : "label__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "max_utilization__n", + "name" : "label__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "max_utilization__lte", + "name" : "label__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "max_utilization__lt", + "name" : "label__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "max_utilization__gte", + "name" : "label__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "max_utilization__gt", + "name" : "label__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "label__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "label__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "color__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "color__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "color__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "power_panel_id__n", + "name" : "color__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "rack_id__n", + "name" : "color__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag__n", + "name" : "color__isw", "required" : false, "type" : "string" }, { - "description" : "Number of results to return per page.", + "description" : "", "in" : "query", - "name" : "limit", + "name" : "color__nisw", "required" : false, - "type" : "integer" + "type" : "string" }, { - "description" : "The initial index from which to return the results.", + "description" : "", "in" : "query", - "name" : "offset", + "name" : "color__ie", "required" : false, - "type" : "integer" - } - ], - "responses" : { "200" : { - "description" : "", - "schema" : { - "properties" : { - "count" : { "type" : "integer" }, - "next" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "previous" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "results" : { - "items" : { "$ref" : "#/definitions/PowerFeed" }, - "type" : "array" - } - }, - "required" : [ - "count", - "results" - ], - "type" : "object" - } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ ], - "patch" : { - "description" : "", - "operationId" : "dcim_power-feeds_bulk_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerFeed" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerFeed" } - } }, - "tags" : [ "dcim" ] - }, - "post" : { - "description" : "", - "operationId" : "dcim_power-feeds_create", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerFeed" } - } ], - "responses" : { "201" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerFeed" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_power-feeds_bulk_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerFeed" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerFeed" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/power-feeds/{id}/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_power-feeds_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "", - "operationId" : "dcim_power-feeds_read", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerFeed" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this power feed.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ], - "patch" : { - "description" : "", - "operationId" : "dcim_power-feeds_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerFeed" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerFeed" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_power-feeds_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerFeed" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerFeed" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/power-feeds/{id}/trace/" : { - "get" : { - "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", - "operationId" : "dcim_power-feeds_trace", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerFeed" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this power feed.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ] - }, - "/dcim/power-outlet-templates/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_power-outlet-templates_bulk_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_power-outlet-templates_list", - "parameters" : [ + "type" : "string" + }, { "description" : "", "in" : "query", - "name" : "id", + "name" : "color__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name", + "name" : "color__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type", + "name" : "positions__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "feed_leg", + "name" : "positions__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "positions__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "positions__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "positions__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "description__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "description__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "description__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "description__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "devicetype_id", + "name" : "description__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "description__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "description__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "description__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "description__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "description__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "region_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "region__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "site_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "site_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "site_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "site__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "location_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "location__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "device_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "device__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "virtual_chassis_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "feed_leg__n", + "name" : "virtual_chassis__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "devicetype_id__n", + "name" : "tag__n", "required" : false, "type" : "string" }, @@ -30662,7 +40519,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/PowerOutletTemplate" }, + "items" : { "$ref" : "#/definitions/RearPort" }, "type" : "array" } }, @@ -30678,70 +40535,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_power-outlet-templates_bulk_partial_update", + "operationId" : "dcim_rear-ports_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerOutletTemplate" } + "schema" : { "$ref" : "#/definitions/WritableRearPort" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } + "schema" : { "$ref" : "#/definitions/RearPort" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_power-outlet-templates_create", + "operationId" : "dcim_rear-ports_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerOutletTemplate" } + "schema" : { "$ref" : "#/definitions/WritableRearPort" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } + "schema" : { "$ref" : "#/definitions/RearPort" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_power-outlet-templates_bulk_update", + "operationId" : "dcim_rear-ports_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerOutletTemplate" } + "schema" : { "$ref" : "#/definitions/WritableRearPort" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } + "schema" : { "$ref" : "#/definitions/RearPort" } } }, "tags" : [ "dcim" ] } }, - "/dcim/power-outlet-templates/{id}/" : { + "/dcim/rear-ports/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_power-outlet-templates_delete", + "operationId" : "dcim_rear-ports_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_power-outlet-templates_read", + "operationId" : "dcim_rear-ports_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } + "schema" : { "$ref" : "#/definitions/RearPort" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this power outlet template.", + "description" : "A unique integer value identifying this rear port.", "in" : "path", "name" : "id", "required" : true, @@ -30749,46 +40606,65 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_power-outlet-templates_partial_update", + "operationId" : "dcim_rear-ports_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerOutletTemplate" } + "schema" : { "$ref" : "#/definitions/WritableRearPort" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } + "schema" : { "$ref" : "#/definitions/RearPort" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_power-outlet-templates_update", + "operationId" : "dcim_rear-ports_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerOutletTemplate" } + "schema" : { "$ref" : "#/definitions/WritableRearPort" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutletTemplate" } + "schema" : { "$ref" : "#/definitions/RearPort" } } }, "tags" : [ "dcim" ] } }, - "/dcim/power-outlets/" : { + "/dcim/rear-ports/{id}/paths/" : { + "get" : { + "description" : "Return all CablePaths which traverse a given pass-through port.", + "operationId" : "dcim_rear-ports_paths", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/RearPort" } + } }, + "tags" : [ "dcim" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this rear port.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] + }, + "/dcim/regions/" : { "delete" : { "description" : "", - "operationId" : "dcim_power-outlets_bulk_delete", + "operationId" : "dcim_regions_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_power-outlets_list", + "operationId" : "dcim_regions_list", "parameters" : [ { "description" : "", @@ -30807,14 +40683,7 @@ { "description" : "", "in" : "query", - "name" : "label", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "feed_leg", + "name" : "slug", "required" : false, "type" : "string" }, @@ -30877,84 +40746,28 @@ { "description" : "", "in" : "query", - "name" : "region_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "region", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_group_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_group", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "location_id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "location", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "device_id", + "name" : "contact", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device", + "name" : "contact_role", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id", + "name" : "parent_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis", + "name" : "parent", "required" : false, "type" : "string" }, @@ -30965,27 +40778,6 @@ "required" : false, "type" : "string" }, - { - "description" : "", - "in" : "query", - "name" : "cabled", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "connected", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "type", - "required" : false, - "type" : "string" - }, { "description" : "", "in" : "query", @@ -31094,77 +40886,70 @@ { "description" : "", "in" : "query", - "name" : "label__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "label__ic", + "name" : "slug__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nic", + "name" : "slug__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__iew", + "name" : "slug__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__niew", + "name" : "slug__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__isw", + "name" : "slug__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nisw", + "name" : "slug__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__ie", + "name" : "slug__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nie", + "name" : "slug__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__empty", + "name" : "slug__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "feed_leg__n", + "name" : "slug__empty", "required" : false, "type" : "string" }, @@ -31241,84 +41026,28 @@ { "description" : "", "in" : "query", - "name" : "region_id__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "region__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_group_id__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "site_group__n", + "name" : "contact__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "contact_role__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "location_id__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "location__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "device_id__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "device__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "virtual_chassis_id__n", + "name" : "parent_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis__n", + "name" : "parent__n", "required" : false, "type" : "string" }, @@ -31329,13 +41058,6 @@ "required" : false, "type" : "string" }, - { - "description" : "", - "in" : "query", - "name" : "type__n", - "required" : false, - "type" : "string" - }, { "description" : "Number of results to return per page.", "in" : "query", @@ -31367,7 +41089,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/PowerOutlet" }, + "items" : { "$ref" : "#/definitions/Region" }, "type" : "array" } }, @@ -31383,70 +41105,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_power-outlets_bulk_partial_update", + "operationId" : "dcim_regions_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerOutlet" } + "schema" : { "$ref" : "#/definitions/WritableRegion" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutlet" } + "schema" : { "$ref" : "#/definitions/Region" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_power-outlets_create", + "operationId" : "dcim_regions_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerOutlet" } + "schema" : { "$ref" : "#/definitions/WritableRegion" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutlet" } + "schema" : { "$ref" : "#/definitions/Region" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_power-outlets_bulk_update", + "operationId" : "dcim_regions_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerOutlet" } + "schema" : { "$ref" : "#/definitions/WritableRegion" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutlet" } + "schema" : { "$ref" : "#/definitions/Region" } } }, "tags" : [ "dcim" ] } }, - "/dcim/power-outlets/{id}/" : { + "/dcim/regions/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_power-outlets_delete", + "operationId" : "dcim_regions_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_power-outlets_read", + "operationId" : "dcim_regions_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutlet" } + "schema" : { "$ref" : "#/definitions/Region" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this power outlet.", + "description" : "A unique integer value identifying this region.", "in" : "path", "name" : "id", "required" : true, @@ -31454,65 +41176,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_power-outlets_partial_update", + "operationId" : "dcim_regions_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerOutlet" } + "schema" : { "$ref" : "#/definitions/WritableRegion" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutlet" } + "schema" : { "$ref" : "#/definitions/Region" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_power-outlets_update", + "operationId" : "dcim_regions_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerOutlet" } + "schema" : { "$ref" : "#/definitions/WritableRegion" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutlet" } + "schema" : { "$ref" : "#/definitions/Region" } } }, "tags" : [ "dcim" ] } }, - "/dcim/power-outlets/{id}/trace/" : { - "get" : { - "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", - "operationId" : "dcim_power-outlets_trace", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerOutlet" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this power outlet.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ] - }, - "/dcim/power-panels/" : { + "/dcim/site-groups/" : { "delete" : { "description" : "", - "operationId" : "dcim_power-panels_bulk_delete", + "operationId" : "dcim_site-groups_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_power-panels_list", + "operationId" : "dcim_site-groups_list", "parameters" : [ { "description" : "", @@ -31531,98 +41234,91 @@ { "description" : "", "in" : "query", - "name" : "created", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "created__gte", + "name" : "slug", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "description", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "created", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "created__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "created__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "last_updated", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id", + "name" : "last_updated__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region", + "name" : "last_updated__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group", + "name" : "contact", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id", + "name" : "contact_role", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site", + "name" : "parent_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id", + "name" : "parent", "required" : false, "type" : "string" }, @@ -31741,49 +41437,168 @@ { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "slug__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "slug__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "slug__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "slug__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "slug__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "slug__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id__n", + "name" : "slug__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "slug__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact_role__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "parent_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "parent__n", "required" : false, "type" : "string" }, @@ -31825,7 +41640,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/PowerPanel" }, + "items" : { "$ref" : "#/definitions/SiteGroup" }, "type" : "array" } }, @@ -31841,70 +41656,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_power-panels_bulk_partial_update", + "operationId" : "dcim_site-groups_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPanel" } + "schema" : { "$ref" : "#/definitions/WritableSiteGroup" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPanel" } + "schema" : { "$ref" : "#/definitions/SiteGroup" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_power-panels_create", + "operationId" : "dcim_site-groups_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPanel" } + "schema" : { "$ref" : "#/definitions/WritableSiteGroup" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPanel" } + "schema" : { "$ref" : "#/definitions/SiteGroup" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_power-panels_bulk_update", + "operationId" : "dcim_site-groups_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPanel" } + "schema" : { "$ref" : "#/definitions/WritableSiteGroup" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPanel" } + "schema" : { "$ref" : "#/definitions/SiteGroup" } } }, "tags" : [ "dcim" ] } }, - "/dcim/power-panels/{id}/" : { + "/dcim/site-groups/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_power-panels_delete", + "operationId" : "dcim_site-groups_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_power-panels_read", + "operationId" : "dcim_site-groups_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPanel" } + "schema" : { "$ref" : "#/definitions/SiteGroup" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this power panel.", + "description" : "A unique integer value identifying this site group.", "in" : "path", "name" : "id", "required" : true, @@ -31912,46 +41727,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_power-panels_partial_update", + "operationId" : "dcim_site-groups_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPanel" } + "schema" : { "$ref" : "#/definitions/WritableSiteGroup" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPanel" } + "schema" : { "$ref" : "#/definitions/SiteGroup" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_power-panels_update", + "operationId" : "dcim_site-groups_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPanel" } + "schema" : { "$ref" : "#/definitions/WritableSiteGroup" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPanel" } + "schema" : { "$ref" : "#/definitions/SiteGroup" } } }, "tags" : [ "dcim" ] } }, - "/dcim/power-port-templates/" : { + "/dcim/sites/" : { "delete" : { "description" : "", - "operationId" : "dcim_power-port-templates_bulk_delete", + "operationId" : "dcim_sites_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_power-port-templates_list", + "operationId" : "dcim_sites_list", "parameters" : [ { "description" : "", @@ -31970,21 +41785,63 @@ { "description" : "", "in" : "query", - "name" : "type", + "name" : "slug", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw", + "name" : "facility", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw", + "name" : "asn", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "latitude", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "longitude", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact_name", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact_phone", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "contact_email", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "description", "required" : false, "type" : "string" }, @@ -32033,810 +41890,658 @@ { "description" : "", "in" : "query", - "name" : "q", + "name" : "tenant_group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "devicetype_id", + "name" : "tenant_group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "tenant_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "tenant", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "contact", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "contact_role", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "status", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "region_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "region", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "group_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "group", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "asn_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "tag", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw__n", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw__lte", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw__lt", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw__gte", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw__gt", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw__n", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw__lte", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw__lt", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw__gte", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw__gt", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "devicetype_id__n", + "name" : "name__empty", "required" : false, "type" : "string" }, { - "description" : "Number of results to return per page.", + "description" : "", "in" : "query", - "name" : "limit", + "name" : "slug__n", "required" : false, - "type" : "integer" + "type" : "string" }, - { - "description" : "The initial index from which to return the results.", - "in" : "query", - "name" : "offset", - "required" : false, - "type" : "integer" - } - ], - "responses" : { "200" : { - "description" : "", - "schema" : { - "properties" : { - "count" : { "type" : "integer" }, - "next" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "previous" : { - "format" : "uri", - "type" : "string", - "x-nullable" : true - }, - "results" : { - "items" : { "$ref" : "#/definitions/PowerPortTemplate" }, - "type" : "array" - } - }, - "required" : [ - "count", - "results" - ], - "type" : "object" - } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ ], - "patch" : { - "description" : "", - "operationId" : "dcim_power-port-templates_bulk_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPortTemplate" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } - } }, - "tags" : [ "dcim" ] - }, - "post" : { - "description" : "", - "operationId" : "dcim_power-port-templates_create", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPortTemplate" } - } ], - "responses" : { "201" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_power-port-templates_bulk_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPortTemplate" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/power-port-templates/{id}/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_power-port-templates_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "", - "operationId" : "dcim_power-port-templates_read", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this power port template.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ], - "patch" : { - "description" : "", - "operationId" : "dcim_power-port-templates_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPortTemplate" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } - } }, - "tags" : [ "dcim" ] - }, - "put" : { - "description" : "", - "operationId" : "dcim_power-port-templates_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPortTemplate" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPortTemplate" } - } }, - "tags" : [ "dcim" ] - } - }, - "/dcim/power-ports/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_power-ports_bulk_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_power-ports_list", - "parameters" : [ { "description" : "", "in" : "query", - "name" : "id", + "name" : "slug__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name", + "name" : "slug__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label", + "name" : "slug__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw", + "name" : "slug__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw", + "name" : "slug__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description", + "name" : "slug__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "slug__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "slug__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "slug__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "facility__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "facility__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "facility__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "facility__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id", + "name" : "facility__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region", + "name" : "facility__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id", + "name" : "facility__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group", + "name" : "facility__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id", + "name" : "facility__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site", + "name" : "facility__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id", + "name" : "asn__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location", + "name" : "asn__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id", + "name" : "asn__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device", + "name" : "asn__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id", + "name" : "asn__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis", + "name" : "latitude__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag", + "name" : "latitude__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cabled", + "name" : "latitude__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "connected", + "name" : "latitude__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type", + "name" : "latitude__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "longitude__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "longitude__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "longitude__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "longitude__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "longitude__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "contact_name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "contact_name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "contact_name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "contact_name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "contact_name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "contact_name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "contact_name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "contact_name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "contact_name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "contact_name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__n", + "name" : "contact_phone__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__ic", + "name" : "contact_phone__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nic", + "name" : "contact_phone__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__iew", + "name" : "contact_phone__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__niew", + "name" : "contact_phone__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__isw", + "name" : "contact_phone__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nisw", + "name" : "contact_phone__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__ie", + "name" : "contact_phone__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nie", + "name" : "contact_phone__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__empty", + "name" : "contact_phone__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw__n", + "name" : "contact_email__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw__lte", + "name" : "contact_email__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw__lt", + "name" : "contact_email__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw__gte", + "name" : "contact_email__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "maximum_draw__gt", + "name" : "contact_email__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw__n", + "name" : "contact_email__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw__lte", + "name" : "contact_email__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw__lt", + "name" : "contact_email__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw__gte", + "name" : "contact_email__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "allocated_draw__gt", + "name" : "contact_email__empty", "required" : false, "type" : "string" }, @@ -32913,84 +42618,84 @@ { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "tenant_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "tenant_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "tenant_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "tenant__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "contact__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "contact_role__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id__n", + "name" : "status__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location__n", + "name" : "region_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id__n", + "name" : "region__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device__n", + "name" : "group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id__n", + "name" : "group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis__n", + "name" : "asn_id__n", "required" : false, "type" : "string" }, @@ -33001,13 +42706,6 @@ "required" : false, "type" : "string" }, - { - "description" : "", - "in" : "query", - "name" : "type__n", - "required" : false, - "type" : "string" - }, { "description" : "Number of results to return per page.", "in" : "query", @@ -33039,7 +42737,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/PowerPort" }, + "items" : { "$ref" : "#/definitions/Site" }, "type" : "array" } }, @@ -33055,70 +42753,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_power-ports_bulk_partial_update", + "operationId" : "dcim_sites_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPort" } + "schema" : { "$ref" : "#/definitions/WritableSite" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPort" } + "schema" : { "$ref" : "#/definitions/Site" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_power-ports_create", + "operationId" : "dcim_sites_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPort" } + "schema" : { "$ref" : "#/definitions/WritableSite" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPort" } + "schema" : { "$ref" : "#/definitions/Site" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_power-ports_bulk_update", + "operationId" : "dcim_sites_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPort" } + "schema" : { "$ref" : "#/definitions/WritableSite" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPort" } + "schema" : { "$ref" : "#/definitions/Site" } } }, "tags" : [ "dcim" ] } }, - "/dcim/power-ports/{id}/" : { + "/dcim/sites/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_power-ports_delete", + "operationId" : "dcim_sites_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_power-ports_read", + "operationId" : "dcim_sites_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPort" } + "schema" : { "$ref" : "#/definitions/Site" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this power port.", + "description" : "A unique integer value identifying this site.", "in" : "path", "name" : "id", "required" : true, @@ -33126,65 +42824,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_power-ports_partial_update", + "operationId" : "dcim_sites_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPort" } + "schema" : { "$ref" : "#/definitions/WritableSite" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPort" } + "schema" : { "$ref" : "#/definitions/Site" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_power-ports_update", + "operationId" : "dcim_sites_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritablePowerPort" } + "schema" : { "$ref" : "#/definitions/WritableSite" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPort" } + "schema" : { "$ref" : "#/definitions/Site" } } }, "tags" : [ "dcim" ] } }, - "/dcim/power-ports/{id}/trace/" : { - "get" : { - "description" : "Trace a complete cable path and return each segment as a three-tuple of (termination, cable, termination).", - "operationId" : "dcim_power-ports_trace", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/PowerPort" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this power port.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ] - }, - "/dcim/rack-reservations/" : { + "/dcim/virtual-chassis/" : { "delete" : { "description" : "", - "operationId" : "dcim_rack-reservations_bulk_delete", + "operationId" : "dcim_virtual-chassis_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_rack-reservations_list", + "operationId" : "dcim_virtual-chassis_list", "parameters" : [ { "description" : "", @@ -33193,6 +42872,20 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "domain", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -33238,42 +42931,49 @@ { "description" : "", "in" : "query", - "name" : "tenant_group_id", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group", + "name" : "master_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_id", + "name" : "master", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant", + "name" : "region_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "region", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "rack_id", + "name" : "site_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group", "required" : false, "type" : "string" }, @@ -33294,147 +42994,266 @@ { "description" : "", "in" : "query", - "name" : "location_id", + "name" : "tenant_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location", + "name" : "tenant", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "user_id", + "name" : "tag", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "user", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "domain__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "domain__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group_id__n", + "name" : "domain__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group__n", + "name" : "domain__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_id__n", + "name" : "domain__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant__n", + "name" : "domain__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "rack_id__n", + "name" : "domain__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "domain__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "domain__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id__n", + "name" : "domain__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location__n", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "user_id__n", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "user__n", + "name" : "name__nic", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__iew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__niew", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__isw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nisw", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__ie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__nie", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "name__empty", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "master_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "master__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_id__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant__n", "required" : false, "type" : "string" }, @@ -33476,7 +43295,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/RackReservation" }, + "items" : { "$ref" : "#/definitions/VirtualChassis" }, "type" : "array" } }, @@ -33492,70 +43311,70 @@ "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_rack-reservations_bulk_partial_update", + "operationId" : "dcim_virtual-chassis_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRackReservation" } + "schema" : { "$ref" : "#/definitions/WritableVirtualChassis" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackReservation" } + "schema" : { "$ref" : "#/definitions/VirtualChassis" } } }, "tags" : [ "dcim" ] }, "post" : { "description" : "", - "operationId" : "dcim_rack-reservations_create", + "operationId" : "dcim_virtual-chassis_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRackReservation" } + "schema" : { "$ref" : "#/definitions/WritableVirtualChassis" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackReservation" } + "schema" : { "$ref" : "#/definitions/VirtualChassis" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_rack-reservations_bulk_update", + "operationId" : "dcim_virtual-chassis_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRackReservation" } + "schema" : { "$ref" : "#/definitions/WritableVirtualChassis" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackReservation" } + "schema" : { "$ref" : "#/definitions/VirtualChassis" } } }, "tags" : [ "dcim" ] } }, - "/dcim/rack-reservations/{id}/" : { + "/dcim/virtual-chassis/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_rack-reservations_delete", + "operationId" : "dcim_virtual-chassis_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, "tags" : [ "dcim" ] }, "get" : { "description" : "", - "operationId" : "dcim_rack-reservations_read", + "operationId" : "dcim_virtual-chassis_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackReservation" } + "schema" : { "$ref" : "#/definitions/VirtualChassis" } } }, "tags" : [ "dcim" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this rack reservation.", + "description" : "A unique integer value identifying this virtual chassis.", "in" : "path", "name" : "id", "required" : true, @@ -33563,46 +43382,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_rack-reservations_partial_update", + "operationId" : "dcim_virtual-chassis_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRackReservation" } + "schema" : { "$ref" : "#/definitions/WritableVirtualChassis" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackReservation" } + "schema" : { "$ref" : "#/definitions/VirtualChassis" } } }, "tags" : [ "dcim" ] }, "put" : { "description" : "", - "operationId" : "dcim_rack-reservations_update", + "operationId" : "dcim_virtual-chassis_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRackReservation" } + "schema" : { "$ref" : "#/definitions/WritableVirtualChassis" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackReservation" } + "schema" : { "$ref" : "#/definitions/VirtualChassis" } } }, "tags" : [ "dcim" ] } }, - "/dcim/rack-roles/" : { + "/extras/config-contexts/" : { "delete" : { "description" : "", - "operationId" : "dcim_rack-roles_bulk_delete", + "operationId" : "extras_config-contexts_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_rack-roles_list", + "operationId" : "extras_config-contexts_list", "parameters" : [ { "description" : "", @@ -33621,14 +43440,7 @@ { "description" : "", "in" : "query", - "name" : "slug", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "color", + "name" : "is_active", "required" : false, "type" : "string" }, @@ -33681,6 +43493,146 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "region_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "region", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "site", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "device_type_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "role_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "role", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "platform_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "platform", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cluster_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cluster_group", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "cluster_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_group", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tenant", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag_id", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "tag", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -33789,140 +43741,140 @@ { "description" : "", "in" : "query", - "name" : "slug__n", + "name" : "region_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__ic", + "name" : "region__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nic", + "name" : "site_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__iew", + "name" : "site_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__niew", + "name" : "site_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__isw", + "name" : "site__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nisw", + "name" : "device_type_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__ie", + "name" : "role_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nie", + "name" : "role__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__empty", + "name" : "platform_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__n", + "name" : "platform__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__ic", + "name" : "cluster_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nic", + "name" : "cluster_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__iew", + "name" : "cluster_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__niew", + "name" : "tenant_group_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__isw", + "name" : "tenant_group__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nisw", + "name" : "tenant_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__ie", + "name" : "tenant__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nie", + "name" : "tag_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__empty", + "name" : "tag__n", "required" : false, "type" : "string" }, @@ -33957,7 +43909,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/RackRole" }, + "items" : { "$ref" : "#/definitions/ConfigContext" }, "type" : "array" } }, @@ -33968,75 +43920,75 @@ "type" : "object" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_rack-roles_bulk_partial_update", + "operationId" : "extras_config-contexts_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/RackRole" } + "schema" : { "$ref" : "#/definitions/WritableConfigContext" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackRole" } + "schema" : { "$ref" : "#/definitions/ConfigContext" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "post" : { "description" : "", - "operationId" : "dcim_rack-roles_create", + "operationId" : "extras_config-contexts_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/RackRole" } + "schema" : { "$ref" : "#/definitions/WritableConfigContext" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackRole" } + "schema" : { "$ref" : "#/definitions/ConfigContext" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "put" : { "description" : "", - "operationId" : "dcim_rack-roles_bulk_update", + "operationId" : "extras_config-contexts_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/RackRole" } + "schema" : { "$ref" : "#/definitions/WritableConfigContext" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackRole" } + "schema" : { "$ref" : "#/definitions/ConfigContext" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] } }, - "/dcim/rack-roles/{id}/" : { + "/extras/config-contexts/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_rack-roles_delete", + "operationId" : "extras_config-contexts_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "get" : { "description" : "", - "operationId" : "dcim_rack-roles_read", + "operationId" : "extras_config-contexts_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackRole" } + "schema" : { "$ref" : "#/definitions/ConfigContext" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this rack role.", + "description" : "A unique integer value identifying this config context.", "in" : "path", "name" : "id", "required" : true, @@ -34044,46 +43996,144 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_rack-roles_partial_update", + "operationId" : "extras_config-contexts_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/RackRole" } + "schema" : { "$ref" : "#/definitions/WritableConfigContext" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackRole" } + "schema" : { "$ref" : "#/definitions/ConfigContext" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "put" : { "description" : "", - "operationId" : "dcim_rack-roles_update", + "operationId" : "extras_config-contexts_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/RackRole" } + "schema" : { "$ref" : "#/definitions/WritableConfigContext" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RackRole" } + "schema" : { "$ref" : "#/definitions/ConfigContext" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] } }, - "/dcim/racks/" : { + "/extras/content-types/" : { + "get" : { + "description" : "Read-only list of ContentTypes. Limit results to ContentTypes pertinent to NetBox objects.", + "operationId" : "extras_content-types_list", + "parameters" : [ + { + "description" : "", + "in" : "query", + "name" : "id", + "required" : false, + "type" : "number" + }, + { + "description" : "", + "in" : "query", + "name" : "app_label", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "model", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "q", + "required" : false, + "type" : "string" + }, + { + "description" : "Number of results to return per page.", + "in" : "query", + "name" : "limit", + "required" : false, + "type" : "integer" + }, + { + "description" : "The initial index from which to return the results.", + "in" : "query", + "name" : "offset", + "required" : false, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/ContentType" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "extras" ] + }, + "parameters" : [ ] + }, + "/extras/content-types/{id}/" : { + "get" : { + "description" : "Read-only list of ContentTypes. Limit results to ContentTypes pertinent to NetBox objects.", + "operationId" : "extras_content-types_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ContentType" } + } }, + "tags" : [ "extras" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this content type.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] + }, + "/extras/custom-fields/" : { "delete" : { "description" : "", - "operationId" : "dcim_racks_bulk_delete", + "operationId" : "extras_custom-fields_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_racks_list", + "operationId" : "extras_custom-fields_list", "parameters" : [ { "description" : "", @@ -34092,6 +44142,13 @@ "required" : false, "type" : "string" }, + { + "description" : "", + "in" : "query", + "name" : "content_types", + "required" : false, + "type" : "string" + }, { "description" : "", "in" : "query", @@ -34102,714 +44159,894 @@ { "description" : "", "in" : "query", - "name" : "facility_id", + "name" : "required", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag", + "name" : "filter_logic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "u_height", + "name" : "weight", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "desc_units", + "name" : "description", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_width", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_depth", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_unit", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "content_types__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "content_types__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "content_types__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group_id", + "name" : "content_types__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group", + "name" : "content_types__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_id", + "name" : "content_types__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant", + "name" : "content_types__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "content_types__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id", + "name" : "content_types__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "status", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "width", + "name" : "name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "role_id", + "name" : "filter_logic__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "weight__n", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "weight__lte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "weight__lt", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "weight__gte", + "required" : false, + "type" : "string" + }, + { + "description" : "", + "in" : "query", + "name" : "weight__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "role", + "name" : "description__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "serial", + "name" : "description__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag", + "name" : "description__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "description__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "description__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "description__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "description__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "description__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__n", + "name" : "description__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ic", + "name" : "description__empty", "required" : false, "type" : "string" }, { - "description" : "", + "description" : "Number of results to return per page.", "in" : "query", - "name" : "name__nic", + "name" : "limit", "required" : false, - "type" : "string" + "type" : "integer" }, { - "description" : "", + "description" : "The initial index from which to return the results.", "in" : "query", - "name" : "name__iew", + "name" : "offset", "required" : false, - "type" : "string" - }, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/CustomField" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "extras" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "extras_custom-fields_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCustomField" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CustomField" } + } }, + "tags" : [ "extras" ] + }, + "post" : { + "description" : "", + "operationId" : "extras_custom-fields_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCustomField" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CustomField" } + } }, + "tags" : [ "extras" ] + }, + "put" : { + "description" : "", + "operationId" : "extras_custom-fields_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCustomField" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CustomField" } + } }, + "tags" : [ "extras" ] + } + }, + "/extras/custom-fields/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "extras_custom-fields_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "extras" ] + }, + "get" : { + "description" : "", + "operationId" : "extras_custom-fields_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CustomField" } + } }, + "tags" : [ "extras" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this custom field.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "extras_custom-fields_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCustomField" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CustomField" } + } }, + "tags" : [ "extras" ] + }, + "put" : { + "description" : "", + "operationId" : "extras_custom-fields_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/WritableCustomField" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/CustomField" } + } }, + "tags" : [ "extras" ] + } + }, + "/extras/custom-links/" : { + "delete" : { + "description" : "", + "operationId" : "extras_custom-links_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "extras" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "extras_custom-links_list", + "parameters" : [ { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "content_type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "name", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "link_text", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "link_url", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "weight", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "facility_id__n", + "name" : "group_name", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "facility_id__ic", + "name" : "new_window", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "facility_id__nic", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "facility_id__iew", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "facility_id__niew", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "facility_id__isw", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "facility_id__nisw", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "facility_id__ie", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "facility_id__nie", + "name" : "content_type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "facility_id__empty", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__n", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__ic", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__nic", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__iew", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__niew", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__isw", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__nisw", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__ie", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__nie", + "name" : "name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "asset_tag__empty", + "name" : "link_text__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "u_height__n", + "name" : "link_text__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "u_height__lte", + "name" : "link_text__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "u_height__lt", + "name" : "link_text__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "u_height__gte", + "name" : "link_text__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "u_height__gt", + "name" : "link_text__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_width__n", + "name" : "link_text__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_width__lte", + "name" : "link_text__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_width__lt", + "name" : "link_text__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_width__gte", + "name" : "link_text__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_width__gt", + "name" : "link_url__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_depth__n", + "name" : "link_url__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_depth__lte", + "name" : "link_url__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_depth__lt", + "name" : "link_url__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_depth__gte", + "name" : "link_url__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_depth__gt", + "name" : "link_url__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "outer_unit__n", + "name" : "link_url__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group_id__n", + "name" : "link_url__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_group__n", + "name" : "link_url__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant_id__n", + "name" : "link_url__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tenant__n", + "name" : "weight__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "weight__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "weight__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "weight__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "weight__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "group_name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "group_name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id__n", + "name" : "group_name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location__n", + "name" : "group_name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "status__n", + "name" : "group_name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "group_name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "width__n", + "name" : "group_name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "role_id__n", + "name" : "group_name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "role__n", + "name" : "group_name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag__n", + "name" : "group_name__empty", "required" : false, "type" : "string" }, @@ -34844,7 +45081,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/Rack" }, + "items" : { "$ref" : "#/definitions/CustomLink" }, "type" : "array" } }, @@ -34855,75 +45092,75 @@ "type" : "object" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_racks_bulk_partial_update", + "operationId" : "extras_custom-links_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRack" } + "schema" : { "$ref" : "#/definitions/CustomLink" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Rack" } + "schema" : { "$ref" : "#/definitions/CustomLink" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "post" : { "description" : "", - "operationId" : "dcim_racks_create", + "operationId" : "extras_custom-links_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRack" } + "schema" : { "$ref" : "#/definitions/CustomLink" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Rack" } + "schema" : { "$ref" : "#/definitions/CustomLink" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "put" : { "description" : "", - "operationId" : "dcim_racks_bulk_update", + "operationId" : "extras_custom-links_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRack" } + "schema" : { "$ref" : "#/definitions/CustomLink" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Rack" } + "schema" : { "$ref" : "#/definitions/CustomLink" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] } }, - "/dcim/racks/{id}/" : { + "/extras/custom-links/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_racks_delete", + "operationId" : "extras_custom-links_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "get" : { "description" : "", - "operationId" : "dcim_racks_read", + "operationId" : "extras_custom-links_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Rack" } + "schema" : { "$ref" : "#/definitions/CustomLink" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this rack.", + "description" : "A unique integer value identifying this custom link.", "in" : "path", "name" : "id", "required" : true, @@ -34931,214 +45168,72 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_racks_partial_update", + "operationId" : "extras_custom-links_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRack" } + "schema" : { "$ref" : "#/definitions/CustomLink" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Rack" } + "schema" : { "$ref" : "#/definitions/CustomLink" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "put" : { "description" : "", - "operationId" : "dcim_racks_update", + "operationId" : "extras_custom-links_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRack" } + "schema" : { "$ref" : "#/definitions/CustomLink" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Rack" } + "schema" : { "$ref" : "#/definitions/CustomLink" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] } }, - "/dcim/racks/{id}/elevation/" : { - "get" : { - "description" : "Rack elevation representing the list of rack units. Also supports rendering the elevation as an SVG.", - "operationId" : "dcim_racks_elevation", - "parameters" : [ - { - "in" : "query", - "minLength" : 1, - "name" : "q", - "required" : false, - "type" : "string" - }, - { - "default" : "front", - "enum" : [ - "front", - "rear" - ], - "in" : "query", - "name" : "face", - "required" : false, - "type" : "string" - }, - { - "default" : "json", - "enum" : [ - "json", - "svg" - ], - "in" : "query", - "name" : "render", - "required" : false, - "type" : "string" - }, - { - "default" : 220, - "in" : "query", - "name" : "unit_width", - "required" : false, - "type" : "integer" - }, - { - "default" : 22, - "in" : "query", - "name" : "unit_height", - "required" : false, - "type" : "integer" - }, - { - "default" : 30, - "in" : "query", - "name" : "legend_width", - "required" : false, - "type" : "integer" - }, - { - "in" : "query", - "name" : "exclude", - "required" : false, - "type" : "integer" - }, - { - "default" : true, - "in" : "query", - "name" : "expand_devices", - "required" : false, - "type" : "boolean" - }, - { - "default" : true, - "in" : "query", - "name" : "include_images", - "required" : false, - "type" : "boolean" - } - ], - "responses" : { "200" : { - "description" : "", - "schema" : { - "items" : { "$ref" : "#/definitions/RackUnit" }, - "type" : "array" - } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this rack.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ] - }, - "/dcim/rear-port-templates/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_rear-port-templates_bulk_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, - "get" : { - "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_rear-port-templates_list", - "parameters" : [ - { - "description" : "", - "in" : "query", - "name" : "id", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "name", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "type", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "color", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "positions", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "created", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "created__gte", - "required" : false, - "type" : "string" - }, + "/extras/export-templates/" : { + "delete" : { + "description" : "", + "operationId" : "extras_export-templates_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "extras" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "extras_export-templates_list", + "parameters" : [ { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "content_type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "name", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "description", "required" : false, "type" : "string" }, @@ -35152,42 +45247,42 @@ { "description" : "", "in" : "query", - "name" : "devicetype_id", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "content_type__n", "required" : false, "type" : "string" }, @@ -35264,119 +45359,70 @@ { "description" : "", "in" : "query", - "name" : "type__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "color__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "color__ic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "color__nic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "color__iew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "color__niew", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "color__isw", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "color__nisw", + "name" : "description__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__ie", + "name" : "description__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nie", + "name" : "description__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__empty", + "name" : "description__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "positions__n", + "name" : "description__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "positions__lte", + "name" : "description__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "positions__lt", + "name" : "description__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "positions__gte", + "name" : "description__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "positions__gt", + "name" : "description__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "devicetype_id__n", + "name" : "description__empty", "required" : false, "type" : "string" }, @@ -35411,7 +45457,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/RearPortTemplate" }, + "items" : { "$ref" : "#/definitions/ExportTemplate" }, "type" : "array" } }, @@ -35422,75 +45468,75 @@ "type" : "object" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_rear-port-templates_bulk_partial_update", + "operationId" : "extras_export-templates_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRearPortTemplate" } + "schema" : { "$ref" : "#/definitions/ExportTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPortTemplate" } + "schema" : { "$ref" : "#/definitions/ExportTemplate" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "post" : { "description" : "", - "operationId" : "dcim_rear-port-templates_create", + "operationId" : "extras_export-templates_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRearPortTemplate" } + "schema" : { "$ref" : "#/definitions/ExportTemplate" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPortTemplate" } + "schema" : { "$ref" : "#/definitions/ExportTemplate" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "put" : { "description" : "", - "operationId" : "dcim_rear-port-templates_bulk_update", + "operationId" : "extras_export-templates_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRearPortTemplate" } + "schema" : { "$ref" : "#/definitions/ExportTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPortTemplate" } + "schema" : { "$ref" : "#/definitions/ExportTemplate" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] } }, - "/dcim/rear-port-templates/{id}/" : { + "/extras/export-templates/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_rear-port-templates_delete", + "operationId" : "extras_export-templates_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "get" : { "description" : "", - "operationId" : "dcim_rear-port-templates_read", + "operationId" : "extras_export-templates_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPortTemplate" } + "schema" : { "$ref" : "#/definitions/ExportTemplate" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this rear port template.", + "description" : "A unique integer value identifying this export template.", "in" : "path", "name" : "id", "required" : true, @@ -35498,46 +45544,46 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_rear-port-templates_partial_update", + "operationId" : "extras_export-templates_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRearPortTemplate" } + "schema" : { "$ref" : "#/definitions/ExportTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPortTemplate" } + "schema" : { "$ref" : "#/definitions/ExportTemplate" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "put" : { "description" : "", - "operationId" : "dcim_rear-port-templates_update", + "operationId" : "extras_export-templates_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRearPortTemplate" } + "schema" : { "$ref" : "#/definitions/ExportTemplate" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPortTemplate" } + "schema" : { "$ref" : "#/definitions/ExportTemplate" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] } }, - "/dcim/rear-ports/" : { + "/extras/image-attachments/" : { "delete" : { "description" : "", - "operationId" : "dcim_rear-ports_bulk_delete", + "operationId" : "extras_image-attachments_bulk_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "get" : { "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_rear-ports_list", + "operationId" : "extras_image-attachments_list", "parameters" : [ { "description" : "", @@ -35549,42 +45595,28 @@ { "description" : "", "in" : "query", - "name" : "name", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "label", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "type", + "name" : "content_type_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color", + "name" : "object_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "positions", + "name" : "name", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description", + "name" : "q", "required" : false, "type" : "string" }, @@ -35598,588 +45630,775 @@ { "description" : "", "in" : "query", - "name" : "created__gte", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "created__lte", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "last_updated", + "name" : "content_type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id", + "name" : "content_type_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group", + "name" : "object_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id", + "name" : "object_id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site", + "name" : "object_id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id", + "name" : "object_id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location", + "name" : "object_id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "cabled", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__n", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lte", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__lt", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gte", + "name" : "name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "id__gt", + "name" : "content_type__n", "required" : false, "type" : "string" }, { - "description" : "", + "description" : "Number of results to return per page.", "in" : "query", - "name" : "name__n", + "name" : "limit", "required" : false, - "type" : "string" + "type" : "integer" }, { - "description" : "", + "description" : "The initial index from which to return the results.", "in" : "query", - "name" : "name__ic", + "name" : "offset", "required" : false, - "type" : "string" - }, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/ImageAttachment" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "extras" ] + }, + "parameters" : [ ], + "patch" : { + "description" : "", + "operationId" : "extras_image-attachments_bulk_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/ImageAttachment" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ImageAttachment" } + } }, + "tags" : [ "extras" ] + }, + "post" : { + "description" : "", + "operationId" : "extras_image-attachments_create", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/ImageAttachment" } + } ], + "responses" : { "201" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ImageAttachment" } + } }, + "tags" : [ "extras" ] + }, + "put" : { + "description" : "", + "operationId" : "extras_image-attachments_bulk_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/ImageAttachment" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ImageAttachment" } + } }, + "tags" : [ "extras" ] + } + }, + "/extras/image-attachments/{id}/" : { + "delete" : { + "description" : "", + "operationId" : "extras_image-attachments_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "extras" ] + }, + "get" : { + "description" : "", + "operationId" : "extras_image-attachments_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ImageAttachment" } + } }, + "tags" : [ "extras" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this image attachment.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ], + "patch" : { + "description" : "", + "operationId" : "extras_image-attachments_partial_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/ImageAttachment" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ImageAttachment" } + } }, + "tags" : [ "extras" ] + }, + "put" : { + "description" : "", + "operationId" : "extras_image-attachments_update", + "parameters" : [ { + "in" : "body", + "name" : "data", + "required" : true, + "schema" : { "$ref" : "#/definitions/ImageAttachment" } + } ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/ImageAttachment" } + } }, + "tags" : [ "extras" ] + } + }, + "/extras/job-results/" : { + "get" : { + "description" : "Retrieve a list of job results", + "operationId" : "extras_job-results_list", + "parameters" : [ { "description" : "", "in" : "query", - "name" : "name__nic", + "name" : "id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "created", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "completed", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "status", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "user", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "obj_type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "name", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__n", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__ic", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nic", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__iew", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__niew", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__isw", + "name" : "status__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nisw", + "name" : "user__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__ie", + "name" : "obj_type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__nie", + "name" : "name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "label__empty", + "name" : "name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "type__n", + "name" : "name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__n", + "name" : "name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__ic", + "name" : "name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nic", + "name" : "name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__iew", + "name" : "name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__niew", + "name" : "name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__isw", + "name" : "name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "color__nisw", + "name" : "name__empty", "required" : false, "type" : "string" }, { - "description" : "", + "description" : "Number of results to return per page.", "in" : "query", - "name" : "color__ie", + "name" : "limit", "required" : false, - "type" : "string" + "type" : "integer" }, { - "description" : "", + "description" : "The initial index from which to return the results.", "in" : "query", - "name" : "color__nie", + "name" : "offset", "required" : false, - "type" : "string" - }, + "type" : "integer" + } + ], + "responses" : { "200" : { + "description" : "", + "schema" : { + "properties" : { + "count" : { "type" : "integer" }, + "next" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "previous" : { + "format" : "uri", + "type" : "string", + "x-nullable" : true + }, + "results" : { + "items" : { "$ref" : "#/definitions/JobResult" }, + "type" : "array" + } + }, + "required" : [ + "count", + "results" + ], + "type" : "object" + } + } }, + "tags" : [ "extras" ] + }, + "parameters" : [ ] + }, + "/extras/job-results/{id}/" : { + "get" : { + "description" : "Retrieve a list of job results", + "operationId" : "extras_job-results_read", + "parameters" : [ ], + "responses" : { "200" : { + "description" : "", + "schema" : { "$ref" : "#/definitions/JobResult" } + } }, + "tags" : [ "extras" ] + }, + "parameters" : [ { + "description" : "A unique integer value identifying this job result.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] + }, + "/extras/journal-entries/" : { + "delete" : { + "description" : "", + "operationId" : "extras_journal-entries_bulk_delete", + "parameters" : [ ], + "responses" : { "204" : { "description" : "" } }, + "tags" : [ "extras" ] + }, + "get" : { + "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", + "operationId" : "extras_journal-entries_list", + "parameters" : [ { "description" : "", "in" : "query", - "name" : "color__empty", + "name" : "id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "positions__n", + "name" : "assigned_object_type_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "positions__lte", + "name" : "assigned_object_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "positions__lt", + "name" : "created", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "positions__gte", + "name" : "kind", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "positions__gt", + "name" : "created__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__n", + "name" : "created__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ic", + "name" : "last_updated", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nic", + "name" : "last_updated__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__iew", + "name" : "last_updated__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__niew", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__isw", + "name" : "assigned_object_type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nisw", + "name" : "created_by_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ie", + "name" : "created_by", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nie", + "name" : "id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__empty", + "name" : "id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region_id__n", + "name" : "id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "region__n", + "name" : "id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group_id__n", + "name" : "id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_group__n", + "name" : "assigned_object_type_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site_id__n", + "name" : "assigned_object_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "site__n", + "name" : "assigned_object_id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location_id__n", + "name" : "assigned_object_id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "location__n", + "name" : "assigned_object_id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device_id__n", + "name" : "assigned_object_id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "device__n", + "name" : "kind__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis_id__n", + "name" : "assigned_object_type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "virtual_chassis__n", + "name" : "created_by_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "tag__n", + "name" : "created_by__n", "required" : false, "type" : "string" }, @@ -36214,7 +46433,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/RearPort" }, + "items" : { "$ref" : "#/definitions/JournalEntry" }, "type" : "array" } }, @@ -36225,75 +46444,75 @@ "type" : "object" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "parameters" : [ ], "patch" : { "description" : "", - "operationId" : "dcim_rear-ports_bulk_partial_update", + "operationId" : "extras_journal-entries_bulk_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRearPort" } + "schema" : { "$ref" : "#/definitions/WritableJournalEntry" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPort" } + "schema" : { "$ref" : "#/definitions/JournalEntry" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "post" : { "description" : "", - "operationId" : "dcim_rear-ports_create", + "operationId" : "extras_journal-entries_create", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRearPort" } + "schema" : { "$ref" : "#/definitions/WritableJournalEntry" } } ], "responses" : { "201" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPort" } + "schema" : { "$ref" : "#/definitions/JournalEntry" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "put" : { "description" : "", - "operationId" : "dcim_rear-ports_bulk_update", + "operationId" : "extras_journal-entries_bulk_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRearPort" } + "schema" : { "$ref" : "#/definitions/WritableJournalEntry" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPort" } + "schema" : { "$ref" : "#/definitions/JournalEntry" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] } }, - "/dcim/rear-ports/{id}/" : { + "/extras/journal-entries/{id}/" : { "delete" : { "description" : "", - "operationId" : "dcim_rear-ports_delete", + "operationId" : "extras_journal-entries_delete", "parameters" : [ ], "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "get" : { "description" : "", - "operationId" : "dcim_rear-ports_read", + "operationId" : "extras_journal-entries_read", "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPort" } + "schema" : { "$ref" : "#/definitions/JournalEntry" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this rear port.", + "description" : "A unique integer value identifying this journal entry.", "in" : "path", "name" : "id", "required" : true, @@ -36301,65 +46520,39 @@ } ], "patch" : { "description" : "", - "operationId" : "dcim_rear-ports_partial_update", + "operationId" : "extras_journal-entries_partial_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRearPort" } + "schema" : { "$ref" : "#/definitions/WritableJournalEntry" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPort" } + "schema" : { "$ref" : "#/definitions/JournalEntry" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, "put" : { "description" : "", - "operationId" : "dcim_rear-ports_update", + "operationId" : "extras_journal-entries_update", "parameters" : [ { "in" : "body", "name" : "data", "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRearPort" } + "schema" : { "$ref" : "#/definitions/WritableJournalEntry" } } ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/RearPort" } + "schema" : { "$ref" : "#/definitions/JournalEntry" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] } }, - "/dcim/rear-ports/{id}/paths/" : { - "get" : { - "description" : "Return all CablePaths which traverse a given pass-through port.", - "operationId" : "dcim_rear-ports_paths", - "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/RearPort" } - } }, - "tags" : [ "dcim" ] - }, - "parameters" : [ { - "description" : "A unique integer value identifying this rear port.", - "in" : "path", - "name" : "id", - "required" : true, - "type" : "integer" - } ] - }, - "/dcim/regions/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_regions_bulk_delete", - "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] - }, + "/extras/object-changes/" : { "get" : { - "description" : "Overrides ListModelMixin to allow processing ExportTemplates.", - "operationId" : "dcim_regions_list", + "description" : "Retrieve a list of recent changes.", + "operationId" : "extras_object-changes_list", "parameters" : [ { "description" : "", @@ -36371,84 +46564,77 @@ { "description" : "", "in" : "query", - "name" : "name", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "slug", + "name" : "user", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description", + "name" : "user_name", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created", + "name" : "request_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__gte", + "name" : "action", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "created__lte", + "name" : "changed_object_type_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated", + "name" : "changed_object_id", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__gte", + "name" : "object_repr", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "last_updated__lte", + "name" : "q", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "q", + "name" : "time", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "parent_id", + "name" : "changed_object_type", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "parent", + "name" : "user_id", "required" : false, "type" : "string" }, @@ -36490,224 +46676,210 @@ { "description" : "", "in" : "query", - "name" : "name__n", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "name__ic", - "required" : false, - "type" : "string" - }, - { - "description" : "", - "in" : "query", - "name" : "name__nic", + "name" : "user__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__iew", + "name" : "user_name__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__niew", + "name" : "user_name__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__isw", + "name" : "user_name__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nisw", + "name" : "user_name__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__ie", + "name" : "user_name__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__nie", + "name" : "user_name__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "name__empty", + "name" : "user_name__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__n", + "name" : "user_name__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__ic", + "name" : "user_name__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nic", + "name" : "user_name__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__iew", + "name" : "action__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__niew", + "name" : "changed_object_type_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__isw", + "name" : "changed_object_id__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nisw", + "name" : "changed_object_id__lte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__ie", + "name" : "changed_object_id__lt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__nie", + "name" : "changed_object_id__gte", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "slug__empty", + "name" : "changed_object_id__gt", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__n", + "name" : "object_repr__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ic", + "name" : "object_repr__ic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nic", + "name" : "object_repr__nic", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__iew", + "name" : "object_repr__iew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__niew", + "name" : "object_repr__niew", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__isw", + "name" : "object_repr__isw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nisw", + "name" : "object_repr__nisw", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__ie", + "name" : "object_repr__ie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__nie", + "name" : "object_repr__nie", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "description__empty", + "name" : "object_repr__empty", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "parent_id__n", + "name" : "changed_object_type__n", "required" : false, "type" : "string" }, { "description" : "", "in" : "query", - "name" : "parent__n", + "name" : "user_id__n", "required" : false, "type" : "string" }, @@ -36742,7 +46914,7 @@ "x-nullable" : true }, "results" : { - "items" : { "$ref" : "#/definitions/Region" }, + "items" : { "$ref" : "#/definitions/ObjectChange" }, "type" : "array" } }, @@ -36753,122 +46925,105 @@ "type" : "object" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, - "parameters" : [ ], - "patch" : { - "description" : "", - "operationId" : "dcim_regions_bulk_partial_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRegion" } - } ], + "parameters" : [ ] + }, + "/extras/object-changes/{id}/" : { + "get" : { + "description" : "Retrieve a list of recent changes.", + "operationId" : "extras_object-changes_read", + "parameters" : [ ], "responses" : { "200" : { "description" : "", - "schema" : { "$ref" : "#/definitions/Region" } - } }, - "tags" : [ "dcim" ] - }, - "post" : { - "description" : "", - "operationId" : "dcim_regions_create", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRegion" } - } ], - "responses" : { "201" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Region" } + "schema" : { "$ref" : "#/definitions/ObjectChange" } } }, - "tags" : [ "dcim" ] + "tags" : [ "extras" ] }, - "put" : { - "description" : "", - "operationId" : "dcim_regions_bulk_update", - "parameters" : [ { - "in" : "body", - "name" : "data", - "required" : true, - "schema" : { "$ref" : "#/definitions/WritableRegion" } - } ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Region" } - } }, - "tags" : [ "dcim" ] - } + "parameters" : [ { + "description" : "A unique integer value identifying this object change.", + "in" : "path", + "name" : "id", + "required" : true, + "type" : "integer" + } ] }, - "/dcim/regions/{id}/" : { - "delete" : { - "description" : "", - "operationId" : "dcim_regions_delete", + "/extras/reports/" : { + "get" : { + "description" : "Compile all reports and their related results (if any). Result data is deferred in the list view.", + "operationId" : "extras_reports_list", "parameters" : [ ], - "responses" : { "204" : { "description" : "" } }, - "tags" : [ "dcim" ] + "responses" : { "200" : { "description" : "" } }, + "tags" : [ "extras" ] }, + "parameters" : [ ] + }, + "/extras/reports/{id}/" : { "get" : { - "description" : "", - "operationId" : "dcim_regions_read", + "description" : "Retrieve a single Report identified as \".\".", + "operationId" : "extras_reports_read", "parameters" : [ ], - "responses" : { "200" : { - "description" : "", - "schema" : { "$ref" : "#/definitions/Region" } - } }, - "tags" : [ "dcim" ] + "responses" : { "200" : { "description" : "" } }, + "tags" : [ "extras" ] }, "parameters" : [ { - "description" : "A unique integer value identifying this region.", "in" : "path", "name" : "id", "required" : true, - "type" : "integer" + "type" : "string" + } ] + }, + "/extras/reports/{id}/run/" : { + "parameters" : [ { + "in" : "path", + "name" : "id", + "required" : true, + "type" : "string" } ], - "patch" : { + "post" : { + "description" : "Run a Report identified as \".