From 514f5a88de103a0063562d55093a7a1b5854972b Mon Sep 17 00:00:00 2001 From: Micah Martin <micahlmartin@gmail.com> Date: Sat, 20 Nov 2021 12:06:13 -0500 Subject: [PATCH] Added nextgen connectors --- go.mod | 2 +- go.sum | 2 + harness/cd/graphql/model_delegate_scope.go | 5 + harness/nextgen/README.md | 1102 +- .../nextgen/api_authentication_settings.go | 95 +- harness/nextgen/api_connectors.go | 191 +- harness/nextgen/api_default.go | 25605 ---------------- harness/nextgen/api_enforcement.go | 146 +- harness/nextgen/api_environments.go | 936 + harness/nextgen/api_filter.go | 638 + harness/nextgen/api_full_sync.go | 158 + harness/nextgen/api_gcp_clusters.go | 6 +- harness/nextgen/api_git_branches.go | 302 + harness/nextgen/api_git_sync.go | 633 + harness/nextgen/api_git_sync_entities.go | 447 + harness/nextgen/api_git_sync_errors.go | 652 + harness/nextgen/api_git_sync_settings.go | 362 + harness/nextgen/api_invite.go | 1064 + harness/nextgen/api_licenses.go | 216 +- harness/nextgen/api_organization.go | 44 +- harness/nextgen/api_project.go | 42 +- harness/nextgen/api_scm.go | 671 + harness/nextgen/api_services.go | 1054 + harness/nextgen/api_source_code_manager.go | 474 + harness/nextgen/api_users.go | 124 + harness/nextgen/client.go | 46 +- .../nextgen/enum_app_dynamics_auth_types.go | 20 + .../nextgen/enum_aws_kms_credential_type.go | 23 + .../enum_aws_secret_manager_auth_types.go | 23 + .../enum_bitbucket_api_access_types.go | 17 + .../enum_bitbucket_http_credential_types.go | 17 + ...or_type.go => enum_git_connector_types.go} | 0 .../nextgen/enum_github_api_access_types.go | 20 + .../enum_github_http_credential_types.go | 17 + harness/nextgen/enum_gitlab_api_auth_types.go | 17 + .../enum_gitlab_http_credential_types.go | 20 + .../nextgen/enum_kubernetes_auth_methods.go | 14 +- harness/nextgen/model_account.go | 2 +- harness/nextgen/model_account_license.go | 2 +- .../nextgen/model_aggregate_acl_request.go | 16 - .../nextgen/model_api_key_aggregate_dto.go | 17 - harness/nextgen/model_api_key_dto.go | 23 - .../model_app_dynamics_connector_dto.go | 16 +- harness/nextgen/model_artifact_summary.go | 15 - ... => model_artifactory_auth_credentials.go} | 4 +- ...go => model_artifactory_authentication.go} | 9 +- ...l_artifactory_authentication_serializer.go | 16 +- ...nfig.go => model_artifactory_connector.go} | 10 +- .../model_artifactory_connector_dto.go | 16 - ...odel_artifactory_username_password_auth.go | 17 + harness/nextgen/model_artifacts_summary.go | 15 - ...icationsettings_samlmetadataupload_body.go | 1 + ...ationsettings_samlmetadataupload_body_1.go | 1 + harness/nextgen/model_author_info.go | 15 - ...g.go => model_availability_restriction.go} | 8 +- ...odel_availability_restriction_metadata.go} | 3 +- .../model_aws_code_commit_authentication.go | 16 + ...odel_aws_code_commit_authentication_dto.go | 15 - ....go => model_aws_code_commit_connector.go} | 12 +- ...o => model_aws_code_commit_credentials.go} | 4 +- ...model_aws_code_commit_https_credentials.go | 16 + ...l_aws_code_commit_https_credentials_dto.go | 15 - ..._aws_code_commit_https_credentials_spec.go | 14 + ..._code_commit_https_credentials_spec_dto.go | 13 - ..._aws_code_commit_secret_key_access_key.go} | 3 +- ...snippets_dto.go => model_aws_connector.go} | 6 +- harness/nextgen/model_aws_connector_dto.go | 15 - harness/nextgen/model_aws_credential.go | 20 + harness/nextgen/model_aws_credential_dto.go | 21 - .../model_aws_credential_serializer.go | 20 +- ...detail.go => model_aws_credential_spec.go} | 3 +- .../nextgen/model_aws_credential_spec_dto.go | 13 - harness/nextgen/model_aws_kms_config_dto.go | 24 - .../model_aws_kms_connector_credential_dto.go | 9 +- ...aws_kms_connector_credential_serializer.go | 61 + .../model_aws_kms_credential_spec_config.go | 13 - .../model_aws_kms_manual_credential_config.go | 15 - ...dto.go => model_aws_manual_config_spec.go} | 3 +- ...model_aws_secret_manager_credential_dto.go | 9 +- ...ws_secret_manager_credential_serializer.go | 61 + .../model_azure_key_vault_config_dto.go | 30 - harness/nextgen/model_barrier_info_config.go | 15 - .../nextgen/model_base_aws_kms_config_dto.go | 18 - harness/nextgen/model_bitbucket_api_access.go | 19 + .../nextgen/model_bitbucket_api_access_dto.go | 15 - .../model_bitbucket_api_access_serializer.go | 53 + .../model_bitbucket_api_access_spec_dto.go | 13 - .../nextgen/model_bitbucket_authentication.go | 20 + .../model_bitbucket_authentication_dto.go | 15 - ...del_bitbucket_authentication_serializer.go | 57 + .../model_bitbucket_cloud_webhook_events.go | 25 - ...tbucket_cloud_webhook_events_or_builder.go | 22 - ...or_dto.go => model_bitbucket_connector.go} | 9 +- .../nextgen/model_bitbucket_connector_dto.go | 19 - .../nextgen/model_bitbucket_credentials.go | 14 + .../model_bitbucket_credentials_dto.go | 13 - .../model_bitbucket_http_credentials.go | 19 + .../model_bitbucket_http_credentials_dto.go | 15 - ...l_bitbucket_http_credentials_serializer.go | 53 + .../model_bitbucket_http_credentials_spec.go | 14 + ...del_bitbucket_http_credentials_spec_dto.go | 13 - .../model_bitbucket_server_webhook_events.go | 25 - ...bucket_server_webhook_events_or_builder.go | 22 - ....go => model_bitbucket_ssh_credentials.go} | 3 +- .../model_bitbucket_username_password.go | 17 + ...el_bitbucket_username_token_api_access.go} | 3 +- .../model_build_id_and_instance_count.go | 15 - harness/nextgen/model_byte_string.go | 15 - harness/nextgen/model_cd_license_summary.go | 20 + harness/nextgen/model_cd_module_license.go | 27 + .../nextgen/model_cd_pipeline_module_info.go | 18 - harness/nextgen/model_cd_stage_module_info.go | 16 - harness/nextgen/model_ce_aws_connector_dto.go | 8 +- ...ary_dto.go => model_ce_license_summary.go} | 3 +- ...ense_dto.go => model_ce_module_license.go} | 3 +- ...ary_dto.go => model_cf_license_summary.go} | 3 +- ...ense_dto.go => model_cf_module_license.go} | 3 +- .../nextgen/model_check_expiry_result_dto.go | 15 - ...ary_dto.go => model_ci_license_summary.go} | 3 +- ...ense_dto.go => model_ci_module_license.go} | 3 +- .../model_connected_argo_git_ops_info_dto.go | 15 - .../model_connectivity_check_summary_dto.go | 17 - harness/nextgen/model_connector.go | 2 +- harness/nextgen/model_connector_config.go | 14 + harness/nextgen/model_connector_config_dto.go | 13 - harness/nextgen/model_connector_info.go | 48 + harness/nextgen/model_connector_info_dto.go | 34 - .../model_connector_info_serializer.go | 100 +- harness/nextgen/model_connector_response.go | 2 +- ...e_invite_dto.go => model_create_invite.go} | 3 +- ...del_create_prdto.go => model_create_pr.go} | 3 +- ...s_dto.go => model_cross_account_access.go} | 3 +- .../model_custom_health_connector_dto.go | 20 + .../model_custom_health_key_and_value.go | 18 + harness/nextgen/model_custom_restriction.go | 15 + .../nextgen/model_custom_restriction_dto.go | 13 - ...model_custom_restriction_evaluation_dto.go | 17 - ...o => model_custom_restriction_metadata.go} | 3 +- ...ary_dto.go => model_cv_license_summary.go} | 3 +- ...ense_dto.go => model_cv_module_license.go} | 3 +- .../model_dashboard_execution_status_info.go | 16 - .../model_dashboard_workload_deployment.go | 14 - harness/nextgen/model_decryptable_entity.go | 13 - ...ptable_entity_with_encryption_consumers.go | 15 - .../nextgen/model_delegate_configuration.go | 1 + .../nextgen/model_delegate_response_data.go | 14 - harness/nextgen/model_deployment.go | 14 - .../nextgen/model_deployment_change_rates.go | 17 - harness/nextgen/model_deployment_count.go | 16 - .../model_deployment_date_and_count.go | 15 - .../nextgen/model_deployment_stats_summary.go | 20 - harness/nextgen/model_deployments_info.go | 14 - harness/nextgen/model_descriptor.go | 26 - harness/nextgen/model_descriptor_proto.go | 49 - .../model_descriptor_proto_or_builder.go | 44 - .../nextgen/model_docker_auth_credentials.go | 14 + .../model_docker_auth_credentials_dto.go | 13 - ...umer.go => model_docker_authentication.go} | 10 +- .../model_docker_authentication_serializer.go | 16 +- .../nextgen/model_docker_build_details_dto.go | 18 - ...ponse_dto.go => model_docker_connector.go} | 10 +- harness/nextgen/model_docker_connector_dto.go | 17 - harness/nextgen/model_docker_request_dto.go | 16 - harness/nextgen/model_docker_response_dto.go | 14 - ....go => model_docker_user_name_password.go} | 3 +- ...mmary.go => model_duration_restriction.go} | 7 +- .../nextgen/model_duration_restriction_dto.go | 14 - ...=> model_duration_restriction_metadata.go} | 3 +- .../nextgen/model_ecr_build_details_dto.go | 18 - harness/nextgen/model_ecr_list_images_dto.go | 14 - harness/nextgen/model_ecr_request_dto.go | 17 - harness/nextgen/model_ecr_response_dto.go | 14 - ..._action_dto.go => model_edition_action.go} | 3 +- harness/nextgen/model_email_config_dto.go | 15 - .../nextgen/model_encrypted_data_detail.go | 17 - .../nextgen/model_encrypted_data_params.go | 15 - .../nextgen/model_encrypted_record_data.go | 27 - harness/nextgen/model_encryption_config.go | 23 - harness/nextgen/model_entity_detail.go | 16 - .../nextgen/model_entity_references_dto.go | 14 - ...referred_by_pipeline_setup_usage_detail.go | 16 - .../model_entity_setup_usage_batch_dto.go | 15 - .../nextgen/model_entity_setup_usage_dto.go | 18 - harness/nextgen/model_enum_descriptor.go | 21 - .../nextgen/model_enum_descriptor_proto.go | 34 - .../model_enum_descriptor_proto_or_builder.go | 31 - harness/nextgen/model_enum_options.go | 28 - .../nextgen/model_enum_options_or_builder.go | 24 - harness/nextgen/model_enum_reserved_range.go | 24 - .../model_enum_reserved_range_or_builder.go | 21 - .../nextgen/model_enum_value_descriptor.go | 21 - .../model_enum_value_descriptor_proto.go | 27 - ..._enum_value_descriptor_proto_or_builder.go | 24 - harness/nextgen/model_enum_value_options.go | 27 - .../model_enum_value_options_or_builder.go | 23 - ...el_env_build_id_and_instance_count_info.go | 16 - ...v_build_id_and_instance_count_info_list.go | 14 - harness/nextgen/model_env_count.go | 15 - harness/nextgen/model_env_id_count_pair.go | 15 - ...st_dto.go => model_environment_request.go} | 3 +- harness/nextgen/model_environment_response.go | 6 +- .../nextgen/model_environment_response_dto.go | 24 - harness/nextgen/model_error.go | 1 + harness/nextgen/model_execution_deployment.go | 15 - .../model_execution_deployment_info.go | 14 - .../nextgen/model_execution_status_info.go | 23 - harness/nextgen/model_extension_range.go | 26 - .../nextgen/model_extension_range_options.go | 26 - ...odel_extension_range_options_or_builder.go | 22 - .../model_extension_range_or_builder.go | 23 - ...feature_restriction_detail_list_request.go | 15 + ...odel_feature_restriction_detail_request.go | 2 +- .../model_feature_restriction_details.go | 14 +- .../model_feature_restriction_metadata.go | 10 +- .../model_feature_restriction_usage_dto.go | 14 - harness/nextgen/model_field_descriptor.go | 38 - .../nextgen/model_field_descriptor_proto.go | 38 - ...model_field_descriptor_proto_or_builder.go | 35 - harness/nextgen/model_field_options.go | 32 - .../nextgen/model_field_options_or_builder.go | 28 - harness/nextgen/model_file_descriptor.go | 26 - .../nextgen/model_file_descriptor_proto.go | 50 - harness/nextgen/model_file_options.go | 56 - .../nextgen/model_file_options_or_builder.go | 52 - .../nextgen/model_files_identifier_body.go | 15 - harness/nextgen/model_filter_dto.go | 19 - ...ties_dto.go => model_filter_properties.go} | 3 +- harness/nextgen/model_flow_control_config.go | 14 - ...gate_dto.go => model_full_sync_request.go} | 12 +- ...dd_users_dto.go => model_gcp_connector.go} | 8 +- ...o.go => model_gcp_connector_credential.go} | 11 +- ...del_gcp_connector_credential_serializer.go | 16 +- harness/nextgen/model_gcp_connector_dto.go | 15 - ...ls_dto.go => model_gcp_credential_spec.go} | 3 +- .../nextgen/model_gcp_credential_spec_dto.go | 13 - harness/nextgen/model_gcp_kms_config_dto.go | 29 - ...ils_dto.go => model_gcp_manual_details.go} | 3 +- .../nextgen/model_gcr_build_details_dto.go | 18 - harness/nextgen/model_gcr_request_dto.go | 17 - harness/nextgen/model_gcr_response_dto.go | 14 - ...pec_dto.go => model_git_authentication.go} | 3 +- .../nextgen/model_git_authentication_dto.go | 14 - ..._git_branch_dto.go => model_git_branch.go} | 3 +- ...y_list_dto.go => model_git_branch_list.go} | 8 +- harness/nextgen/model_git_branch_list_dto.go | 15 - ..._git_config_dto.go => model_git_config.go} | 11 +- .../nextgen/model_git_config_serializer.go | 16 +- ...it_enabled_dto.go => model_git_enabled.go} | 3 +- ...model_git_entity_branch_summary_filter.go} | 3 +- ....go => model_git_entity_summary_filter.go} | 3 +- .../model_git_http_authentication_dto.go | 2 +- harness/nextgen/model_git_info.go | 19 - harness/nextgen/model_git_ops_info_dto.go | 14 - harness/nextgen/model_git_ops_provider_dto.go | 20 - .../model_git_ops_provider_response_dto.go | 20 - ...dto.go => model_git_ssh_authentication.go} | 4 +- harness/nextgen/model_git_sync_config.go | 23 + harness/nextgen/model_git_sync_config_dto.go | 22 - ...entity_dto.go => model_git_sync_entity.go} | 3 +- ...s_dto.go => model_git_sync_entity_list.go} | 10 +- harness/nextgen/model_git_sync_error.go | 26 + ...odel_git_sync_error_aggregate_by_commit.go | 21 + ..._git_sync_error_aggregate_by_commit_dto.go | 20 - ...t_dto.go => model_git_sync_error_count.go} | 3 +- .../nextgen/model_git_sync_error_details.go | 14 + .../model_git_sync_error_details_dto.go | 13 - harness/nextgen/model_git_sync_error_dto.go | 25 - ...dto.go => model_git_sync_folder_config.go} | 3 +- harness/nextgen/model_git_sync_repo_files.go | 16 + .../nextgen/model_git_sync_repo_files_dto.go | 15 - ...o.go => model_git_sync_repo_files_list.go} | 12 +- .../model_git_sync_repo_files_list_dto.go | 15 - ...ings_dto.go => model_git_sync_settings.go} | 3 +- harness/nextgen/model_github_api_access.go | 20 + .../nextgen/model_github_api_access_dto.go | 15 - .../model_github_api_access_serializer.go | 57 + .../nextgen/model_github_api_access_spec.go | 14 + .../model_github_api_access_spec_dto.go | 13 - ...p_spec_dto.go => model_github_app_spec.go} | 3 +- .../nextgen/model_github_authentication.go | 20 + .../model_github_authentication_dto.go | 15 - .../model_github_authentication_serializer.go | 57 + harness/nextgen/model_github_connector.go | 21 + harness/nextgen/model_github_connector_dto.go | 20 - ...als_dto.go => model_github_credentials.go} | 3 +- .../nextgen/model_github_credentials_dto.go | 13 - ...to.go => model_github_http_credentials.go} | 13 +- .../model_github_http_credentials_dto.go | 15 - ...odel_github_http_credentials_serializer.go | 53 + .../model_github_http_credentials_spec.go | 14 + .../model_github_http_credentials_spec_dto.go | 13 - ...dto.go => model_github_ssh_credentials.go} | 3 +- ...spec_dto.go => model_github_token_spec.go} | 3 +- .../nextgen/model_github_username_password.go | 17 + ..._dto.go => model_github_username_token.go} | 3 +- .../nextgen/model_github_webhook_events.go | 25 - .../model_github_webhook_events_or_builder.go | 22 - ...tial_dto.go => model_gitlab_api_access.go} | 13 +- .../nextgen/model_gitlab_api_access_dto.go | 15 - .../model_gitlab_api_access_serializer.go | 53 + .../nextgen/model_gitlab_api_access_spec.go | 14 + .../model_gitlab_api_access_spec_dto.go | 13 - .../nextgen/model_gitlab_authentication.go | 20 + .../model_gitlab_authentication_dto.go | 15 - .../model_gitlab_authentication_serializer.go | 57 + harness/nextgen/model_gitlab_connector.go | 20 + harness/nextgen/model_gitlab_credentials.go | 14 + .../nextgen/model_gitlab_credentials_dto.go | 13 - ...to.go => model_gitlab_http_credentials.go} | 13 +- .../model_gitlab_http_credentials_dto.go | 15 - ...odel_gitlab_http_credentials_serializer.go | 57 + .../model_gitlab_http_credentials_spec.go | 14 + .../model_gitlab_http_credentials_spec_dto.go | 13 - ...rberos_dto.go => model_gitlab_kerberos.go} | 3 +- ...dto.go => model_gitlab_ssh_credentials.go} | 4 +- harness/nextgen/model_gitlab_token_spec.go | 15 + .../nextgen/model_gitlab_username_password.go | 17 + .../model_gitlab_username_password_dto.go | 16 - ..._dto.go => model_gitlab_username_token.go} | 3 +- .../nextgen/model_gitlab_webhook_events.go | 25 - .../model_gitlab_webhook_events_or_builder.go | 22 - .../nextgen/model_harness_service_info_ng.go | 18 - .../model_health_deployment_dashboard.go | 14 - .../nextgen/model_health_deployment_info.go | 16 - ...go => model_http_helm_auth_credentials.go} | 4 +- .../model_http_helm_auth_credentials_dto.go | 13 - .../nextgen/model_http_helm_authentication.go | 19 + ...del_http_helm_authentication_serializer.go | 16 +- ...or_dto.go => model_http_helm_connector.go} | 8 +- .../nextgen/model_http_helm_connector_dto.go | 16 - ...o => model_http_helm_username_password.go} | 3 +- .../model_http_helm_username_password_dto.go | 16 - .../nextgen/model_infra_execution_summary.go | 16 - .../nextgen/model_infrastructure_details.go | 14 - harness/nextgen/model_input_set_validator.go | 15 - ...instance_count_details_by_env_type_base.go | 17 - .../model_instance_details_by_build_id.go | 15 - harness/nextgen/model_instance_details_dto.go | 22 - .../model_instances_by_build_id_list.go | 14 - .../{model_invite_dto.go => model_invite.go} | 3 +- ...nnector_dto.go => model_jira_connector.go} | 3 +- .../model_jira_field_allowed_value_ng.go | 16 - harness/nextgen/model_jira_field_ng.go | 20 - harness/nextgen/model_jira_field_schema_ng.go | 17 - .../model_jira_issue_create_metadata_ng.go | 14 - harness/nextgen/model_jira_issue_type_ng.go | 19 - .../model_jira_issue_update_metadata_ng.go | 14 - .../nextgen/model_jira_project_basic_ng.go | 16 - harness/nextgen/model_jira_project_ng.go | 17 - .../nextgen/model_jira_status_category_ng.go | 16 - harness/nextgen/model_json_node.go | 34 - .../model_k8s_infrastructure_details.go | 16 - harness/nextgen/model_kerberos_config_dto.go | 18 - harness/nextgen/model_kubernetes_auth.go | 22 + ...go => model_kubernetes_auth_credential.go} | 4 +- .../model_kubernetes_auth_credential_dto.go | 13 - harness/nextgen/model_kubernetes_auth_dto.go | 23 - .../model_kubernetes_auth_serializer.go | 24 +- ...go => model_kubernetes_client_key_cert.go} | 3 +- .../model_kubernetes_cluster_config.go | 16 + .../model_kubernetes_cluster_config_dto.go | 15 - .../model_kubernetes_cluster_details.go | 16 + .../model_kubernetes_cluster_details_dto.go | 15 - .../nextgen/model_kubernetes_credential.go | 19 + .../model_kubernetes_credential_serializer.go | 20 +- ...go => model_kubernetes_credential_spec.go} | 4 +- .../model_kubernetes_credential_spec_dto.go | 13 - ...go => model_kubernetes_open_id_connect.go} | 3 +- ...go => model_kubernetes_service_account.go} | 3 +- ...=> model_kubernetes_user_name_password.go} | 3 +- ...model_kubernetes_user_name_password_dto.go | 16 - harness/nextgen/model_last_workload_info.go | 17 - harness/nextgen/model_local_config_dto.go | 23 - harness/nextgen/model_location.go | 32 - harness/nextgen/model_location_or_builder.go | 29 - .../model_managed_argo_git_ops_info_dto.go | 15 - harness/nextgen/model_message.go | 21 - harness/nextgen/model_message_lite.go | 17 - harness/nextgen/model_message_options.go | 30 - .../model_message_options_or_builder.go | 26 - harness/nextgen/model_method_descriptor.go | 24 - .../nextgen/model_method_descriptor_proto.go | 32 - ...odel_method_descriptor_proto_or_builder.go | 29 - harness/nextgen/model_method_options.go | 28 - .../model_method_options_or_builder.go | 24 - .../model_microsoft_teams_config_dto.go | 15 - harness/nextgen/model_name_part.go | 25 - harness/nextgen/model_name_part_or_builder.go | 22 - harness/nextgen/model_native_events.go | 31 - .../nextgen/model_native_events_or_builder.go | 28 - .../nextgen/model_nexus_auth_credentials.go | 14 + .../model_nexus_auth_credentials_dto.go | 13 - ...n_dto.go => model_nexus_authentication.go} | 11 +- .../nextgen/model_nexus_authentication_dto.go | 20 - .../model_nexus_authentication_serializer.go | 16 +- ...t_response.go => model_nexus_connector.go} | 10 +- ... => model_nexus_username_password_auth.go} | 3 +- .../model_nexus_username_password_auth_dto.go | 16 - harness/nextgen/model_ng_access.go | 17 - harness/nextgen/model_ng_activity_dto.go | 20 - .../nextgen/model_ng_activity_summary_dto.go | 19 - harness/nextgen/model_ng_properties.go | 14 - harness/nextgen/model_ng_tag.go | 15 - harness/nextgen/model_ng_variable.go | 19 - .../model_notification_channel_wrapper.go | 15 - harness/nextgen/model_notification_rules.go | 17 - .../model_notification_setting_config.go | 14 - .../model_notification_setting_config_dto.go | 14 - harness/nextgen/model_number_ng_variable.go | 21 - harness/nextgen/model_o_auth_signup_dto.go | 16 - harness/nextgen/model_oneof_descriptor.go | 22 - .../nextgen/model_oneof_descriptor_proto.go | 26 - ...model_oneof_descriptor_proto_or_builder.go | 23 - harness/nextgen/model_oneof_options.go | 26 - .../nextgen/model_oneof_options_or_builder.go | 22 - .../nextgen/model_org_project_identifier.go | 15 - .../model_organization_aggregate_dto.go | 21 - .../model_page_entity_setup_usage_dto.go | 24 - harness/nextgen/model_page_ng_activity_dto.go | 24 - .../model_page_ng_activity_summary_dto.go | 24 - ...del_page_response_api_key_aggregate_dto.go | 20 - ..._page_response_environment_response_dto.go | 20 - harness/nextgen/model_page_response_filter.go | 20 + ...o.go => model_page_response_git_branch.go} | 4 +- ..._response_git_ops_provider_response_dto.go | 20 - ...del_page_response_git_sync_entity_list.go} | 4 +- ..._page_response_git_sync_entity_list_dto.go | 20 - ... => model_page_response_git_sync_error.go} | 4 +- ...onse_git_sync_error_aggregate_by_commit.go | 20 + ..._git_sync_error_aggregate_by_commit_dto.go | 20 - .../model_page_response_git_sync_error_dto.go | 20 - harness/nextgen/model_page_response_invite.go | 20 + .../nextgen/model_page_response_invite_dto.go | 20 - ...age_response_organization_aggregate_dto.go | 20 - .../nextgen/model_page_response_project.go | 20 - ...del_page_response_project_aggregate_dto.go | 20 - ..._page_response_role_assignment_response.go | 20 - ...l_page_response_secret_response_wrapper.go | 20 - ..._response_service_account_aggregate_dto.go | 20 - ...odel_page_response_service_response_dto.go | 20 - .../model_page_response_user_aggregate_dto.go | 20 - ..._page_response_user_group_aggregate_dto.go | 20 - .../model_page_response_user_group_dto.go | 20 - .../model_page_response_user_metadata_dto.go | 20 - harness/nextgen/model_pageable.go | 19 - .../nextgen/model_pager_duty_config_dto.go | 15 - .../nextgen/model_parameter_field_double.go | 20 - ...eter_field_notification_channel_wrapper.go | 20 - .../nextgen/model_parameter_field_object.go | 20 - .../model_parameter_field_secret_ref_data.go | 20 - .../nextgen/model_parameter_field_string.go | 20 - .../nextgen/model_parameter_field_timeout.go | 20 - harness/nextgen/model_parser.go | 13 - ...l_parser_bitbucket_cloud_webhook_events.go | 13 - ..._parser_bitbucket_server_webhook_events.go | 13 - .../nextgen/model_parser_descriptor_proto.go | 13 - .../model_parser_enum_descriptor_proto.go | 13 - harness/nextgen/model_parser_enum_options.go | 13 - .../model_parser_enum_reserved_range.go | 13 - ...odel_parser_enum_value_descriptor_proto.go | 13 - .../model_parser_enum_value_options.go | 13 - .../nextgen/model_parser_extension_range.go | 13 - .../model_parser_extension_range_options.go | 13 - .../model_parser_field_descriptor_proto.go | 13 - harness/nextgen/model_parser_field_options.go | 13 - .../model_parser_file_descriptor_proto.go | 13 - harness/nextgen/model_parser_file_options.go | 13 - .../model_parser_github_webhook_events.go | 13 - .../model_parser_gitlab_webhook_events.go | 13 - harness/nextgen/model_parser_location.go | 13 - harness/nextgen/model_parser_message.go | 13 - harness/nextgen/model_parser_message_lite.go | 13 - .../nextgen/model_parser_message_options.go | 13 - .../model_parser_method_descriptor_proto.go | 13 - .../nextgen/model_parser_method_options.go | 13 - harness/nextgen/model_parser_name_part.go | 13 - harness/nextgen/model_parser_native_events.go | 13 - .../model_parser_oneof_descriptor_proto.go | 13 - harness/nextgen/model_parser_oneof_options.go | 13 - .../nextgen/model_parser_reserved_range.go | 13 - .../model_parser_service_descriptor_proto.go | 13 - .../nextgen/model_parser_service_options.go | 13 - .../nextgen/model_parser_source_code_info.go | 13 - .../model_parser_uninterpreted_option.go | 13 - .../nextgen/model_parser_webhook_response.go | 13 - harness/nextgen/model_partial_schema_dto.go | 18 - harness/nextgen/model_password_change_dto.go | 15 - harness/nextgen/model_pipeline_config.go | 14 - harness/nextgen/model_pipeline_event.go | 15 - ...model_pipeline_execution_dashboard_info.go | 20 - harness/nextgen/model_pipeline_info_config.go | 26 - ...odel_pipelines_execution_dashboard_info.go | 17 - harness/nextgen/model_pms_email_channel.go | 16 - harness/nextgen/model_pms_ms_team_channel.go | 16 - .../nextgen/model_pms_notification_channel.go | 14 - .../nextgen/model_pms_pager_duty_channel.go | 16 - harness/nextgen/model_pms_slack_channel.go | 16 - harness/nextgen/model_polling_response_dto.go | 14 - harness/nextgen/model_principal.go | 15 - .../nextgen/model_project_aggregate_dto.go | 18 - .../nextgen/model_project_dash_board_info.go | 20 - .../nextgen/model_projects_dashboard_info.go | 14 - .../nextgen/model_rate_limit_protection.go | 17 + .../nextgen/model_rate_limit_restriction.go | 18 + .../model_rate_limit_restriction_dto.go | 16 - ... model_rate_limit_restriction_metadata.go} | 3 +- harness/nextgen/model_reserved_range.go | 24 - .../model_reserved_range_or_builder.go | 21 - harness/nextgen/model_resource_group.go | 15 - ...odel_response_dto_account_resources_dto.go | 17 - ..._response_dto_active_projects_count_dto.go | 17 - ...nse_dto_active_service_instance_summary.go | 17 - .../model_response_dto_add_users_response.go | 17 - ...el_response_dto_check_expiry_result_dto.go | 17 - ...onse_dto_connectivity_check_summary_dto.go | 17 - ...ode.go => model_response_dto_create_pr.go} | 4 +- .../model_response_dto_create_prdto.go | 17 - ...nse_dto_dashboard_execution_status_info.go | 17 - ...ponse_dto_dashboard_workload_deployment.go | 17 - .../model_response_dto_decryptable_entity.go | 17 - ...l_response_dto_deployment_stats_summary.go | 17 - ...l_response_dto_docker_build_details_dto.go | 17 - .../model_response_dto_docker_response_dto.go | 17 - .../model_response_dto_ecr_list_images_dto.go | 17 - .../model_response_dto_ecr_response_dto.go | 17 - ...odel_response_dto_entity_references_dto.go | 17 - ...del_response_dto_entity_setup_usage_dto.go | 17 - ...v_build_id_and_instance_count_info_list.go | 17 - ...l_response_dto_environment_response_dto.go | 17 - ...sponse_dto_feature_restriction_metadata.go | 17 - ...ponse_dto_feature_restriction_usage_dto.go | 17 - ...en_dto.go => model_response_dto_filter.go} | 4 +- .../nextgen/model_response_dto_filter_dto.go | 17 - .../model_response_dto_gcr_response_dto.go | 17 - ... => model_response_dto_git_branch_list.go} | 4 +- .../model_response_dto_git_branch_list_dto.go | 17 - ...ponse_dto_git_ops_provider_response_dto.go | 17 - ...odel_response_dto_git_sync_error_count.go} | 4 +- ...l_response_dto_git_sync_error_count_dto.go | 17 - ..._response_dto_git_sync_repo_files_list.go} | 4 +- ...sponse_dto_git_sync_repo_files_list_dto.go | 17 - ...> model_response_dto_git_sync_settings.go} | 4 +- ...esponse_dto_health_deployment_dashboard.go | 17 - ...response_dto_instances_by_build_id_list.go | 17 - ..._count.go => model_response_dto_invite.go} | 4 +- .../nextgen/model_response_dto_invite_dto.go | 17 - ...ponse_dto_jira_issue_create_metadata_ng.go | 17 - .../model_response_dto_list_api_key_dto.go | 17 - ...response_dto_list_encrypted_data_detail.go | 17 - ...esponse_dto_list_entity_setup_usage_dto.go | 17 - ...odel_response_dto_list_execution_status.go | 17 - ...response_dto_list_git_sync_entity_list.go} | 4 +- ...ponse_dto_list_git_sync_entity_list_dto.go | 17 - ...response_dto_list_jira_project_basic_ng.go | 17 - .../model_response_dto_list_jira_status_ng.go | 17 - .../model_response_dto_list_project.go | 17 - ...ponse_dto_list_role_assignment_response.go | 17 - ...l_response_dto_list_service_account_dto.go | 17 - ...sponse_dto_list_service_definition_type.go | 17 - ..._response_dto_list_source_code_manager.go} | 4 +- ...sponse_dto_list_source_code_manager_dto.go | 17 - ...ponse_dto_list_user_group_aggregate_dto.go | 17 - .../model_response_dto_list_user_group_dto.go | 17 - ...nse_dto_map_edition_set_edition_action.go} | 4 +- ..._dto_map_edition_set_edition_action_dto.go | 17 - ...odel_response_dto_map_module_type_long.go} | 4 +- ...ition_type_list_execution_strategy_type.go | 17 - .../model_response_dto_map_string_string.go | 17 - ...se_dto_optional_harness_service_info_ng.go | 17 - ... => model_response_dto_optional_invite.go} | 4 +- .../model_response_dto_optional_invite_dto.go | 17 - ...esponse_dto_page_entity_setup_usage_dto.go | 17 - ...sponse_dto_page_ng_activity_summary_dto.go | 17 - ...dto_page_response_api_key_aggregate_dto.go | 17 - ..._page_response_environment_response_dto.go | 17 - ...odel_response_dto_page_response_filter.go} | 4 +- ...l_response_dto_page_response_filter_dto.go | 17 - ..._response_git_ops_provider_response_dto.go | 17 - ...dto_page_response_git_sync_entity_list.go} | 4 +- ..._page_response_git_sync_entity_list_dto.go | 17 - ...ponse_dto_page_response_git_sync_error.go} | 4 +- ...nse_git_sync_error_aggregate_by_commit.go} | 4 +- ..._git_sync_error_aggregate_by_commit_dto.go | 17 - ...se_dto_page_response_git_sync_error_dto.go | 17 - ...odel_response_dto_page_response_invite.go} | 4 +- ...l_response_dto_page_response_invite_dto.go | 17 - ...age_response_organization_aggregate_dto.go | 17 - ...odel_response_dto_page_response_project.go | 17 - ...dto_page_response_project_aggregate_dto.go | 17 - ..._page_response_role_assignment_response.go | 17 - ...o_page_response_secret_response_wrapper.go | 17 - ..._response_service_account_aggregate_dto.go | 17 - ..._dto_page_response_service_response_dto.go | 17 - ...se_dto_page_response_user_aggregate_dto.go | 17 - ..._page_response_user_group_aggregate_dto.go | 17 - ...sponse_dto_page_response_user_group_dto.go | 17 - ...nse_dto_page_response_user_metadata_dto.go | 17 - .../model_response_dto_partial_schema_dto.go | 17 - ...l_response_dto_password_change_response.go | 17 - .../model_response_dto_pipeline_config.go | 17 - ..._dto_pipelines_execution_dashboard_info.go | 17 - ...model_response_dto_polling_response_dto.go | 17 - ...odel_response_dto_project_aggregate_dto.go | 17 - ...el_response_dto_projects_dashboard_info.go | 17 - ...o_restriction_metadata_map_response_dto.go | 17 - ..._dto_role_assignment_aggregate_response.go | 17 - ...l_response_dto_role_assignment_response.go | 17 - ..._response_dto_secret_manager_config_dto.go | 17 - ...el_response_dto_secret_response_wrapper.go | 17 - ...sponse_dto_secret_validation_result_dto.go | 17 - ...ponse_dto_service_account_aggregate_dto.go | 17 - ...esponse_dto_service_deployment_info_dto.go | 17 - ...sponse_dto_service_deployment_list_info.go | 17 - ...l_response_dto_service_details_info_dto.go | 17 - .../model_response_dto_service_header_info.go | 17 - ...model_response_dto_service_response_dto.go | 17 - ...el_response_dto_services_dashboard_info.go | 17 - ...model_response_dto_source_code_manager.go} | 4 +- .../model_response_dto_step_category.go | 17 - ...e_value_pair_list_dto_env_id_count_pair.go | 17 - ...se_dto_time_value_pair_list_dto_integer.go | 17 - ...esponse_dto_trigger_full_sync_response.go} | 4 +- ...ponse_dto_two_factor_auth_settings_info.go | 17 - ...esponse_dto_upsert_webhook_response_dto.go | 17 - .../model_response_dto_user_aggregate_dto.go | 17 - ...l_response_dto_user_group_aggregate_dto.go | 17 - .../model_response_dto_user_group_dto.go | 17 - ...del_response_dtocd_pipeline_module_info.go | 17 - .../model_response_dtocd_stage_module_info.go | 17 - .../model_response_dtong_activity_dto.go | 17 - .../nextgen/model_rest_response_user_group.go | 16 - .../nextgen/model_rest_response_user_info.go | 16 - harness/nextgen/model_restriction.go | 15 + harness/nextgen/model_restriction_dto.go | 13 - ...a_dto.go => model_restriction_metadata.go} | 3 +- ...el_restriction_metadata_map_request_dto.go | 14 - ...l_restriction_metadata_map_response_dto.go | 14 - harness/nextgen/model_role.go | 19 - harness/nextgen/model_role_assignment.go | 19 - ...odel_role_assignment_aggregate_response.go | 17 - .../model_role_assignment_create_request.go | 14 - .../nextgen/model_role_assignment_filter.go | 19 - .../model_role_assignment_metadata_dto.go | 20 - .../nextgen/model_role_assignment_response.go | 18 - harness/nextgen/model_role_response.go | 18 - .../nextgen/model_saml_link_group_request.go | 14 - harness/nextgen/model_scope.go | 16 - harness/nextgen/model_secret_dtov2.go | 21 - harness/nextgen/model_secret_file_spec_dto.go | 16 - .../model_secret_manager_config_dto.go | 23 - .../model_secret_manager_metadata_dto.go | 15 - ...del_secret_manager_metadata_request_dto.go | 18 - ...ecret_manager_metadata_request_spec_dto.go | 14 - .../model_secret_manager_metadata_spec_dto.go | 14 - harness/nextgen/model_secret_ng_variable.go | 21 - ...eferred_by_connector_setup_usage_detail.go | 15 - .../nextgen/model_secret_request_wrapper.go | 14 - .../model_secret_resource_filter_dto.go | 18 - .../nextgen/model_secret_response_wrapper.go | 17 - harness/nextgen/model_secret_spec_dto.go | 15 - harness/nextgen/model_secret_text_spec_dto.go | 18 - .../nextgen/model_secret_unique_identifier.go | 14 - .../model_secret_validation_meta_data.go | 14 - .../model_secret_validation_result_dto.go | 15 - harness/nextgen/model_secrets_files_body.go | 15 - .../model_service_account_aggregate_dto.go | 18 - harness/nextgen/model_service_account_dto.go | 21 - .../nextgen/model_service_dashboard_info.go | 24 - harness/nextgen/model_service_deployment.go | 16 - .../nextgen/model_service_deployment_info.go | 15 - .../model_service_deployment_info_dto.go | 14 - .../model_service_deployment_list_info.go | 22 - harness/nextgen/model_service_descriptor.go | 20 - .../nextgen/model_service_descriptor_proto.go | 29 - ...del_service_descriptor_proto_or_builder.go | 26 - harness/nextgen/model_service_details_dto.go | 26 - .../nextgen/model_service_details_info_dto.go | 14 - .../model_service_execution_summary.go | 17 - harness/nextgen/model_service_header_info.go | 19 - harness/nextgen/model_service_options.go | 27 - .../model_service_options_or_builder.go | 23 - .../nextgen/model_service_pipeline_info.go | 18 - ...equest_dto.go => model_service_request.go} | 3 +- harness/nextgen/model_service_response.go | 6 +- harness/nextgen/model_service_response_dto.go | 22 - harness/nextgen/model_services_count.go | 15 - .../nextgen/model_services_dashboard_info.go | 14 - harness/nextgen/model_setup_usage_detail.go | 14 - harness/nextgen/model_signup_dto.go | 20 - harness/nextgen/model_slack_config_dto.go | 15 - harness/nextgen/model_sort.go | 16 - harness/nextgen/model_source_code_info.go | 25 - .../model_source_code_info_or_builder.go | 22 - ...er_dto.go => model_source_code_manager.go} | 3 +- harness/nextgen/model_ssh_auth_dto.go | 15 - harness/nextgen/model_ssh_config_dto.go | 16 - .../nextgen/model_ssh_credential_spec_dto.go | 14 - .../model_ssh_key_path_credential_dto.go | 17 - .../model_ssh_key_reference_credential_dto.go | 17 - harness/nextgen/model_ssh_key_spec_dto.go | 17 - .../model_ssh_password_credential_dto.go | 16 - .../model_stage_element_wrapper_config.go | 15 - harness/nextgen/model_start_trial.go | 2 +- .../nextgen/model_static_limit_restriction.go | 17 + .../model_static_limit_restriction_dto.go | 15 - ...odel_static_limit_restriction_metadata.go} | 3 +- harness/nextgen/model_step_category.go | 16 - harness/nextgen/model_step_data.go | 15 - harness/nextgen/model_string_ng_variable.go | 21 - .../nextgen/model_tgt_generation_spec_dto.go | 14 - .../model_tgt_key_tab_file_path_spec_dto.go | 15 - .../nextgen/model_tgt_password_spec_dto.go | 15 - .../model_time_based_deployment_info.go | 18 - ...model_time_value_pair_env_id_count_pair.go | 15 - .../nextgen/model_time_value_pair_integer.go | 15 - ...e_value_pair_list_dto_env_id_count_pair.go | 14 - .../model_time_value_pair_list_dto_integer.go | 14 - harness/nextgen/model_token_aggregate_dto.go | 17 - harness/nextgen/model_token_dto.go | 30 - .../nextgen/model_total_deployment_info.go | 17 - .../model_trigger_full_sync_response.go | 15 + .../model_two_factor_auth_settings_info.go | 19 - harness/nextgen/model_uninterpreted_option.go | 33 - .../model_uninterpreted_option_or_builder.go | 30 - harness/nextgen/model_unknown_field_set.go | 18 - .../model_upsert_webhook_request_dto.go | 19 - .../model_upsert_webhook_response_dto.go | 16 - harness/nextgen/model_user.go | 77 +- harness/nextgen/model_user_aggregate_dto.go | 15 - harness/nextgen/model_user_filter.go | 16 - harness/nextgen/model_user_group.go | 43 +- .../nextgen/model_user_group_aggregate_dto.go | 17 - harness/nextgen/model_user_group_dto.go | 28 - .../nextgen/model_user_group_filter_dto.go | 20 - harness/nextgen/model_user_metadata_dto.go | 17 - harness/nextgen/model_vault_config_dto.go | 37 - .../model_verify_token_response_dto.go | 14 - harness/nextgen/model_webhook_response.go | 32 - harness/nextgen/model_workload_count_info.go | 14 - .../nextgen/model_workload_date_count_info.go | 15 - .../nextgen/model_workload_deployment_info.go | 27 - .../model_yaml_snippet_meta_data_dto.go | 19 - 742 files changed, 10360 insertions(+), 36622 deletions(-) create mode 100644 harness/cd/graphql/model_delegate_scope.go delete mode 100644 harness/nextgen/api_default.go create mode 100644 harness/nextgen/api_environments.go create mode 100644 harness/nextgen/api_filter.go create mode 100644 harness/nextgen/api_full_sync.go create mode 100644 harness/nextgen/api_git_branches.go create mode 100644 harness/nextgen/api_git_sync.go create mode 100644 harness/nextgen/api_git_sync_entities.go create mode 100644 harness/nextgen/api_git_sync_errors.go create mode 100644 harness/nextgen/api_git_sync_settings.go create mode 100644 harness/nextgen/api_invite.go create mode 100644 harness/nextgen/api_scm.go create mode 100644 harness/nextgen/api_services.go create mode 100644 harness/nextgen/api_source_code_manager.go create mode 100644 harness/nextgen/api_users.go create mode 100644 harness/nextgen/enum_app_dynamics_auth_types.go create mode 100644 harness/nextgen/enum_aws_kms_credential_type.go create mode 100644 harness/nextgen/enum_aws_secret_manager_auth_types.go create mode 100644 harness/nextgen/enum_bitbucket_api_access_types.go create mode 100644 harness/nextgen/enum_bitbucket_http_credential_types.go rename harness/nextgen/{enum_git_connector_type.go => enum_git_connector_types.go} (100%) create mode 100644 harness/nextgen/enum_github_api_access_types.go create mode 100644 harness/nextgen/enum_github_http_credential_types.go create mode 100644 harness/nextgen/enum_gitlab_api_auth_types.go create mode 100644 harness/nextgen/enum_gitlab_http_credential_types.go delete mode 100644 harness/nextgen/model_aggregate_acl_request.go delete mode 100644 harness/nextgen/model_api_key_aggregate_dto.go delete mode 100644 harness/nextgen/model_api_key_dto.go delete mode 100644 harness/nextgen/model_artifact_summary.go rename harness/nextgen/{model_add_users_response.go => model_artifactory_auth_credentials.go} (76%) rename harness/nextgen/{model_instance_count_details_by_env_type_and_service_id.go => model_artifactory_authentication.go} (54%) rename harness/nextgen/{model_aws_kms_sts_credential_config.go => model_artifactory_connector.go} (53%) delete mode 100644 harness/nextgen/model_artifactory_connector_dto.go create mode 100644 harness/nextgen/model_artifactory_username_password_auth.go delete mode 100644 harness/nextgen/model_artifacts_summary.go delete mode 100644 harness/nextgen/model_author_info.go rename harness/nextgen/{model_jira_status_ng.go => model_availability_restriction.go} (64%) rename harness/nextgen/{model_availability_restriction_metadata_dto.go => model_availability_restriction_metadata.go} (80%) create mode 100644 harness/nextgen/model_aws_code_commit_authentication.go delete mode 100644 harness/nextgen/model_aws_code_commit_authentication_dto.go rename harness/nextgen/{model_kubernetes_credential_dto.go => model_aws_code_commit_connector.go} (57%) rename harness/nextgen/{model_aws_kms_iam_credential_config.go => model_aws_code_commit_credentials.go} (77%) create mode 100644 harness/nextgen/model_aws_code_commit_https_credentials.go delete mode 100644 harness/nextgen/model_aws_code_commit_https_credentials_dto.go create mode 100644 harness/nextgen/model_aws_code_commit_https_credentials_spec.go delete mode 100644 harness/nextgen/model_aws_code_commit_https_credentials_spec_dto.go rename harness/nextgen/{model_aws_manual_config_spec_dto.go => model_aws_code_commit_secret_key_access_key.go} (81%) rename harness/nextgen/{model_yaml_snippets_dto.go => model_aws_connector.go} (65%) delete mode 100644 harness/nextgen/model_aws_connector_dto.go create mode 100644 harness/nextgen/model_aws_credential.go delete mode 100644 harness/nextgen/model_aws_credential_dto.go rename harness/nextgen/{model_activity_detail.go => model_aws_credential_spec.go} (81%) delete mode 100644 harness/nextgen/model_aws_credential_spec_dto.go delete mode 100644 harness/nextgen/model_aws_kms_config_dto.go create mode 100644 harness/nextgen/model_aws_kms_connector_credential_serializer.go delete mode 100644 harness/nextgen/model_aws_kms_credential_spec_config.go delete mode 100644 harness/nextgen/model_aws_kms_manual_credential_config.go rename harness/nextgen/{model_aws_code_commit_secret_key_access_key_dto.go => model_aws_manual_config_spec.go} (84%) create mode 100644 harness/nextgen/model_aws_secret_manager_credential_serializer.go delete mode 100644 harness/nextgen/model_azure_key_vault_config_dto.go delete mode 100644 harness/nextgen/model_barrier_info_config.go delete mode 100644 harness/nextgen/model_base_aws_kms_config_dto.go create mode 100644 harness/nextgen/model_bitbucket_api_access.go delete mode 100644 harness/nextgen/model_bitbucket_api_access_dto.go create mode 100644 harness/nextgen/model_bitbucket_api_access_serializer.go delete mode 100644 harness/nextgen/model_bitbucket_api_access_spec_dto.go create mode 100644 harness/nextgen/model_bitbucket_authentication.go delete mode 100644 harness/nextgen/model_bitbucket_authentication_dto.go create mode 100644 harness/nextgen/model_bitbucket_authentication_serializer.go delete mode 100644 harness/nextgen/model_bitbucket_cloud_webhook_events.go delete mode 100644 harness/nextgen/model_bitbucket_cloud_webhook_events_or_builder.go rename harness/nextgen/{model_gitlab_connector_dto.go => model_bitbucket_connector.go} (68%) delete mode 100644 harness/nextgen/model_bitbucket_connector_dto.go create mode 100644 harness/nextgen/model_bitbucket_credentials.go delete mode 100644 harness/nextgen/model_bitbucket_credentials_dto.go create mode 100644 harness/nextgen/model_bitbucket_http_credentials.go delete mode 100644 harness/nextgen/model_bitbucket_http_credentials_dto.go create mode 100644 harness/nextgen/model_bitbucket_http_credentials_serializer.go create mode 100644 harness/nextgen/model_bitbucket_http_credentials_spec.go delete mode 100644 harness/nextgen/model_bitbucket_http_credentials_spec_dto.go delete mode 100644 harness/nextgen/model_bitbucket_server_webhook_events.go delete mode 100644 harness/nextgen/model_bitbucket_server_webhook_events_or_builder.go rename harness/nextgen/{model_github_ssh_credentials_dto.go => model_bitbucket_ssh_credentials.go} (77%) create mode 100644 harness/nextgen/model_bitbucket_username_password.go rename harness/nextgen/{model_bitbucket_username_token_api_access_dto.go => model_bitbucket_username_token_api_access.go} (75%) delete mode 100644 harness/nextgen/model_build_id_and_instance_count.go delete mode 100644 harness/nextgen/model_byte_string.go create mode 100644 harness/nextgen/model_cd_license_summary.go create mode 100644 harness/nextgen/model_cd_module_license.go delete mode 100644 harness/nextgen/model_cd_pipeline_module_info.go delete mode 100644 harness/nextgen/model_cd_stage_module_info.go rename harness/nextgen/{model_ce_license_summary_dto.go => model_ce_license_summary.go} (84%) rename harness/nextgen/{model_ce_module_license_dto.go => model_ce_module_license.go} (90%) rename harness/nextgen/{model_cf_license_summary_dto.go => model_cf_license_summary.go} (87%) rename harness/nextgen/{model_cf_module_license_dto.go => model_cf_module_license.go} (91%) delete mode 100644 harness/nextgen/model_check_expiry_result_dto.go rename harness/nextgen/{model_ci_license_summary_dto.go => model_ci_license_summary.go} (84%) rename harness/nextgen/{model_ci_module_license_dto.go => model_ci_module_license.go} (90%) delete mode 100644 harness/nextgen/model_connected_argo_git_ops_info_dto.go delete mode 100644 harness/nextgen/model_connectivity_check_summary_dto.go create mode 100644 harness/nextgen/model_connector_config.go delete mode 100644 harness/nextgen/model_connector_config_dto.go create mode 100644 harness/nextgen/model_connector_info.go delete mode 100644 harness/nextgen/model_connector_info_dto.go rename harness/nextgen/{model_create_invite_dto.go => model_create_invite.go} (86%) rename harness/nextgen/{model_create_prdto.go => model_create_pr.go} (89%) rename harness/nextgen/{model_cross_account_access_dto.go => model_cross_account_access.go} (83%) create mode 100644 harness/nextgen/model_custom_health_connector_dto.go create mode 100644 harness/nextgen/model_custom_health_key_and_value.go create mode 100644 harness/nextgen/model_custom_restriction.go delete mode 100644 harness/nextgen/model_custom_restriction_dto.go delete mode 100644 harness/nextgen/model_custom_restriction_evaluation_dto.go rename harness/nextgen/{model_restriction_metadata_dto.go => model_custom_restriction_metadata.go} (80%) rename harness/nextgen/{model_cv_license_summary_dto.go => model_cv_license_summary.go} (83%) rename harness/nextgen/{model_cv_module_license_dto.go => model_cv_module_license.go} (90%) delete mode 100644 harness/nextgen/model_dashboard_execution_status_info.go delete mode 100644 harness/nextgen/model_dashboard_workload_deployment.go delete mode 100644 harness/nextgen/model_decryptable_entity.go delete mode 100644 harness/nextgen/model_decryptable_entity_with_encryption_consumers.go delete mode 100644 harness/nextgen/model_delegate_response_data.go delete mode 100644 harness/nextgen/model_deployment.go delete mode 100644 harness/nextgen/model_deployment_change_rates.go delete mode 100644 harness/nextgen/model_deployment_count.go delete mode 100644 harness/nextgen/model_deployment_date_and_count.go delete mode 100644 harness/nextgen/model_deployment_stats_summary.go delete mode 100644 harness/nextgen/model_deployments_info.go delete mode 100644 harness/nextgen/model_descriptor.go delete mode 100644 harness/nextgen/model_descriptor_proto.go delete mode 100644 harness/nextgen/model_descriptor_proto_or_builder.go create mode 100644 harness/nextgen/model_docker_auth_credentials.go delete mode 100644 harness/nextgen/model_docker_auth_credentials_dto.go rename harness/nextgen/{model_ng_access_with_encryption_consumer.go => model_docker_authentication.go} (56%) delete mode 100644 harness/nextgen/model_docker_build_details_dto.go rename harness/nextgen/{model_rest_response_verify_token_response_dto.go => model_docker_connector.go} (52%) delete mode 100644 harness/nextgen/model_docker_connector_dto.go delete mode 100644 harness/nextgen/model_docker_request_dto.go delete mode 100644 harness/nextgen/model_docker_response_dto.go rename harness/nextgen/{model_bitbucket_username_password_dto.go => model_docker_user_name_password.go} (84%) rename harness/nextgen/{model_active_service_instance_summary.go => model_duration_restriction.go} (63%) delete mode 100644 harness/nextgen/model_duration_restriction_dto.go rename harness/nextgen/{model_duration_restriction_metadata_dto.go => model_duration_restriction_metadata.go} (81%) delete mode 100644 harness/nextgen/model_ecr_build_details_dto.go delete mode 100644 harness/nextgen/model_ecr_list_images_dto.go delete mode 100644 harness/nextgen/model_ecr_request_dto.go delete mode 100644 harness/nextgen/model_ecr_response_dto.go rename harness/nextgen/{model_edition_action_dto.go => model_edition_action.go} (82%) delete mode 100644 harness/nextgen/model_email_config_dto.go delete mode 100644 harness/nextgen/model_encrypted_data_detail.go delete mode 100644 harness/nextgen/model_encrypted_data_params.go delete mode 100644 harness/nextgen/model_encrypted_record_data.go delete mode 100644 harness/nextgen/model_encryption_config.go delete mode 100644 harness/nextgen/model_entity_detail.go delete mode 100644 harness/nextgen/model_entity_references_dto.go delete mode 100644 harness/nextgen/model_entity_referred_by_pipeline_setup_usage_detail.go delete mode 100644 harness/nextgen/model_entity_setup_usage_batch_dto.go delete mode 100644 harness/nextgen/model_entity_setup_usage_dto.go delete mode 100644 harness/nextgen/model_enum_descriptor.go delete mode 100644 harness/nextgen/model_enum_descriptor_proto.go delete mode 100644 harness/nextgen/model_enum_descriptor_proto_or_builder.go delete mode 100644 harness/nextgen/model_enum_options.go delete mode 100644 harness/nextgen/model_enum_options_or_builder.go delete mode 100644 harness/nextgen/model_enum_reserved_range.go delete mode 100644 harness/nextgen/model_enum_reserved_range_or_builder.go delete mode 100644 harness/nextgen/model_enum_value_descriptor.go delete mode 100644 harness/nextgen/model_enum_value_descriptor_proto.go delete mode 100644 harness/nextgen/model_enum_value_descriptor_proto_or_builder.go delete mode 100644 harness/nextgen/model_enum_value_options.go delete mode 100644 harness/nextgen/model_enum_value_options_or_builder.go delete mode 100644 harness/nextgen/model_env_build_id_and_instance_count_info.go delete mode 100644 harness/nextgen/model_env_build_id_and_instance_count_info_list.go delete mode 100644 harness/nextgen/model_env_count.go delete mode 100644 harness/nextgen/model_env_id_count_pair.go rename harness/nextgen/{model_environment_request_dto.go => model_environment_request.go} (91%) delete mode 100644 harness/nextgen/model_environment_response_dto.go delete mode 100644 harness/nextgen/model_execution_deployment.go delete mode 100644 harness/nextgen/model_execution_deployment_info.go delete mode 100644 harness/nextgen/model_execution_status_info.go delete mode 100644 harness/nextgen/model_extension_range.go delete mode 100644 harness/nextgen/model_extension_range_options.go delete mode 100644 harness/nextgen/model_extension_range_options_or_builder.go delete mode 100644 harness/nextgen/model_extension_range_or_builder.go create mode 100644 harness/nextgen/model_feature_restriction_detail_list_request.go delete mode 100644 harness/nextgen/model_feature_restriction_usage_dto.go delete mode 100644 harness/nextgen/model_field_descriptor.go delete mode 100644 harness/nextgen/model_field_descriptor_proto.go delete mode 100644 harness/nextgen/model_field_descriptor_proto_or_builder.go delete mode 100644 harness/nextgen/model_field_options.go delete mode 100644 harness/nextgen/model_field_options_or_builder.go delete mode 100644 harness/nextgen/model_file_descriptor.go delete mode 100644 harness/nextgen/model_file_descriptor_proto.go delete mode 100644 harness/nextgen/model_file_options.go delete mode 100644 harness/nextgen/model_file_options_or_builder.go delete mode 100644 harness/nextgen/model_files_identifier_body.go delete mode 100644 harness/nextgen/model_filter_dto.go rename harness/nextgen/{model_filter_properties_dto.go => model_filter_properties.go} (82%) delete mode 100644 harness/nextgen/model_flow_control_config.go rename harness/nextgen/{model_response_dto_organization_aggregate_dto.go => model_full_sync_request.go} (50%) rename harness/nextgen/{model_add_users_dto.go => model_gcp_connector.go} (61%) rename harness/nextgen/{model_deployment_info.go => model_gcp_connector_credential.go} (59%) delete mode 100644 harness/nextgen/model_gcp_connector_dto.go rename harness/nextgen/{model_aws_code_commit_credentials_dto.go => model_gcp_credential_spec.go} (81%) delete mode 100644 harness/nextgen/model_gcp_credential_spec_dto.go delete mode 100644 harness/nextgen/model_gcp_kms_config_dto.go rename harness/nextgen/{model_gcp_manual_details_dto.go => model_gcp_manual_details.go} (83%) delete mode 100644 harness/nextgen/model_gcr_build_details_dto.go delete mode 100644 harness/nextgen/model_gcr_request_dto.go delete mode 100644 harness/nextgen/model_gcr_response_dto.go rename harness/nextgen/{model_base_ssh_spec_dto.go => model_git_authentication.go} (77%) delete mode 100644 harness/nextgen/model_git_authentication_dto.go rename harness/nextgen/{model_git_branch_dto.go => model_git_branch.go} (83%) rename harness/nextgen/{model_git_sync_entity_list_dto.go => model_git_branch_list.go} (62%) delete mode 100644 harness/nextgen/model_git_branch_list_dto.go rename harness/nextgen/{model_git_config_dto.go => model_git_config.go} (79%) rename harness/nextgen/{model_git_enabled_dto.go => model_git_enabled.go} (84%) rename harness/nextgen/{model_git_entity_branch_summary_filter_dto.go => model_git_entity_branch_summary_filter.go} (78%) rename harness/nextgen/{model_git_entity_summary_filter_dto.go => model_git_entity_summary_filter.go} (80%) delete mode 100644 harness/nextgen/model_git_info.go delete mode 100644 harness/nextgen/model_git_ops_info_dto.go delete mode 100644 harness/nextgen/model_git_ops_provider_dto.go delete mode 100644 harness/nextgen/model_git_ops_provider_response_dto.go rename harness/nextgen/{model_gitlab_ssh_credentials_dto.go => model_git_ssh_authentication.go} (70%) create mode 100644 harness/nextgen/model_git_sync_config.go delete mode 100644 harness/nextgen/model_git_sync_config_dto.go rename harness/nextgen/{model_git_sync_entity_dto.go => model_git_sync_entity.go} (93%) rename harness/nextgen/{model_account_resources_dto.go => model_git_sync_entity_list.go} (56%) create mode 100644 harness/nextgen/model_git_sync_error.go create mode 100644 harness/nextgen/model_git_sync_error_aggregate_by_commit.go delete mode 100644 harness/nextgen/model_git_sync_error_aggregate_by_commit_dto.go rename harness/nextgen/{model_git_sync_error_count_dto.go => model_git_sync_error_count.go} (81%) create mode 100644 harness/nextgen/model_git_sync_error_details.go delete mode 100644 harness/nextgen/model_git_sync_error_details_dto.go delete mode 100644 harness/nextgen/model_git_sync_error_dto.go rename harness/nextgen/{model_git_sync_folder_config_dto.go => model_git_sync_folder_config.go} (88%) create mode 100644 harness/nextgen/model_git_sync_repo_files.go delete mode 100644 harness/nextgen/model_git_sync_repo_files_dto.go rename harness/nextgen/{model_http_helm_authentication_dto.go => model_git_sync_repo_files_list.go} (59%) delete mode 100644 harness/nextgen/model_git_sync_repo_files_list_dto.go rename harness/nextgen/{model_git_sync_settings_dto.go => model_git_sync_settings.go} (88%) create mode 100644 harness/nextgen/model_github_api_access.go delete mode 100644 harness/nextgen/model_github_api_access_dto.go create mode 100644 harness/nextgen/model_github_api_access_serializer.go create mode 100644 harness/nextgen/model_github_api_access_spec.go delete mode 100644 harness/nextgen/model_github_api_access_spec_dto.go rename harness/nextgen/{model_github_app_spec_dto.go => model_github_app_spec.go} (79%) create mode 100644 harness/nextgen/model_github_authentication.go delete mode 100644 harness/nextgen/model_github_authentication_dto.go create mode 100644 harness/nextgen/model_github_authentication_serializer.go create mode 100644 harness/nextgen/model_github_connector.go delete mode 100644 harness/nextgen/model_github_connector_dto.go rename harness/nextgen/{model_artifactory_auth_credentials_dto.go => model_github_credentials.go} (79%) delete mode 100644 harness/nextgen/model_github_credentials_dto.go rename harness/nextgen/{model_artifactory_authentication_dto.go => model_github_http_credentials.go} (54%) delete mode 100644 harness/nextgen/model_github_http_credentials_dto.go create mode 100644 harness/nextgen/model_github_http_credentials_serializer.go create mode 100644 harness/nextgen/model_github_http_credentials_spec.go delete mode 100644 harness/nextgen/model_github_http_credentials_spec_dto.go rename harness/nextgen/{model_bitbucket_ssh_credentials_dto.go => model_github_ssh_credentials.go} (78%) rename harness/nextgen/{model_gitlab_token_spec_dto.go => model_github_token_spec.go} (74%) create mode 100644 harness/nextgen/model_github_username_password.go rename harness/nextgen/{model_github_username_token_dto.go => model_github_username_token.go} (78%) delete mode 100644 harness/nextgen/model_github_webhook_events.go delete mode 100644 harness/nextgen/model_github_webhook_events_or_builder.go rename harness/nextgen/{model_gcp_connector_credential_dto.go => model_gitlab_api_access.go} (58%) delete mode 100644 harness/nextgen/model_gitlab_api_access_dto.go create mode 100644 harness/nextgen/model_gitlab_api_access_serializer.go create mode 100644 harness/nextgen/model_gitlab_api_access_spec.go delete mode 100644 harness/nextgen/model_gitlab_api_access_spec_dto.go create mode 100644 harness/nextgen/model_gitlab_authentication.go delete mode 100644 harness/nextgen/model_gitlab_authentication_dto.go create mode 100644 harness/nextgen/model_gitlab_authentication_serializer.go create mode 100644 harness/nextgen/model_gitlab_connector.go create mode 100644 harness/nextgen/model_gitlab_credentials.go delete mode 100644 harness/nextgen/model_gitlab_credentials_dto.go rename harness/nextgen/{model_aws_code_commit_connector_dto.go => model_gitlab_http_credentials.go} (50%) delete mode 100644 harness/nextgen/model_gitlab_http_credentials_dto.go create mode 100644 harness/nextgen/model_gitlab_http_credentials_serializer.go create mode 100644 harness/nextgen/model_gitlab_http_credentials_spec.go delete mode 100644 harness/nextgen/model_gitlab_http_credentials_spec_dto.go rename harness/nextgen/{model_gitlab_kerberos_dto.go => model_gitlab_kerberos.go} (77%) rename harness/nextgen/{model_git_ssh_authentication_dto.go => model_gitlab_ssh_credentials.go} (78%) create mode 100644 harness/nextgen/model_gitlab_token_spec.go create mode 100644 harness/nextgen/model_gitlab_username_password.go delete mode 100644 harness/nextgen/model_gitlab_username_password_dto.go rename harness/nextgen/{model_gitlab_username_token_dto.go => model_gitlab_username_token.go} (78%) delete mode 100644 harness/nextgen/model_gitlab_webhook_events.go delete mode 100644 harness/nextgen/model_gitlab_webhook_events_or_builder.go delete mode 100644 harness/nextgen/model_harness_service_info_ng.go delete mode 100644 harness/nextgen/model_health_deployment_dashboard.go delete mode 100644 harness/nextgen/model_health_deployment_info.go rename harness/nextgen/{model_availability_restriction_dto.go => model_http_helm_auth_credentials.go} (81%) delete mode 100644 harness/nextgen/model_http_helm_auth_credentials_dto.go create mode 100644 harness/nextgen/model_http_helm_authentication.go rename harness/nextgen/{model_nexus_connector_dto.go => model_http_helm_connector.go} (66%) delete mode 100644 harness/nextgen/model_http_helm_connector_dto.go rename harness/nextgen/{model_artifactory_username_password_auth_dto.go => model_http_helm_username_password.go} (84%) delete mode 100644 harness/nextgen/model_http_helm_username_password_dto.go delete mode 100644 harness/nextgen/model_infra_execution_summary.go delete mode 100644 harness/nextgen/model_infrastructure_details.go delete mode 100644 harness/nextgen/model_input_set_validator.go delete mode 100644 harness/nextgen/model_instance_count_details_by_env_type_base.go delete mode 100644 harness/nextgen/model_instance_details_by_build_id.go delete mode 100644 harness/nextgen/model_instance_details_dto.go delete mode 100644 harness/nextgen/model_instances_by_build_id_list.go rename harness/nextgen/{model_invite_dto.go => model_invite.go} (92%) rename harness/nextgen/{model_jira_connector_dto.go => model_jira_connector.go} (89%) delete mode 100644 harness/nextgen/model_jira_field_allowed_value_ng.go delete mode 100644 harness/nextgen/model_jira_field_ng.go delete mode 100644 harness/nextgen/model_jira_field_schema_ng.go delete mode 100644 harness/nextgen/model_jira_issue_create_metadata_ng.go delete mode 100644 harness/nextgen/model_jira_issue_type_ng.go delete mode 100644 harness/nextgen/model_jira_issue_update_metadata_ng.go delete mode 100644 harness/nextgen/model_jira_project_basic_ng.go delete mode 100644 harness/nextgen/model_jira_project_ng.go delete mode 100644 harness/nextgen/model_jira_status_category_ng.go delete mode 100644 harness/nextgen/model_json_node.go delete mode 100644 harness/nextgen/model_k8s_infrastructure_details.go delete mode 100644 harness/nextgen/model_kerberos_config_dto.go create mode 100644 harness/nextgen/model_kubernetes_auth.go rename harness/nextgen/{model_active_projects_count_dto.go => model_kubernetes_auth_credential.go} (80%) delete mode 100644 harness/nextgen/model_kubernetes_auth_credential_dto.go delete mode 100644 harness/nextgen/model_kubernetes_auth_dto.go rename harness/nextgen/{model_kubernetes_client_key_cert_dto.go => model_kubernetes_client_key_cert.go} (87%) create mode 100644 harness/nextgen/model_kubernetes_cluster_config.go delete mode 100644 harness/nextgen/model_kubernetes_cluster_config_dto.go create mode 100644 harness/nextgen/model_kubernetes_cluster_details.go delete mode 100644 harness/nextgen/model_kubernetes_cluster_details_dto.go create mode 100644 harness/nextgen/model_kubernetes_credential.go rename harness/nextgen/{model_additional_metadata.go => model_kubernetes_credential_spec.go} (79%) delete mode 100644 harness/nextgen/model_kubernetes_credential_spec_dto.go rename harness/nextgen/{model_kubernetes_open_id_connect_dto.go => model_kubernetes_open_id_connect.go} (89%) rename harness/nextgen/{model_kubernetes_service_account_dto.go => model_kubernetes_service_account.go} (82%) rename harness/nextgen/{model_github_username_password_dto.go => model_kubernetes_user_name_password.go} (83%) delete mode 100644 harness/nextgen/model_kubernetes_user_name_password_dto.go delete mode 100644 harness/nextgen/model_last_workload_info.go delete mode 100644 harness/nextgen/model_local_config_dto.go delete mode 100644 harness/nextgen/model_location.go delete mode 100644 harness/nextgen/model_location_or_builder.go delete mode 100644 harness/nextgen/model_managed_argo_git_ops_info_dto.go delete mode 100644 harness/nextgen/model_message.go delete mode 100644 harness/nextgen/model_message_lite.go delete mode 100644 harness/nextgen/model_message_options.go delete mode 100644 harness/nextgen/model_message_options_or_builder.go delete mode 100644 harness/nextgen/model_method_descriptor.go delete mode 100644 harness/nextgen/model_method_descriptor_proto.go delete mode 100644 harness/nextgen/model_method_descriptor_proto_or_builder.go delete mode 100644 harness/nextgen/model_method_options.go delete mode 100644 harness/nextgen/model_method_options_or_builder.go delete mode 100644 harness/nextgen/model_microsoft_teams_config_dto.go delete mode 100644 harness/nextgen/model_name_part.go delete mode 100644 harness/nextgen/model_name_part_or_builder.go delete mode 100644 harness/nextgen/model_native_events.go delete mode 100644 harness/nextgen/model_native_events_or_builder.go create mode 100644 harness/nextgen/model_nexus_auth_credentials.go delete mode 100644 harness/nextgen/model_nexus_auth_credentials_dto.go rename harness/nextgen/{model_docker_authentication_dto.go => model_nexus_authentication.go} (65%) delete mode 100644 harness/nextgen/model_nexus_authentication_dto.go rename harness/nextgen/{model_rest_response.go => model_nexus_connector.go} (53%) rename harness/nextgen/{model_docker_user_name_password_dto.go => model_nexus_username_password_auth.go} (83%) delete mode 100644 harness/nextgen/model_nexus_username_password_auth_dto.go delete mode 100644 harness/nextgen/model_ng_access.go delete mode 100644 harness/nextgen/model_ng_activity_dto.go delete mode 100644 harness/nextgen/model_ng_activity_summary_dto.go delete mode 100644 harness/nextgen/model_ng_properties.go delete mode 100644 harness/nextgen/model_ng_tag.go delete mode 100644 harness/nextgen/model_ng_variable.go delete mode 100644 harness/nextgen/model_notification_channel_wrapper.go delete mode 100644 harness/nextgen/model_notification_rules.go delete mode 100644 harness/nextgen/model_notification_setting_config.go delete mode 100644 harness/nextgen/model_notification_setting_config_dto.go delete mode 100644 harness/nextgen/model_number_ng_variable.go delete mode 100644 harness/nextgen/model_o_auth_signup_dto.go delete mode 100644 harness/nextgen/model_oneof_descriptor.go delete mode 100644 harness/nextgen/model_oneof_descriptor_proto.go delete mode 100644 harness/nextgen/model_oneof_descriptor_proto_or_builder.go delete mode 100644 harness/nextgen/model_oneof_options.go delete mode 100644 harness/nextgen/model_oneof_options_or_builder.go delete mode 100644 harness/nextgen/model_org_project_identifier.go delete mode 100644 harness/nextgen/model_organization_aggregate_dto.go delete mode 100644 harness/nextgen/model_page_entity_setup_usage_dto.go delete mode 100644 harness/nextgen/model_page_ng_activity_dto.go delete mode 100644 harness/nextgen/model_page_ng_activity_summary_dto.go delete mode 100644 harness/nextgen/model_page_response_api_key_aggregate_dto.go delete mode 100644 harness/nextgen/model_page_response_environment_response_dto.go create mode 100644 harness/nextgen/model_page_response_filter.go rename harness/nextgen/{model_page_response_filter_dto.go => model_page_response_git_branch.go} (88%) delete mode 100644 harness/nextgen/model_page_response_git_ops_provider_response_dto.go rename harness/nextgen/{model_page_response_token_aggregate_dto.go => model_page_response_git_sync_entity_list.go} (87%) delete mode 100644 harness/nextgen/model_page_response_git_sync_entity_list_dto.go rename harness/nextgen/{model_page_response_git_branch_dto.go => model_page_response_git_sync_error.go} (88%) create mode 100644 harness/nextgen/model_page_response_git_sync_error_aggregate_by_commit.go delete mode 100644 harness/nextgen/model_page_response_git_sync_error_aggregate_by_commit_dto.go delete mode 100644 harness/nextgen/model_page_response_git_sync_error_dto.go create mode 100644 harness/nextgen/model_page_response_invite.go delete mode 100644 harness/nextgen/model_page_response_invite_dto.go delete mode 100644 harness/nextgen/model_page_response_organization_aggregate_dto.go delete mode 100644 harness/nextgen/model_page_response_project.go delete mode 100644 harness/nextgen/model_page_response_project_aggregate_dto.go delete mode 100644 harness/nextgen/model_page_response_role_assignment_response.go delete mode 100644 harness/nextgen/model_page_response_secret_response_wrapper.go delete mode 100644 harness/nextgen/model_page_response_service_account_aggregate_dto.go delete mode 100644 harness/nextgen/model_page_response_service_response_dto.go delete mode 100644 harness/nextgen/model_page_response_user_aggregate_dto.go delete mode 100644 harness/nextgen/model_page_response_user_group_aggregate_dto.go delete mode 100644 harness/nextgen/model_page_response_user_group_dto.go delete mode 100644 harness/nextgen/model_page_response_user_metadata_dto.go delete mode 100644 harness/nextgen/model_pageable.go delete mode 100644 harness/nextgen/model_pager_duty_config_dto.go delete mode 100644 harness/nextgen/model_parameter_field_double.go delete mode 100644 harness/nextgen/model_parameter_field_notification_channel_wrapper.go delete mode 100644 harness/nextgen/model_parameter_field_object.go delete mode 100644 harness/nextgen/model_parameter_field_secret_ref_data.go delete mode 100644 harness/nextgen/model_parameter_field_string.go delete mode 100644 harness/nextgen/model_parameter_field_timeout.go delete mode 100644 harness/nextgen/model_parser.go delete mode 100644 harness/nextgen/model_parser_bitbucket_cloud_webhook_events.go delete mode 100644 harness/nextgen/model_parser_bitbucket_server_webhook_events.go delete mode 100644 harness/nextgen/model_parser_descriptor_proto.go delete mode 100644 harness/nextgen/model_parser_enum_descriptor_proto.go delete mode 100644 harness/nextgen/model_parser_enum_options.go delete mode 100644 harness/nextgen/model_parser_enum_reserved_range.go delete mode 100644 harness/nextgen/model_parser_enum_value_descriptor_proto.go delete mode 100644 harness/nextgen/model_parser_enum_value_options.go delete mode 100644 harness/nextgen/model_parser_extension_range.go delete mode 100644 harness/nextgen/model_parser_extension_range_options.go delete mode 100644 harness/nextgen/model_parser_field_descriptor_proto.go delete mode 100644 harness/nextgen/model_parser_field_options.go delete mode 100644 harness/nextgen/model_parser_file_descriptor_proto.go delete mode 100644 harness/nextgen/model_parser_file_options.go delete mode 100644 harness/nextgen/model_parser_github_webhook_events.go delete mode 100644 harness/nextgen/model_parser_gitlab_webhook_events.go delete mode 100644 harness/nextgen/model_parser_location.go delete mode 100644 harness/nextgen/model_parser_message.go delete mode 100644 harness/nextgen/model_parser_message_lite.go delete mode 100644 harness/nextgen/model_parser_message_options.go delete mode 100644 harness/nextgen/model_parser_method_descriptor_proto.go delete mode 100644 harness/nextgen/model_parser_method_options.go delete mode 100644 harness/nextgen/model_parser_name_part.go delete mode 100644 harness/nextgen/model_parser_native_events.go delete mode 100644 harness/nextgen/model_parser_oneof_descriptor_proto.go delete mode 100644 harness/nextgen/model_parser_oneof_options.go delete mode 100644 harness/nextgen/model_parser_reserved_range.go delete mode 100644 harness/nextgen/model_parser_service_descriptor_proto.go delete mode 100644 harness/nextgen/model_parser_service_options.go delete mode 100644 harness/nextgen/model_parser_source_code_info.go delete mode 100644 harness/nextgen/model_parser_uninterpreted_option.go delete mode 100644 harness/nextgen/model_parser_webhook_response.go delete mode 100644 harness/nextgen/model_partial_schema_dto.go delete mode 100644 harness/nextgen/model_password_change_dto.go delete mode 100644 harness/nextgen/model_pipeline_config.go delete mode 100644 harness/nextgen/model_pipeline_event.go delete mode 100644 harness/nextgen/model_pipeline_execution_dashboard_info.go delete mode 100644 harness/nextgen/model_pipeline_info_config.go delete mode 100644 harness/nextgen/model_pipelines_execution_dashboard_info.go delete mode 100644 harness/nextgen/model_pms_email_channel.go delete mode 100644 harness/nextgen/model_pms_ms_team_channel.go delete mode 100644 harness/nextgen/model_pms_notification_channel.go delete mode 100644 harness/nextgen/model_pms_pager_duty_channel.go delete mode 100644 harness/nextgen/model_pms_slack_channel.go delete mode 100644 harness/nextgen/model_polling_response_dto.go delete mode 100644 harness/nextgen/model_principal.go delete mode 100644 harness/nextgen/model_project_aggregate_dto.go delete mode 100644 harness/nextgen/model_project_dash_board_info.go delete mode 100644 harness/nextgen/model_projects_dashboard_info.go create mode 100644 harness/nextgen/model_rate_limit_protection.go create mode 100644 harness/nextgen/model_rate_limit_restriction.go delete mode 100644 harness/nextgen/model_rate_limit_restriction_dto.go rename harness/nextgen/{model_rate_limit_restriction_metadata_dto.go => model_rate_limit_restriction_metadata.go} (84%) delete mode 100644 harness/nextgen/model_reserved_range.go delete mode 100644 harness/nextgen/model_reserved_range_or_builder.go delete mode 100644 harness/nextgen/model_resource_group.go delete mode 100644 harness/nextgen/model_response_dto_account_resources_dto.go delete mode 100644 harness/nextgen/model_response_dto_active_projects_count_dto.go delete mode 100644 harness/nextgen/model_response_dto_active_service_instance_summary.go delete mode 100644 harness/nextgen/model_response_dto_add_users_response.go delete mode 100644 harness/nextgen/model_response_dto_check_expiry_result_dto.go delete mode 100644 harness/nextgen/model_response_dto_connectivity_check_summary_dto.go rename harness/nextgen/{model_response_dto_json_node.go => model_response_dto_create_pr.go} (85%) delete mode 100644 harness/nextgen/model_response_dto_create_prdto.go delete mode 100644 harness/nextgen/model_response_dto_dashboard_execution_status_info.go delete mode 100644 harness/nextgen/model_response_dto_dashboard_workload_deployment.go delete mode 100644 harness/nextgen/model_response_dto_decryptable_entity.go delete mode 100644 harness/nextgen/model_response_dto_deployment_stats_summary.go delete mode 100644 harness/nextgen/model_response_dto_docker_build_details_dto.go delete mode 100644 harness/nextgen/model_response_dto_docker_response_dto.go delete mode 100644 harness/nextgen/model_response_dto_ecr_list_images_dto.go delete mode 100644 harness/nextgen/model_response_dto_ecr_response_dto.go delete mode 100644 harness/nextgen/model_response_dto_entity_references_dto.go delete mode 100644 harness/nextgen/model_response_dto_entity_setup_usage_dto.go delete mode 100644 harness/nextgen/model_response_dto_env_build_id_and_instance_count_info_list.go delete mode 100644 harness/nextgen/model_response_dto_environment_response_dto.go delete mode 100644 harness/nextgen/model_response_dto_feature_restriction_metadata.go delete mode 100644 harness/nextgen/model_response_dto_feature_restriction_usage_dto.go rename harness/nextgen/{model_response_dto_token_dto.go => model_response_dto_filter.go} (85%) delete mode 100644 harness/nextgen/model_response_dto_filter_dto.go delete mode 100644 harness/nextgen/model_response_dto_gcr_response_dto.go rename harness/nextgen/{model_response_dto_services_count.go => model_response_dto_git_branch_list.go} (85%) delete mode 100644 harness/nextgen/model_response_dto_git_branch_list_dto.go delete mode 100644 harness/nextgen/model_response_dto_git_ops_provider_response_dto.go rename harness/nextgen/{model_response_dto_page_ng_activity_dto.go => model_response_dto_git_sync_error_count.go} (84%) delete mode 100644 harness/nextgen/model_response_dto_git_sync_error_count_dto.go rename harness/nextgen/{model_response_dto_source_code_manager_dto.go => model_response_dto_git_sync_repo_files_list.go} (83%) delete mode 100644 harness/nextgen/model_response_dto_git_sync_repo_files_list_dto.go rename harness/nextgen/{model_response_dto_deployments_info.go => model_response_dto_git_sync_settings.go} (84%) delete mode 100644 harness/nextgen/model_response_dto_health_deployment_dashboard.go delete mode 100644 harness/nextgen/model_response_dto_instances_by_build_id_list.go rename harness/nextgen/{model_response_dto_env_count.go => model_response_dto_invite.go} (85%) delete mode 100644 harness/nextgen/model_response_dto_invite_dto.go delete mode 100644 harness/nextgen/model_response_dto_jira_issue_create_metadata_ng.go delete mode 100644 harness/nextgen/model_response_dto_list_api_key_dto.go delete mode 100644 harness/nextgen/model_response_dto_list_encrypted_data_detail.go delete mode 100644 harness/nextgen/model_response_dto_list_entity_setup_usage_dto.go delete mode 100644 harness/nextgen/model_response_dto_list_execution_status.go rename harness/nextgen/{model_response_dto_gcr_build_details_dto.go => model_response_dto_list_git_sync_entity_list.go} (83%) delete mode 100644 harness/nextgen/model_response_dto_list_git_sync_entity_list_dto.go delete mode 100644 harness/nextgen/model_response_dto_list_jira_project_basic_ng.go delete mode 100644 harness/nextgen/model_response_dto_list_jira_status_ng.go delete mode 100644 harness/nextgen/model_response_dto_list_project.go delete mode 100644 harness/nextgen/model_response_dto_list_role_assignment_response.go delete mode 100644 harness/nextgen/model_response_dto_list_service_account_dto.go delete mode 100644 harness/nextgen/model_response_dto_list_service_definition_type.go rename harness/nextgen/{model_response_dto_git_sync_settings_dto.go => model_response_dto_list_source_code_manager.go} (83%) delete mode 100644 harness/nextgen/model_response_dto_list_source_code_manager_dto.go delete mode 100644 harness/nextgen/model_response_dto_list_user_group_aggregate_dto.go delete mode 100644 harness/nextgen/model_response_dto_list_user_group_dto.go rename harness/nextgen/{model_response_dto_jira_issue_update_metadata_ng.go => model_response_dto_map_edition_set_edition_action.go} (83%) delete mode 100644 harness/nextgen/model_response_dto_map_edition_set_edition_action_dto.go rename harness/nextgen/{model_response_dto_yaml_snippets_dto.go => model_response_dto_map_module_type_long.go} (84%) delete mode 100644 harness/nextgen/model_response_dto_map_service_definition_type_list_execution_strategy_type.go delete mode 100644 harness/nextgen/model_response_dto_map_string_string.go delete mode 100644 harness/nextgen/model_response_dto_optional_harness_service_info_ng.go rename harness/nextgen/{model_response_dto_api_key_dto.go => model_response_dto_optional_invite.go} (85%) delete mode 100644 harness/nextgen/model_response_dto_optional_invite_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_entity_setup_usage_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_ng_activity_summary_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_api_key_aggregate_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_environment_response_dto.go rename harness/nextgen/{model_response_dto_api_key_aggregate_dto.go => model_response_dto_page_response_filter.go} (84%) delete mode 100644 harness/nextgen/model_response_dto_page_response_filter_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_git_ops_provider_response_dto.go rename harness/nextgen/{model_response_dto_page_response_token_aggregate_dto.go => model_response_dto_page_response_git_sync_entity_list.go} (83%) delete mode 100644 harness/nextgen/model_response_dto_page_response_git_sync_entity_list_dto.go rename harness/nextgen/{model_response_dto_secret_manager_metadata_dto.go => model_response_dto_page_response_git_sync_error.go} (83%) rename harness/nextgen/{model_response_dto_instance_count_details_by_env_type_and_service_id.go => model_response_dto_page_response_git_sync_error_aggregate_by_commit.go} (83%) delete mode 100644 harness/nextgen/model_response_dto_page_response_git_sync_error_aggregate_by_commit_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_git_sync_error_dto.go rename harness/nextgen/{model_response_dto_ecr_build_details_dto.go => model_response_dto_page_response_invite.go} (84%) delete mode 100644 harness/nextgen/model_response_dto_page_response_invite_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_organization_aggregate_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_project.go delete mode 100644 harness/nextgen/model_response_dto_page_response_project_aggregate_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_role_assignment_response.go delete mode 100644 harness/nextgen/model_response_dto_page_response_secret_response_wrapper.go delete mode 100644 harness/nextgen/model_response_dto_page_response_service_account_aggregate_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_service_response_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_user_aggregate_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_user_group_aggregate_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_user_group_dto.go delete mode 100644 harness/nextgen/model_response_dto_page_response_user_metadata_dto.go delete mode 100644 harness/nextgen/model_response_dto_partial_schema_dto.go delete mode 100644 harness/nextgen/model_response_dto_password_change_response.go delete mode 100644 harness/nextgen/model_response_dto_pipeline_config.go delete mode 100644 harness/nextgen/model_response_dto_pipelines_execution_dashboard_info.go delete mode 100644 harness/nextgen/model_response_dto_polling_response_dto.go delete mode 100644 harness/nextgen/model_response_dto_project_aggregate_dto.go delete mode 100644 harness/nextgen/model_response_dto_projects_dashboard_info.go delete mode 100644 harness/nextgen/model_response_dto_restriction_metadata_map_response_dto.go delete mode 100644 harness/nextgen/model_response_dto_role_assignment_aggregate_response.go delete mode 100644 harness/nextgen/model_response_dto_role_assignment_response.go delete mode 100644 harness/nextgen/model_response_dto_secret_manager_config_dto.go delete mode 100644 harness/nextgen/model_response_dto_secret_response_wrapper.go delete mode 100644 harness/nextgen/model_response_dto_secret_validation_result_dto.go delete mode 100644 harness/nextgen/model_response_dto_service_account_aggregate_dto.go delete mode 100644 harness/nextgen/model_response_dto_service_deployment_info_dto.go delete mode 100644 harness/nextgen/model_response_dto_service_deployment_list_info.go delete mode 100644 harness/nextgen/model_response_dto_service_details_info_dto.go delete mode 100644 harness/nextgen/model_response_dto_service_header_info.go delete mode 100644 harness/nextgen/model_response_dto_service_response_dto.go delete mode 100644 harness/nextgen/model_response_dto_services_dashboard_info.go rename harness/nextgen/{model_response_dto_service_account_dto.go => model_response_dto_source_code_manager.go} (84%) delete mode 100644 harness/nextgen/model_response_dto_step_category.go delete mode 100644 harness/nextgen/model_response_dto_time_value_pair_list_dto_env_id_count_pair.go delete mode 100644 harness/nextgen/model_response_dto_time_value_pair_list_dto_integer.go rename harness/nextgen/{model_response_dto_execution_deployment_info.go => model_response_dto_trigger_full_sync_response.go} (83%) delete mode 100644 harness/nextgen/model_response_dto_two_factor_auth_settings_info.go delete mode 100644 harness/nextgen/model_response_dto_upsert_webhook_response_dto.go delete mode 100644 harness/nextgen/model_response_dto_user_aggregate_dto.go delete mode 100644 harness/nextgen/model_response_dto_user_group_aggregate_dto.go delete mode 100644 harness/nextgen/model_response_dto_user_group_dto.go delete mode 100644 harness/nextgen/model_response_dtocd_pipeline_module_info.go delete mode 100644 harness/nextgen/model_response_dtocd_stage_module_info.go delete mode 100644 harness/nextgen/model_response_dtong_activity_dto.go delete mode 100644 harness/nextgen/model_rest_response_user_group.go delete mode 100644 harness/nextgen/model_rest_response_user_info.go create mode 100644 harness/nextgen/model_restriction.go delete mode 100644 harness/nextgen/model_restriction_dto.go rename harness/nextgen/{model_custom_restriction_metadata_dto.go => model_restriction_metadata.go} (82%) delete mode 100644 harness/nextgen/model_restriction_metadata_map_request_dto.go delete mode 100644 harness/nextgen/model_restriction_metadata_map_response_dto.go delete mode 100644 harness/nextgen/model_role.go delete mode 100644 harness/nextgen/model_role_assignment.go delete mode 100644 harness/nextgen/model_role_assignment_aggregate_response.go delete mode 100644 harness/nextgen/model_role_assignment_create_request.go delete mode 100644 harness/nextgen/model_role_assignment_filter.go delete mode 100644 harness/nextgen/model_role_assignment_metadata_dto.go delete mode 100644 harness/nextgen/model_role_assignment_response.go delete mode 100644 harness/nextgen/model_role_response.go delete mode 100644 harness/nextgen/model_saml_link_group_request.go delete mode 100644 harness/nextgen/model_scope.go delete mode 100644 harness/nextgen/model_secret_dtov2.go delete mode 100644 harness/nextgen/model_secret_file_spec_dto.go delete mode 100644 harness/nextgen/model_secret_manager_config_dto.go delete mode 100644 harness/nextgen/model_secret_manager_metadata_dto.go delete mode 100644 harness/nextgen/model_secret_manager_metadata_request_dto.go delete mode 100644 harness/nextgen/model_secret_manager_metadata_request_spec_dto.go delete mode 100644 harness/nextgen/model_secret_manager_metadata_spec_dto.go delete mode 100644 harness/nextgen/model_secret_ng_variable.go delete mode 100644 harness/nextgen/model_secret_referred_by_connector_setup_usage_detail.go delete mode 100644 harness/nextgen/model_secret_request_wrapper.go delete mode 100644 harness/nextgen/model_secret_resource_filter_dto.go delete mode 100644 harness/nextgen/model_secret_response_wrapper.go delete mode 100644 harness/nextgen/model_secret_spec_dto.go delete mode 100644 harness/nextgen/model_secret_text_spec_dto.go delete mode 100644 harness/nextgen/model_secret_unique_identifier.go delete mode 100644 harness/nextgen/model_secret_validation_meta_data.go delete mode 100644 harness/nextgen/model_secret_validation_result_dto.go delete mode 100644 harness/nextgen/model_secrets_files_body.go delete mode 100644 harness/nextgen/model_service_account_aggregate_dto.go delete mode 100644 harness/nextgen/model_service_account_dto.go delete mode 100644 harness/nextgen/model_service_dashboard_info.go delete mode 100644 harness/nextgen/model_service_deployment.go delete mode 100644 harness/nextgen/model_service_deployment_info.go delete mode 100644 harness/nextgen/model_service_deployment_info_dto.go delete mode 100644 harness/nextgen/model_service_deployment_list_info.go delete mode 100644 harness/nextgen/model_service_descriptor.go delete mode 100644 harness/nextgen/model_service_descriptor_proto.go delete mode 100644 harness/nextgen/model_service_descriptor_proto_or_builder.go delete mode 100644 harness/nextgen/model_service_details_dto.go delete mode 100644 harness/nextgen/model_service_details_info_dto.go delete mode 100644 harness/nextgen/model_service_execution_summary.go delete mode 100644 harness/nextgen/model_service_header_info.go delete mode 100644 harness/nextgen/model_service_options.go delete mode 100644 harness/nextgen/model_service_options_or_builder.go delete mode 100644 harness/nextgen/model_service_pipeline_info.go rename harness/nextgen/{model_service_request_dto.go => model_service_request.go} (90%) delete mode 100644 harness/nextgen/model_service_response_dto.go delete mode 100644 harness/nextgen/model_services_count.go delete mode 100644 harness/nextgen/model_services_dashboard_info.go delete mode 100644 harness/nextgen/model_setup_usage_detail.go delete mode 100644 harness/nextgen/model_signup_dto.go delete mode 100644 harness/nextgen/model_slack_config_dto.go delete mode 100644 harness/nextgen/model_sort.go delete mode 100644 harness/nextgen/model_source_code_info.go delete mode 100644 harness/nextgen/model_source_code_info_or_builder.go rename harness/nextgen/{model_source_code_manager_dto.go => model_source_code_manager.go} (92%) delete mode 100644 harness/nextgen/model_ssh_auth_dto.go delete mode 100644 harness/nextgen/model_ssh_config_dto.go delete mode 100644 harness/nextgen/model_ssh_credential_spec_dto.go delete mode 100644 harness/nextgen/model_ssh_key_path_credential_dto.go delete mode 100644 harness/nextgen/model_ssh_key_reference_credential_dto.go delete mode 100644 harness/nextgen/model_ssh_key_spec_dto.go delete mode 100644 harness/nextgen/model_ssh_password_credential_dto.go delete mode 100644 harness/nextgen/model_stage_element_wrapper_config.go create mode 100644 harness/nextgen/model_static_limit_restriction.go delete mode 100644 harness/nextgen/model_static_limit_restriction_dto.go rename harness/nextgen/{model_static_limit_restriction_metadata_dto.go => model_static_limit_restriction_metadata.go} (82%) delete mode 100644 harness/nextgen/model_step_category.go delete mode 100644 harness/nextgen/model_step_data.go delete mode 100644 harness/nextgen/model_string_ng_variable.go delete mode 100644 harness/nextgen/model_tgt_generation_spec_dto.go delete mode 100644 harness/nextgen/model_tgt_key_tab_file_path_spec_dto.go delete mode 100644 harness/nextgen/model_tgt_password_spec_dto.go delete mode 100644 harness/nextgen/model_time_based_deployment_info.go delete mode 100644 harness/nextgen/model_time_value_pair_env_id_count_pair.go delete mode 100644 harness/nextgen/model_time_value_pair_integer.go delete mode 100644 harness/nextgen/model_time_value_pair_list_dto_env_id_count_pair.go delete mode 100644 harness/nextgen/model_time_value_pair_list_dto_integer.go delete mode 100644 harness/nextgen/model_token_aggregate_dto.go delete mode 100644 harness/nextgen/model_token_dto.go delete mode 100644 harness/nextgen/model_total_deployment_info.go create mode 100644 harness/nextgen/model_trigger_full_sync_response.go delete mode 100644 harness/nextgen/model_two_factor_auth_settings_info.go delete mode 100644 harness/nextgen/model_uninterpreted_option.go delete mode 100644 harness/nextgen/model_uninterpreted_option_or_builder.go delete mode 100644 harness/nextgen/model_unknown_field_set.go delete mode 100644 harness/nextgen/model_upsert_webhook_request_dto.go delete mode 100644 harness/nextgen/model_upsert_webhook_response_dto.go delete mode 100644 harness/nextgen/model_user_aggregate_dto.go delete mode 100644 harness/nextgen/model_user_filter.go delete mode 100644 harness/nextgen/model_user_group_aggregate_dto.go delete mode 100644 harness/nextgen/model_user_group_dto.go delete mode 100644 harness/nextgen/model_user_group_filter_dto.go delete mode 100644 harness/nextgen/model_user_metadata_dto.go delete mode 100644 harness/nextgen/model_vault_config_dto.go delete mode 100644 harness/nextgen/model_verify_token_response_dto.go delete mode 100644 harness/nextgen/model_webhook_response.go delete mode 100644 harness/nextgen/model_workload_count_info.go delete mode 100644 harness/nextgen/model_workload_date_count_info.go delete mode 100644 harness/nextgen/model_workload_deployment_info.go delete mode 100644 harness/nextgen/model_yaml_snippet_meta_data_dto.go diff --git a/go.mod b/go.mod index 20bebf7a..21eaa4c9 100644 --- a/go.mod +++ b/go.mod @@ -17,7 +17,7 @@ require ( github.com/opencontainers/image-spec v1.0.2 github.com/pkg/errors v0.9.1 github.com/stretchr/testify v1.7.0 - golang.org/x/net v0.0.0-20211111160137-58aab5ef257a // indirect + golang.org/x/net v0.0.0-20211118161319-6a13c67c3ce4 // indirect golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8 golang.org/x/sys v0.0.0-20210616094352-59db8d763f22 // indirect golang.org/x/time v0.0.0-20210723032227-1f47c861a9ac // indirect diff --git a/go.sum b/go.sum index f93b4b6f..67dc6043 100644 --- a/go.sum +++ b/go.sum @@ -716,6 +716,8 @@ golang.org/x/net v0.0.0-20201224014010-6772e930b67b/go.mod h1:m0MpNAwzfU5UDzcl9v golang.org/x/net v0.0.0-20210226172049-e18ecbb05110/go.mod h1:m0MpNAwzfU5UDzcl9v0D8zg8gWTRqZa9RBIspLL5mdg= golang.org/x/net v0.0.0-20211111160137-58aab5ef257a h1:c83jeVQW0KGKNaKBRfelNYNHaev+qawl9yaA825s8XE= golang.org/x/net v0.0.0-20211111160137-58aab5ef257a/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= +golang.org/x/net v0.0.0-20211118161319-6a13c67c3ce4 h1:DZshvxDdVoeKIbudAdFEKi+f70l51luSy/7b76ibTY0= +golang.org/x/net v0.0.0-20211118161319-6a13c67c3ce4/go.mod h1:9nx3DQGgdP8bBQD5qxJ1jj9UTztislL4KSBs9R2vV5Y= golang.org/x/oauth2 v0.0.0-20180821212333-d2e6202438be/go.mod h1:N/0e6XlmueqKjAGxoOufVs8QHGRruUQn6yWY3a++T0U= golang.org/x/oauth2 v0.0.0-20190226205417-e64efc72b421/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= golang.org/x/oauth2 v0.0.0-20190604053449-0f29369cfe45/go.mod h1:gOpvHmFTYa4IltrdGE7lF6nIHvwfUNPOp7c8zoXwtLw= diff --git a/harness/cd/graphql/model_delegate_scope.go b/harness/cd/graphql/model_delegate_scope.go new file mode 100644 index 00000000..33167d3b --- /dev/null +++ b/harness/cd/graphql/model_delegate_scope.go @@ -0,0 +1,5 @@ +package graphql + +type DelegateScope struct { + Applications +} diff --git a/harness/nextgen/README.md b/harness/nextgen/README.md index f40f461a..fa0bead6 100644 --- a/harness/nextgen/README.md +++ b/harness/nextgen/README.md @@ -33,269 +33,24 @@ Class | Method | HTTP request | Description *AuthenticationSettingsApi* | [**SetTwoFactorAuthAtAccountLevel**](docs/AuthenticationSettingsApi.md#settwofactorauthataccountlevel) | **Put** /authentication-settings/two-factor-admin-override-settings | set two factor auth at account lever by accountIdentifier *AuthenticationSettingsApi* | [**UpdateAuthMechanism**](docs/AuthenticationSettingsApi.md#updateauthmechanism) | **Put** /authentication-settings/update-auth-mechanism | Updates the Auth mechanism by accountIdentifier *AuthenticationSettingsApi* | [**UpdateOauthProviders**](docs/AuthenticationSettingsApi.md#updateoauthproviders) | **Put** /authentication-settings/oauth/update-providers | Updates the Oauth providers by accountIdentifier -*AuthenticationSettingsApi* | [**UpdateSamlMetaData**](docs/AuthenticationSettingsApi.md#updatesamlmetadata) | **Put** /authentication-settings/saml-metadata-upload | Uploads the saml metadata by accountId +*AuthenticationSettingsApi* | [**UpdateSamlMetaData**](docs/AuthenticationSettingsApi.md#updatesamlmetadata) | **Put** /authentication-settings/saml-metadata-upload | Updates the saml metadata by accountId *AuthenticationSettingsApi* | [**UpdateWhitelistedDomains**](docs/AuthenticationSettingsApi.md#updatewhitelisteddomains) | **Put** /authentication-settings/whitelisted-domains | Updates the Whitelisted domains by accountIdentifier -*AuthenticationSettingsApi* | [**UploadSamlMetaData**](docs/AuthenticationSettingsApi.md#uploadsamlmetadata) | **Post** /authentication-settings/saml-metadata-upload | +*AuthenticationSettingsApi* | [**UploadSamlMetaData**](docs/AuthenticationSettingsApi.md#uploadsamlmetadata) | **Post** /authentication-settings/saml-metadata-upload | Uploads the saml metadata by accountId *ConnectorsApi* | [**CreateConnector**](docs/ConnectorsApi.md#createconnector) | **Post** /connectors | Creates a Connector *ConnectorsApi* | [**DeleteConnector**](docs/ConnectorsApi.md#deleteconnector) | **Delete** /connectors/{identifier} | Deletes Connector by identifier *ConnectorsApi* | [**GetAllAllowedFieldValues**](docs/ConnectorsApi.md#getallallowedfieldvalues) | **Get** /connectors/fieldValues | Get the allowed field values by Connector Type *ConnectorsApi* | [**GetCEAwsTemplate**](docs/ConnectorsApi.md#getceawstemplate) | **Post** /connectors/getceawstemplateurl | Get the Template URL of connector *ConnectorsApi* | [**GetConnector**](docs/ConnectorsApi.md#getconnector) | **Get** /connectors/{identifier} | get the Connector by accountIdentifier and connectorIdentifier *ConnectorsApi* | [**GetConnectorCatalogue**](docs/ConnectorsApi.md#getconnectorcatalogue) | **Get** /connectors/catalogue | gets the connector catalogue by accountIdentifier -*ConnectorsApi* | [**GetConnectorList**](docs/ConnectorsApi.md#getconnectorlist) | **Get** /connectors | Get the list of connectors satisfying the criteria (if any) in the request -*ConnectorsApi* | [**GetConnectorListV2**](docs/ConnectorsApi.md#getconnectorlistv2) | **Post** /connectors/listV2 | Get the list of connectors satisfying the criteria (if any) in the request +*ConnectorsApi* | [**GetConnectorList**](docs/ConnectorsApi.md#getconnectorlist) | **Get** /connectors | Get the list of Connectors satisfying the criteria (if any) in the request +*ConnectorsApi* | [**GetConnectorListV2**](docs/ConnectorsApi.md#getconnectorlistv2) | **Post** /connectors/listV2 | Get the list of Connectors satisfying the criteria (if any) in the request *ConnectorsApi* | [**GetConnectorStatistics**](docs/ConnectorsApi.md#getconnectorstatistics) | **Get** /connectors/stats | gets the connector's statistics by accountIdentifier, projectIdentifier and orgIdentifier *ConnectorsApi* | [**GetConnectorValidationParams**](docs/ConnectorsApi.md#getconnectorvalidationparams) | **Get** /connectors/{identifier}/validation-params | -*ConnectorsApi* | [**GetTestConnectionResult**](docs/ConnectorsApi.md#gettestconnectionresult) | **Post** /connectors/testConnection/{identifier} | Tests the connection of the connector by Identifier +*ConnectorsApi* | [**GetTestConnectionResult**](docs/ConnectorsApi.md#gettestconnectionresult) | **Post** /connectors/testConnection/{identifier} | Tests the connection of the Connector by Identifier *ConnectorsApi* | [**GetTestGitRepoConnectionResult**](docs/ConnectorsApi.md#gettestgitrepoconnectionresult) | **Post** /connectors/testGitRepoConnection/{identifier} | Tests the created Connector's connection *ConnectorsApi* | [**ListConnectorByFQN**](docs/ConnectorsApi.md#listconnectorbyfqn) | **Post** /connectors/listbyfqn | Get the list of connectors by FQN satisfying the criteria (if any) in the request *ConnectorsApi* | [**PutConnector**](docs/ConnectorsApi.md#putconnector) | **Put** /connectors | Updates the Connector *ConnectorsApi* | [**ValidateTheIdentifierIsUnique**](docs/ConnectorsApi.md#validatetheidentifierisunique) | **Get** /connectors/validateUniqueIdentifier | validate the Connector by accountIdentifier and connectorIdentifier -*DefaultApi* | [**Accept**](docs/DefaultApi.md#accept) | **Get** /invites/accept | -*DefaultApi* | [**AddMember**](docs/DefaultApi.md#addmember) | **Put** /user-groups/{identifier}/member/{userIdentifier} | -*DefaultApi* | [**AddUsers**](docs/DefaultApi.md#addusers) | **Post** /user/users | -*DefaultApi* | [**ChangeUserPassword**](docs/DefaultApi.md#changeuserpassword) | **Put** /user/password | -*DefaultApi* | [**CheckIfLastAdmin**](docs/DefaultApi.md#checkiflastadmin) | **Get** /user/last-admin | -*DefaultApi* | [**CheckMember**](docs/DefaultApi.md#checkmember) | **Get** /user-groups/{identifier}/member/{userIdentifier} | -*DefaultApi* | [**CheckUserMembership**](docs/DefaultApi.md#checkusermembership) | **Get** /user/usermembership | -*DefaultApi* | [**CommunitySignup**](docs/DefaultApi.md#communitysignup) | **Post** /signup/community | -*DefaultApi* | [**CompleteInvite**](docs/DefaultApi.md#completeinvite) | **Get** /invites/complete | -*DefaultApi* | [**CompleteSignupInvite**](docs/DefaultApi.md#completesignupinvite) | **Put** /signup/complete/{token} | -*DefaultApi* | [**Create**](docs/DefaultApi.md#create) | **Post** /filters | -*DefaultApi* | [**Create1**](docs/DefaultApi.md#create1) | **Post** /gitopsproviders | -*DefaultApi* | [**Create10**](docs/DefaultApi.md#create10) | **Post** /user-groups | -*DefaultApi* | [**Create11**](docs/DefaultApi.md#create11) | **Post** /services | -*DefaultApi* | [**Create12**](docs/DefaultApi.md#create12) | **Post** /servicesV2 | -*DefaultApi* | [**Create2**](docs/DefaultApi.md#create2) | **Post** /git-sync-settings | -*DefaultApi* | [**Create3**](docs/DefaultApi.md#create3) | **Post** /git-sync | -*DefaultApi* | [**Create4**](docs/DefaultApi.md#create4) | **Post** /admin/licenses | -*DefaultApi* | [**Create5**](docs/DefaultApi.md#create5) | **Post** /roleassignments/multi/internal | -*DefaultApi* | [**Create6**](docs/DefaultApi.md#create6) | **Post** /roleassignments | -*DefaultApi* | [**Create7**](docs/DefaultApi.md#create7) | **Post** /environments | -*DefaultApi* | [**Create8**](docs/DefaultApi.md#create8) | **Post** /environmentsV2 | -*DefaultApi* | [**Create9**](docs/DefaultApi.md#create9) | **Post** /v2/secrets | -*DefaultApi* | [**CreateApiKey**](docs/DefaultApi.md#createapikey) | **Post** /apikey | -*DefaultApi* | [**CreateInvitations**](docs/DefaultApi.md#createinvitations) | **Post** /invites | -*DefaultApi* | [**CreatePR**](docs/DefaultApi.md#createpr) | **Post** /scm/createPR | -*DefaultApi* | [**CreateSecretFile**](docs/DefaultApi.md#createsecretfile) | **Post** /v2/secrets/files | -*DefaultApi* | [**CreateServiceAccount**](docs/DefaultApi.md#createserviceaccount) | **Post** /serviceaccount | -*DefaultApi* | [**CreateServices**](docs/DefaultApi.md#createservices) | **Post** /services/batch | -*DefaultApi* | [**CreateServices1**](docs/DefaultApi.md#createservices1) | **Post** /servicesV2/batch | -*DefaultApi* | [**CreateToken**](docs/DefaultApi.md#createtoken) | **Post** /token | -*DefaultApi* | [**CreateViaYaml**](docs/DefaultApi.md#createviayaml) | **Post** /v2/secrets/yaml | -*DefaultApi* | [**DecryptEncryptedDetails**](docs/DefaultApi.md#decryptencrypteddetails) | **Post** /v2/secrets/decrypt-encryption-details | -*DefaultApi* | [**Delete**](docs/DefaultApi.md#delete) | **Delete** /filters/{identifier} | -*DefaultApi* | [**Delete1**](docs/DefaultApi.md#delete1) | **Delete** /gitopsproviders/{identifier} | -*DefaultApi* | [**Delete10**](docs/DefaultApi.md#delete10) | **Delete** /source-code-manager/{identifier} | -*DefaultApi* | [**Delete2**](docs/DefaultApi.md#delete2) | **Delete** /entitySetupUsage/internal | -*DefaultApi* | [**Delete3**](docs/DefaultApi.md#delete3) | **Delete** /environments/{environmentIdentifier} | -*DefaultApi* | [**Delete4**](docs/DefaultApi.md#delete4) | **Delete** /environmentsV2/{environmentIdentifier} | -*DefaultApi* | [**Delete5**](docs/DefaultApi.md#delete5) | **Delete** /invites/{inviteId} | -*DefaultApi* | [**Delete6**](docs/DefaultApi.md#delete6) | **Delete** /v2/secrets/{identifier} | -*DefaultApi* | [**Delete7**](docs/DefaultApi.md#delete7) | **Delete** /user-groups/{identifier} | -*DefaultApi* | [**Delete8**](docs/DefaultApi.md#delete8) | **Delete** /services/{serviceIdentifier} | -*DefaultApi* | [**Delete9**](docs/DefaultApi.md#delete9) | **Delete** /servicesV2/{serviceIdentifier} | -*DefaultApi* | [**DeleteApiKey**](docs/DefaultApi.md#deleteapikey) | **Delete** /apikey/{identifier} | -*DefaultApi* | [**DeleteServiceAccount**](docs/DefaultApi.md#deleteserviceaccount) | **Delete** /serviceaccount/{identifier} | -*DefaultApi* | [**DeleteToken**](docs/DefaultApi.md#deletetoken) | **Delete** /token/{identifier} | -*DefaultApi* | [**DisableTFA**](docs/DefaultApi.md#disabletfa) | **Put** /user/disable-two-factor-auth | -*DefaultApi* | [**DummyApiForSwaggerSchemaCheck**](docs/DefaultApi.md#dummyapiforswaggerschemacheck) | **Get** /executions/dummyApiForSwaggerSchemaCheck | -*DefaultApi* | [**EvaluateCustomFeatureRestriction**](docs/DefaultApi.md#evaluatecustomfeaturerestriction) | **Put** /enforcement/client/custom/{featureRestrictionName} | -*DefaultApi* | [**Get**](docs/DefaultApi.md#get) | **Get** /filters/{identifier} | -*DefaultApi* | [**Get1**](docs/DefaultApi.md#get1) | **Get** /gitopsproviders/{identifier} | -*DefaultApi* | [**Get10**](docs/DefaultApi.md#get10) | **Get** /user-groups/{identifier} | -*DefaultApi* | [**Get11**](docs/DefaultApi.md#get11) | **Get** /services/{serviceIdentifier} | -*DefaultApi* | [**Get12**](docs/DefaultApi.md#get12) | **Get** /servicesV2/{serviceIdentifier} | -*DefaultApi* | [**Get13**](docs/DefaultApi.md#get13) | **Get** /source-code-manager | -*DefaultApi* | [**Get2**](docs/DefaultApi.md#get2) | **Get** /git-sync-settings | -*DefaultApi* | [**Get3**](docs/DefaultApi.md#get3) | **Post** /roleassignments/filter | -*DefaultApi* | [**Get4**](docs/DefaultApi.md#get4) | **Get** /environments/{environmentIdentifier} | -*DefaultApi* | [**Get5**](docs/DefaultApi.md#get5) | **Get** /environmentsV2/{environmentIdentifier} | -*DefaultApi* | [**Get6**](docs/DefaultApi.md#get6) | **Get** /health | -*DefaultApi* | [**Get7**](docs/DefaultApi.md#get7) | **Get** /aggregate/projects/{identifier} | -*DefaultApi* | [**Get8**](docs/DefaultApi.md#get8) | **Get** /aggregate/organizations/{identifier} | -*DefaultApi* | [**Get9**](docs/DefaultApi.md#get9) | **Get** /v2/secrets/{identifier} | -*DefaultApi* | [**GetAccessibleProjectsCount**](docs/DefaultApi.md#getaccessibleprojectscount) | **Get** /user/projects-count | -*DefaultApi* | [**GetAccountLicensesDTO**](docs/DefaultApi.md#getaccountlicensesdto) | **Get** /admin/licenses/{accountIdentifier} | -*DefaultApi* | [**GetAccountResourcesCount**](docs/DefaultApi.md#getaccountresourcescount) | **Get** /aggregate/account-resources | -*DefaultApi* | [**GetActiveDeploymentStats**](docs/DefaultApi.md#getactivedeploymentstats) | **Get** /landingDashboards/activeDeploymentStats | -*DefaultApi* | [**GetActiveInstancesByServiceIdEnvIdAndBuildIds**](docs/DefaultApi.md#getactiveinstancesbyserviceidenvidandbuildids) | **Get** /dashboard/getInstancesByServiceEnvAndBuilds | -*DefaultApi* | [**GetActiveServiceInstanceCountBreakdown**](docs/DefaultApi.md#getactiveserviceinstancecountbreakdown) | **Get** /dashboard/getInstanceCountDetailsByService | -*DefaultApi* | [**GetActiveServiceInstanceSummary**](docs/DefaultApi.md#getactiveserviceinstancesummary) | **Get** /dashboard/getActiveServiceInstanceSummary | -*DefaultApi* | [**GetActiveServices**](docs/DefaultApi.md#getactiveservices) | **Get** /landingDashboards/activeServices | -*DefaultApi* | [**GetActivitiesSummary**](docs/DefaultApi.md#getactivitiessummary) | **Get** /activityHistory/summary | -*DefaultApi* | [**GetAggregated**](docs/DefaultApi.md#getaggregated) | **Post** /roleassignments/aggregate | -*DefaultApi* | [**GetAggregatedApiKey**](docs/DefaultApi.md#getaggregatedapikey) | **Get** /apikey/aggregate/{identifier} | -*DefaultApi* | [**GetAggregatedServiceAccount**](docs/DefaultApi.md#getaggregatedserviceaccount) | **Get** /serviceaccount/aggregate/{identifier} | -*DefaultApi* | [**GetAggregatedUser**](docs/DefaultApi.md#getaggregateduser) | **Get** /user/aggregate/{userId} | -*DefaultApi* | [**GetAggregatedUsers**](docs/DefaultApi.md#getaggregatedusers) | **Post** /user/aggregate | -*DefaultApi* | [**GetBuckets**](docs/DefaultApi.md#getbuckets) | **Get** /buckets/s3/getBuckets | -*DefaultApi* | [**GetBuildDetails**](docs/DefaultApi.md#getbuilddetails) | **Get** /artifacts/docker/getBuildDetails | -*DefaultApi* | [**GetBuildDetails1**](docs/DefaultApi.md#getbuilddetails1) | **Get** /artifacts/ecr/getBuildDetails | -*DefaultApi* | [**GetBuildDetails2**](docs/DefaultApi.md#getbuilddetails2) | **Get** /artifacts/gcr/getBuildDetails | -*DefaultApi* | [**GetBuildDetails3**](docs/DefaultApi.md#getbuilddetails3) | **Post** /artifacts/gcr/getBuildDetailsV2 | -*DefaultApi* | [**GetBuildDetailsV2**](docs/DefaultApi.md#getbuilddetailsv2) | **Post** /artifacts/docker/getBuildDetailsV2 | -*DefaultApi* | [**GetBuildDetailsV21**](docs/DefaultApi.md#getbuilddetailsv21) | **Post** /artifacts/ecr/getBuildDetailsV2 | -*DefaultApi* | [**GetConnectivitySummary**](docs/DefaultApi.md#getconnectivitysummary) | **Get** /activityHistory/connectivityCheckSummary | -*DefaultApi* | [**GetCurrentGenUsers**](docs/DefaultApi.md#getcurrentgenusers) | **Get** /user/currentgen | -*DefaultApi* | [**GetDeploymentExecution**](docs/DefaultApi.md#getdeploymentexecution) | **Get** /dashboard/deploymentExecution | -*DefaultApi* | [**GetDeploymentExecutionInfo**](docs/DefaultApi.md#getdeploymentexecutioninfo) | **Get** /dashboard/serviceDeploymentsInfo | -*DefaultApi* | [**GetDeploymentHealth**](docs/DefaultApi.md#getdeploymenthealth) | **Get** /dashboard/deploymentHealth | -*DefaultApi* | [**GetDeploymentStatsSummary**](docs/DefaultApi.md#getdeploymentstatssummary) | **Get** /landingDashboards/deploymentStatsSummary | -*DefaultApi* | [**GetDeployments**](docs/DefaultApi.md#getdeployments) | **Get** /dashboard/getDeployments | -*DefaultApi* | [**GetDeploymentsByServiceId**](docs/DefaultApi.md#getdeploymentsbyserviceid) | **Get** /dashboard/getDeploymentsByServiceId | -*DefaultApi* | [**GetDummyCDPipelineModuleInfo**](docs/DefaultApi.md#getdummycdpipelinemoduleinfo) | **Get** /executions/dummyCDPipelineModuleInfo | -*DefaultApi* | [**GetDummyCDStageModuleInfo**](docs/DefaultApi.md#getdummycdstagemoduleinfo) | **Get** /executions/dummyCDStageModuleInfo | -*DefaultApi* | [**GetEncryptionDetails**](docs/DefaultApi.md#getencryptiondetails) | **Post** /v2/secrets/encryption-details | -*DefaultApi* | [**GetEnvBuildInstanceCount**](docs/DefaultApi.md#getenvbuildinstancecount) | **Get** /dashboard/getEnvBuildInstanceCountByService | -*DefaultApi* | [**GetEnvCount**](docs/DefaultApi.md#getenvcount) | **Get** /landingDashboards/envCount | -*DefaultApi* | [**GetErrorCount**](docs/DefaultApi.md#geterrorcount) | **Get** /git-sync-errors/count | -*DefaultApi* | [**GetExecutionStatuses**](docs/DefaultApi.md#getexecutionstatuses) | **Get** /executions/executionStatus | -*DefaultApi* | [**GetExecutionStrategyList**](docs/DefaultApi.md#getexecutionstrategylist) | **Get** /pipelines/configuration/strategies | -*DefaultApi* | [**GetExecutionStrategyYaml**](docs/DefaultApi.md#getexecutionstrategyyaml) | **Get** /pipelines/configuration/strategies/yaml-snippets | -*DefaultApi* | [**GetFeatureUsage**](docs/DefaultApi.md#getfeatureusage) | **Put** /enforcement/client/usage/{featureRestrictionName} | -*DefaultApi* | [**GetFileContent**](docs/DefaultApi.md#getfilecontent) | **Get** /scm/fileContent | -*DefaultApi* | [**GetImages**](docs/DefaultApi.md#getimages) | **Get** /artifacts/ecr/getImages | -*DefaultApi* | [**GetInstanceCountHistory**](docs/DefaultApi.md#getinstancecounthistory) | **Get** /dashboard/getInstanceCountHistory | -*DefaultApi* | [**GetInstanceGrowthTrend**](docs/DefaultApi.md#getinstancegrowthtrend) | **Get** /dashboard/getInstanceGrowthTrend | -*DefaultApi* | [**GetInstanceNGData**](docs/DefaultApi.md#getinstancengdata) | **Get** /instanceng | -*DefaultApi* | [**GetInviteWithToken**](docs/DefaultApi.md#getinvitewithtoken) | **Get** /invites/invite | -*DefaultApi* | [**GetInvites**](docs/DefaultApi.md#getinvites) | **Get** /invites | -*DefaultApi* | [**GetIssueCreateMetadata**](docs/DefaultApi.md#getissuecreatemetadata) | **Get** /jira/createMetadata | -*DefaultApi* | [**GetIssueUpdateMetadata**](docs/DefaultApi.md#getissueupdatemetadata) | **Get** /jira/updateMetadata | -*DefaultApi* | [**GetLabels**](docs/DefaultApi.md#getlabels) | **Post** /artifacts/docker/getLabels | -*DefaultApi* | [**GetLastSuccessfulBuild**](docs/DefaultApi.md#getlastsuccessfulbuild) | **Post** /artifacts/docker/getLastSuccessfulBuild | -*DefaultApi* | [**GetLastSuccessfulBuild1**](docs/DefaultApi.md#getlastsuccessfulbuild1) | **Post** /artifacts/ecr/getLastSuccessfulBuild | -*DefaultApi* | [**GetLastSuccessfulBuild2**](docs/DefaultApi.md#getlastsuccessfulbuild2) | **Post** /artifacts/gcr/getLastSuccessfulBuild | -*DefaultApi* | [**GetListBuckets**](docs/DefaultApi.md#getlistbuckets) | **Get** /buckets/gcs | -*DefaultApi* | [**GetPendingInvites**](docs/DefaultApi.md#getpendinginvites) | **Post** /invites/aggregate | -*DefaultApi* | [**GetProjects**](docs/DefaultApi.md#getprojects) | **Get** /jira/projects | -*DefaultApi* | [**GetProvisionerExecutionStrategyYaml**](docs/DefaultApi.md#getprovisionerexecutionstrategyyaml) | **Get** /pipelines/configuration/strategies/provisioner-yaml-snippets | Gets Yaml for Execution Strategy based on Provisioner Type -*DefaultApi* | [**GetProvisionerSteps**](docs/DefaultApi.md#getprovisionersteps) | **Get** /pipelines/configuration/provisioner-steps | Get provisioner steps -*DefaultApi* | [**GetSchemaFile**](docs/DefaultApi.md#getschemafile) | **Get** /yamlschema/schemafile | -*DefaultApi* | [**GetSecretEngines**](docs/DefaultApi.md#getsecretengines) | **Post** /secret-managers/meta-data | -*DefaultApi* | [**GetSecretManager**](docs/DefaultApi.md#getsecretmanager) | **Get** /secret-managers/{identifier} | -*DefaultApi* | [**GetServiceDefinitionTypes**](docs/DefaultApi.md#getservicedefinitiontypes) | **Get** /pipelines/configuration/serviceDefinitionTypes | -*DefaultApi* | [**GetServiceDeployment**](docs/DefaultApi.md#getservicedeployment) | **Get** /dashboard/serviceDeployments | -*DefaultApi* | [**GetServiceDeployments**](docs/DefaultApi.md#getservicedeployments) | **Get** /dashboard/serviceDetails | -*DefaultApi* | [**GetServiceHeaderInfo**](docs/DefaultApi.md#getserviceheaderinfo) | **Get** /dashboard/getServiceHeaderInfo | -*DefaultApi* | [**GetServicesCount**](docs/DefaultApi.md#getservicescount) | **Get** /landingDashboards/servicesCount | -*DefaultApi* | [**GetServicesGrowthTrend**](docs/DefaultApi.md#getservicesgrowthtrend) | **Get** /dashboard/getServicesGrowthTrend | -*DefaultApi* | [**GetStatuses**](docs/DefaultApi.md#getstatuses) | **Get** /jira/statuses | -*DefaultApi* | [**GetSteps**](docs/DefaultApi.md#getsteps) | **Get** /pipelines/configuration/steps | -*DefaultApi* | [**GetToken**](docs/DefaultApi.md#gettoken) | **Get** /token | -*DefaultApi* | [**GetTopProjects**](docs/DefaultApi.md#gettopprojects) | **Get** /landingDashboards/topProjects | -*DefaultApi* | [**GetTwoFactorAuthSettingsInfo**](docs/DefaultApi.md#gettwofactorauthsettingsinfo) | **Get** /user/two-factor-auth/{authMechanism} | -*DefaultApi* | [**GetUserAllProjectsInfo**](docs/DefaultApi.md#getuserallprojectsinfo) | **Get** /user/all-projects | -*DefaultApi* | [**GetUserInfo**](docs/DefaultApi.md#getuserinfo) | **Get** /user/currentUser | -*DefaultApi* | [**GetUserProjectInfo**](docs/DefaultApi.md#getuserprojectinfo) | **Get** /user/projects | -*DefaultApi* | [**GetUsers**](docs/DefaultApi.md#getusers) | **Post** /user/batch | -*DefaultApi* | [**GetUsersInUserGroup**](docs/DefaultApi.md#getusersinusergroup) | **Post** /user-groups/{identifier}/users | -*DefaultApi* | [**GetWorkloads**](docs/DefaultApi.md#getworkloads) | **Get** /dashboard/getWorkloads | -*DefaultApi* | [**GetYamlSchema**](docs/DefaultApi.md#getyamlschema) | **Get** /partial-yaml-schema | -*DefaultApi* | [**GetYamlSchema1**](docs/DefaultApi.md#getyamlschema1) | **Get** /yaml-schema | -*DefaultApi* | [**GetYamlSnippet**](docs/DefaultApi.md#getyamlsnippet) | **Get** /yaml-snippet/{identifier} | -*DefaultApi* | [**GetYamlSnippetsMetaData**](docs/DefaultApi.md#getyamlsnippetsmetadata) | **Get** /yaml-snippet | -*DefaultApi* | [**IsEntityReferenced**](docs/DefaultApi.md#isentityreferenced) | **Get** /entitySetupUsage/internal/isEntityReferenced | -*DefaultApi* | [**IsGitSyncEnabled**](docs/DefaultApi.md#isgitsyncenabled) | **Get** /git-sync/git-sync-enabled | -*DefaultApi* | [**IsSaasGit**](docs/DefaultApi.md#issaasgit) | **Post** /scm/isSaasGit | -*DefaultApi* | [**LinkToSamlGroup**](docs/DefaultApi.md#linktosamlgroup) | **Put** /user-groups/{userGroupId}/link/saml/{samlId} | -*DefaultApi* | [**List**](docs/DefaultApi.md#list) | **Get** /filters | -*DefaultApi* | [**List1**](docs/DefaultApi.md#list1) | **Get** /gitopsproviders/list | -*DefaultApi* | [**List10**](docs/DefaultApi.md#list10) | **Get** /v2/secrets | -*DefaultApi* | [**List11**](docs/DefaultApi.md#list11) | **Post** /user-groups/batch | -*DefaultApi* | [**List12**](docs/DefaultApi.md#list12) | **Get** /user-groups | -*DefaultApi* | [**List2**](docs/DefaultApi.md#list2) | **Get** /git-sync | -*DefaultApi* | [**List3**](docs/DefaultApi.md#list3) | **Get** /activityHistory | -*DefaultApi* | [**List4**](docs/DefaultApi.md#list4) | **Get** /entitySetupUsage | -*DefaultApi* | [**List5**](docs/DefaultApi.md#list5) | **Get** /aggregate/acl/usergroups | -*DefaultApi* | [**List6**](docs/DefaultApi.md#list6) | **Get** /aggregate/projects | -*DefaultApi* | [**List7**](docs/DefaultApi.md#list7) | **Post** /aggregate/acl/usergroups/filter | -*DefaultApi* | [**List8**](docs/DefaultApi.md#list8) | **Get** /aggregate/organizations | -*DefaultApi* | [**List9**](docs/DefaultApi.md#list9) | **Get** /aggregate/acl/usergroups/{identifier} | -*DefaultApi* | [**ListAccessEnvironment**](docs/DefaultApi.md#listaccessenvironment) | **Get** /environmentsV2/list/access | -*DefaultApi* | [**ListAccessServices**](docs/DefaultApi.md#listaccessservices) | **Get** /servicesV2/list/access | -*DefaultApi* | [**ListAggregatedApiKeys**](docs/DefaultApi.md#listaggregatedapikeys) | **Get** /apikey/aggregate | -*DefaultApi* | [**ListAggregatedServiceAccounts**](docs/DefaultApi.md#listaggregatedserviceaccounts) | **Get** /serviceaccount/aggregate | -*DefaultApi* | [**ListAggregatedTokens**](docs/DefaultApi.md#listaggregatedtokens) | **Get** /token/aggregate | -*DefaultApi* | [**ListAllEntityUsage**](docs/DefaultApi.md#listallentityusage) | **Get** /entitySetupUsage/internal | -*DefaultApi* | [**ListAllReferredUsages**](docs/DefaultApi.md#listallreferredusages) | **Get** /entitySetupUsage/internal/listAllReferredUsages | -*DefaultApi* | [**ListAllReferredUsagesBatch**](docs/DefaultApi.md#listallreferredusagesbatch) | **Post** /entitySetupUsage/internal/listAllReferredUsagesBatch | -*DefaultApi* | [**ListApiKeys**](docs/DefaultApi.md#listapikeys) | **Get** /apikey | -*DefaultApi* | [**ListBranchesForRepo**](docs/DefaultApi.md#listbranchesforrepo) | **Get** /scm/listRepoBranches | -*DefaultApi* | [**ListBranchesForRepo1**](docs/DefaultApi.md#listbranchesforrepo1) | **Get** /scm/listBranchesByGitConfig | -*DefaultApi* | [**ListBranchesWithStatusForRepo**](docs/DefaultApi.md#listbrancheswithstatusforrepo) | **Get** /git-sync-branch/listBranchesWithStatus | -*DefaultApi* | [**ListBranchesWithStatusForRepo1**](docs/DefaultApi.md#listbrancheswithstatusforrepo1) | **Post** /git-sync-branch/sync | -*DefaultApi* | [**ListByType**](docs/DefaultApi.md#listbytype) | **Get** /git-sync-entities/{entityType} | -*DefaultApi* | [**ListEnvironment**](docs/DefaultApi.md#listenvironment) | **Get** /environmentsV2 | -*DefaultApi* | [**ListEnvironmentsForProject**](docs/DefaultApi.md#listenvironmentsforproject) | **Get** /environments | -*DefaultApi* | [**ListGitSyncErrors**](docs/DefaultApi.md#listgitsyncerrors) | **Get** /git-sync-errors | -*DefaultApi* | [**ListGitSyncErrorsForACommit**](docs/DefaultApi.md#listgitsyncerrorsforacommit) | **Get** /git-sync-errors/commits/{commitId} | -*DefaultApi* | [**ListGitToHarnessErrorsGroupedByCommits**](docs/DefaultApi.md#listgittoharnesserrorsgroupedbycommits) | **Get** /git-sync-errors/aggregate | -*DefaultApi* | [**ListSecrets**](docs/DefaultApi.md#listsecrets) | **Post** /v2/secrets/list | -*DefaultApi* | [**ListServiceAccounts**](docs/DefaultApi.md#listserviceaccounts) | **Get** /serviceaccount | -*DefaultApi* | [**ListServices**](docs/DefaultApi.md#listservices) | **Get** /servicesV2 | -*DefaultApi* | [**ListServicesForProject**](docs/DefaultApi.md#listservicesforproject) | **Get** /services | -*DefaultApi* | [**ListSummary**](docs/DefaultApi.md#listsummary) | **Post** /git-sync-entities/summary | -*DefaultApi* | [**ListSummaryByRepoAndBranch**](docs/DefaultApi.md#listsummarybyrepoandbranch) | **Post** /git-sync-entities/branch/{branch} | -*DefaultApi* | [**ProcessInstanceSyncPerpetualTaskResponse**](docs/DefaultApi.md#processinstancesyncperpetualtaskresponse) | **Post** /instancesync/response | -*DefaultApi* | [**ProcessPollingResultNg**](docs/DefaultApi.md#processpollingresultng) | **Post** /polling/delegate-response/{perpetualTaskId} | -*DefaultApi* | [**RemoveMember**](docs/DefaultApi.md#removemember) | **Delete** /user-groups/{identifier}/member/{userIdentifier} | -*DefaultApi* | [**RemoveUser**](docs/DefaultApi.md#removeuser) | **Delete** /user/{userId} | -*DefaultApi* | [**RemoveUserInternal**](docs/DefaultApi.md#removeuserinternal) | **Delete** /user/internal/{userId} | -*DefaultApi* | [**ResendVerifyEmail**](docs/DefaultApi.md#resendverifyemail) | **Post** /signup/verify-notification | -*DefaultApi* | [**RotateToken**](docs/DefaultApi.md#rotatetoken) | **Post** /token/rotate/{identifier} | -*DefaultApi* | [**Save**](docs/DefaultApi.md#save) | **Post** /activityHistory | -*DefaultApi* | [**Save1**](docs/DefaultApi.md#save1) | **Post** /entitySetupUsage/internal | -*DefaultApi* | [**Save2**](docs/DefaultApi.md#save2) | **Post** /source-code-manager | -*DefaultApi* | [**Signup**](docs/DefaultApi.md#signup) | **Post** /signup | -*DefaultApi* | [**SignupOAuth**](docs/DefaultApi.md#signupoauth) | **Post** /signup/oauth | -*DefaultApi* | [**Subscribe**](docs/DefaultApi.md#subscribe) | **Post** /polling/subscribe | -*DefaultApi* | [**UnlinkSsoGroup**](docs/DefaultApi.md#unlinkssogroup) | **Put** /user-groups/{userGroupId}/unlink | -*DefaultApi* | [**UnlockUser**](docs/DefaultApi.md#unlockuser) | **Put** /user/unlock-user/{userId} | -*DefaultApi* | [**Unsubscribe**](docs/DefaultApi.md#unsubscribe) | **Post** /polling/unsubscribe | -*DefaultApi* | [**Update**](docs/DefaultApi.md#update) | **Put** /filters | -*DefaultApi* | [**Update1**](docs/DefaultApi.md#update1) | **Put** /gitopsproviders | -*DefaultApi* | [**Update10**](docs/DefaultApi.md#update10) | **Put** /source-code-manager/{identifier} | -*DefaultApi* | [**Update2**](docs/DefaultApi.md#update2) | **Put** /git-sync-settings | -*DefaultApi* | [**Update3**](docs/DefaultApi.md#update3) | **Put** /git-sync | -*DefaultApi* | [**Update4**](docs/DefaultApi.md#update4) | **Put** /admin/licenses/{identifier} | -*DefaultApi* | [**Update5**](docs/DefaultApi.md#update5) | **Put** /environments | -*DefaultApi* | [**Update6**](docs/DefaultApi.md#update6) | **Put** /environmentsV2 | -*DefaultApi* | [**Update7**](docs/DefaultApi.md#update7) | **Put** /user-groups | -*DefaultApi* | [**Update8**](docs/DefaultApi.md#update8) | **Put** /services | -*DefaultApi* | [**Update9**](docs/DefaultApi.md#update9) | **Put** /servicesV2 | -*DefaultApi* | [**UpdateApiKey**](docs/DefaultApi.md#updateapikey) | **Put** /apikey/{identifier} | -*DefaultApi* | [**UpdateDefault**](docs/DefaultApi.md#updatedefault) | **Put** /git-sync/{identifier}/folder/{folderIdentifier}/default | -*DefaultApi* | [**UpdateInvite**](docs/DefaultApi.md#updateinvite) | **Put** /invites/{inviteId} | -*DefaultApi* | [**UpdateSecret**](docs/DefaultApi.md#updatesecret) | **Put** /v2/secrets/{identifier} | -*DefaultApi* | [**UpdateSecretFile**](docs/DefaultApi.md#updatesecretfile) | **Put** /v2/secrets/files/{identifier} | -*DefaultApi* | [**UpdateSecretViaYaml**](docs/DefaultApi.md#updatesecretviayaml) | **Put** /v2/secrets/{identifier}/yaml | -*DefaultApi* | [**UpdateServiceAccount**](docs/DefaultApi.md#updateserviceaccount) | **Put** /serviceaccount/{identifier} | -*DefaultApi* | [**UpdateToken**](docs/DefaultApi.md#updatetoken) | **Put** /token/{identifier} | -*DefaultApi* | [**UpdateTwoFactorAuthInfo**](docs/DefaultApi.md#updatetwofactorauthinfo) | **Put** /user/enable-two-factor-auth | -*DefaultApi* | [**UpdateUserInfo**](docs/DefaultApi.md#updateuserinfo) | **Put** /user | -*DefaultApi* | [**Upsert**](docs/DefaultApi.md#upsert) | **Put** /environments/upsert | -*DefaultApi* | [**Upsert1**](docs/DefaultApi.md#upsert1) | **Put** /environmentsV2/upsert | -*DefaultApi* | [**Upsert2**](docs/DefaultApi.md#upsert2) | **Put** /services/upsert | -*DefaultApi* | [**Upsert3**](docs/DefaultApi.md#upsert3) | **Put** /servicesV2/upsert | -*DefaultApi* | [**UpsertWebhook**](docs/DefaultApi.md#upsertwebhook) | **Post** /webhookevent | -*DefaultApi* | [**ValidateArtifact**](docs/DefaultApi.md#validateartifact) | **Post** /artifacts/docker/validateArtifact | -*DefaultApi* | [**ValidateArtifact1**](docs/DefaultApi.md#validateartifact1) | **Post** /artifacts/ecr/validateArtifact | -*DefaultApi* | [**ValidateArtifact2**](docs/DefaultApi.md#validateartifact2) | **Post** /artifacts/gcr/validateArtifact | -*DefaultApi* | [**ValidateArtifactImage**](docs/DefaultApi.md#validateartifactimage) | **Get** /artifacts/docker/validateArtifactSource | -*DefaultApi* | [**ValidateArtifactImage1**](docs/DefaultApi.md#validateartifactimage1) | **Get** /artifacts/ecr/validateArtifactSource | -*DefaultApi* | [**ValidateArtifactImage2**](docs/DefaultApi.md#validateartifactimage2) | **Get** /artifacts/gcr/validateArtifactSource | -*DefaultApi* | [**ValidateArtifactServer**](docs/DefaultApi.md#validateartifactserver) | **Get** /artifacts/docker/validateArtifactServer | -*DefaultApi* | [**ValidateArtifactServer1**](docs/DefaultApi.md#validateartifactserver1) | **Get** /artifacts/ecr/validateArtifactServer | -*DefaultApi* | [**ValidateArtifactServer2**](docs/DefaultApi.md#validateartifactserver2) | **Get** /artifacts/gcr/validateArtifactServer | -*DefaultApi* | [**ValidateCredentials**](docs/DefaultApi.md#validatecredentials) | **Get** /jira/validate | -*DefaultApi* | [**ValidateSecret**](docs/DefaultApi.md#validatesecret) | **Post** /v2/secrets/validate | -*DefaultApi* | [**ValidateTheIdentifierIsUnique1**](docs/DefaultApi.md#validatetheidentifierisunique1) | **Get** /gitopsproviders/validateUniqueIdentifier | -*DefaultApi* | [**ValidateTheIdentifierIsUnique2**](docs/DefaultApi.md#validatetheidentifierisunique2) | **Get** /v2/secrets/validateUniqueIdentifier/{identifier} | -*DefaultApi* | [**VerifyInviteViaNGAuthUi**](docs/DefaultApi.md#verifyinviteviangauthui) | **Get** /invites/verify | -*DefaultApi* | [**VerifyToken**](docs/DefaultApi.md#verifytoken) | **Post** /signup/verify/{token} | -*DefaultApi* | [**WebhookCatcher**](docs/DefaultApi.md#webhookcatcher) | **Post** /git-sync-trigger/webhook/{entityToken} | *DelegateConfigurationManagementApi* | [**CreateDelegateConfiguration**](docs/DelegateConfigurationManagementApi.md#createdelegateconfiguration) | **Post** /delegate-profiles/ng | Creates Delegate Configuration specified by Configuration details in body *DelegateConfigurationManagementApi* | [**DeleteDelegateConfig**](docs/DelegateConfigurationManagementApi.md#deletedelegateconfig) | **Delete** /delegate-profiles/ng/{delegateProfileId} | Deletes Delegate Configuration specified by Id *DelegateConfigurationManagementApi* | [**GetDelegateConfigrationDetails**](docs/DelegateConfigurationManagementApi.md#getdelegateconfigrationdetails) | **Get** /delegate-profiles/ng/{delegateProfileId} | Retrieves Delegate Configuration details for given Delegate Configuration Id. @@ -312,22 +67,58 @@ Class | Method | HTTP request | Description *DelegateConfigurationResourceApi* | [**UpdateDelegateConfigurationV2**](docs/DelegateConfigurationResourceApi.md#updatedelegateconfigurationv2) | **Put** /v2/accounts/{accountId}/delegate-configs/{delegateConfigIdentifier} | Updates Delegate Configuration specified by Identifier *DelegateConfigurationResourceApi* | [**UpdateDelegateSelectorsV2**](docs/DelegateConfigurationResourceApi.md#updatedelegateselectorsv2) | **Put** /v2/accounts/{accountId}/delegate-configs/{delegateConfigIdentifier}/selectors | Updates Delegate selectors for Delegate Configuration specified by identifier *DelegateConfigurationResourceApi* | [**UpdateScopingRulesV2**](docs/DelegateConfigurationResourceApi.md#updatescopingrulesv2) | **Put** /v2/accounts/{accountId}/delegate-configs/{delegateConfigIdentifier}/scoping-rules | Updates Scoping Rules for the Delegate Configuration specified by identifier -*EnforcementApi* | [**GetAllFeatureRestrictionMetadata**](docs/EnforcementApi.md#getallfeaturerestrictionmetadata) | **Get** /enforcement/metadata | Gets All Feature Restriction Metadata -*EnforcementApi* | [**GetEnabledFeatureRestrictionDetailByAccountId**](docs/EnforcementApi.md#getenabledfeaturerestrictiondetailbyaccountid) | **Get** /enforcement/enabled | Gets List of Enabled Feature Restriction Detail for The Account -*EnforcementApi* | [**GetFeatureRestrictionDetail**](docs/EnforcementApi.md#getfeaturerestrictiondetail) | **Post** /enforcement | Gets Feature Restriction Detail -*EnforcementApi* | [**GetFeatureRestrictionMetadata**](docs/EnforcementApi.md#getfeaturerestrictionmetadata) | **Get** /enforcement/{featureRestrictionName}/metadata | -*EnforcementApi* | [**GetFeatureRestrictionMetadataMap**](docs/EnforcementApi.md#getfeaturerestrictionmetadatamap) | **Post** /enforcement/metadata | +*EnforcementApi* | [**GetAllFeatureRestrictionMetadata**](docs/EnforcementApi.md#getallfeaturerestrictionmetadata) | **Get** /enforcement/metadata | Fetch All Feature Restriction Metadata +*EnforcementApi* | [**GetEnabledFeatureRestrictionDetailByAccountId**](docs/EnforcementApi.md#getenabledfeaturerestrictiondetailbyaccountid) | **Get** /enforcement/enabled | Fetch List of Enabled Feature Restriction Detail for The Account +*EnforcementApi* | [**GetFeatureRestrictionDetail**](docs/EnforcementApi.md#getfeaturerestrictiondetail) | **Post** /enforcement | Fetch Feature Restriction Detail +*EnforcementApi* | [**GetFeatureRestrictionDetails**](docs/EnforcementApi.md#getfeaturerestrictiondetails) | **Post** /enforcement/details | Fetch List of Feature Restriction Detail +*EnvironmentsApi* | [**CreateEnvironmentV2**](docs/EnvironmentsApi.md#createenvironmentv2) | **Post** /environmentsV2 | Create an Environment +*EnvironmentsApi* | [**DeleteEnvironmentV2**](docs/EnvironmentsApi.md#deleteenvironmentv2) | **Delete** /environmentsV2/{environmentIdentifier} | Delete an Environment by identifier +*EnvironmentsApi* | [**GetEnvironmentAccessList**](docs/EnvironmentsApi.md#getenvironmentaccesslist) | **Get** /environmentsV2/list/access | Gets Environment Access list +*EnvironmentsApi* | [**GetEnvironmentList**](docs/EnvironmentsApi.md#getenvironmentlist) | **Get** /environmentsV2 | Gets Environment list for a project +*EnvironmentsApi* | [**GetEnvironmentV2**](docs/EnvironmentsApi.md#getenvironmentv2) | **Get** /environmentsV2/{environmentIdentifier} | Gets an Environment by identifier +*EnvironmentsApi* | [**UpdateEnvironmentV2**](docs/EnvironmentsApi.md#updateenvironmentv2) | **Put** /environmentsV2 | Update an Environment by identifier +*EnvironmentsApi* | [**UpsertEnvironmentV2**](docs/EnvironmentsApi.md#upsertenvironmentv2) | **Put** /environmentsV2/upsert | Upsert an Environment by identifier *FeedbackApi* | [**SaveFeedback**](docs/FeedbackApi.md#savefeedback) | **Post** /feedback | Saves Feedback +*FilterApi* | [**DeleteFilter**](docs/FilterApi.md#deletefilter) | **Delete** /filters/{identifier} | Delete a Filter by identifier +*FilterApi* | [**GetConnectorListV21**](docs/FilterApi.md#getconnectorlistv21) | **Get** /filters | Get the list of Filters satisfying the criteria (if any) in the request +*FilterApi* | [**GetFilter**](docs/FilterApi.md#getfilter) | **Get** /filters/{identifier} | Gets a Filter by identifier +*FilterApi* | [**PostFilter**](docs/FilterApi.md#postfilter) | **Post** /filters | Creates a Filter +*FilterApi* | [**UpdateFilter**](docs/FilterApi.md#updatefilter) | **Put** /filters | Updates the Filter +*FullSyncApi* | [**TriggerFullSync**](docs/FullSyncApi.md#triggerfullsync) | **Post** /full-sync | Triggers Full Sync *GcpClustersApi* | [**GetClusterNamesForGcp**](docs/GcpClustersApi.md#getclusternamesforgcp) | **Get** /gcp/clusters | Gets gcp cluster names -*LicensesApi* | [**CheckExpiry**](docs/LicensesApi.md#checkexpiry) | **Get** /licenses/{accountId}/check-expiry | +*GitBranchesApi* | [**GetListOfBranchesWithStatus**](docs/GitBranchesApi.md#getlistofbrancheswithstatus) | **Get** /git-sync-branch/listBranchesWithStatus | Lists branches with their status(Synced, Unsynced) by Git Sync Config Identifier for the given scope +*GitBranchesApi* | [**SyncGitBranch**](docs/GitBranchesApi.md#syncgitbranch) | **Post** /git-sync-branch/sync | Sync the content of new Git Branch into harness with Git Sync Config Identifier +*GitSyncApi* | [**CreateGitSyncConfig**](docs/GitSyncApi.md#creategitsyncconfig) | **Post** /git-sync | Creates Git Sync Config in given scope +*GitSyncApi* | [**GetGitSyncConfigList**](docs/GitSyncApi.md#getgitsyncconfiglist) | **Get** /git-sync | Lists Git Sync Config for the given scope +*GitSyncApi* | [**IsGitSyncEnabled**](docs/GitSyncApi.md#isgitsyncenabled) | **Get** /git-sync/git-sync-enabled | Check whether Git Sync is enabled for given scope or not +*GitSyncApi* | [**UpdateDefaultFolder**](docs/GitSyncApi.md#updatedefaultfolder) | **Put** /git-sync/{identifier}/folder/{folderIdentifier}/default | Update existing Git Sync Config default root folder by Identifier +*GitSyncApi* | [**UpdateGitSyncConfig**](docs/GitSyncApi.md#updategitsyncconfig) | **Put** /git-sync | Update existing Git Sync Config by Identifier +*GitSyncEntitiesApi* | [**ListGitSyncEntitiesByType**](docs/GitSyncEntitiesApi.md#listgitsyncentitiesbytype) | **Get** /git-sync-entities/{entityType} | Lists Git Sync Entity filtered by their Type for the given scope +*GitSyncEntitiesApi* | [**ListGitSyncEntitiesSummaryForRepoAndBranch**](docs/GitSyncEntitiesApi.md#listgitsyncentitiessummaryforrepoandbranch) | **Post** /git-sync-entities/branch/{branch} | Lists Git Sync Entity by product for the given Repo, Branch and list of Entity Types +*GitSyncEntitiesApi* | [**ListGitSyncEntitiesSummaryForRepoAndTypes**](docs/GitSyncEntitiesApi.md#listgitsyncentitiessummaryforrepoandtypes) | **Post** /git-sync-entities/summary | Lists Git Sync Entity by product for the given list of Repos and Entity Types +*GitSyncErrorsApi* | [**GetGitSyncErrorsCount**](docs/GitSyncErrorsApi.md#getgitsyncerrorscount) | **Get** /git-sync-errors/count | Get Errors Count for the given scope, Repo and Branch +*GitSyncErrorsApi* | [**ListGitSyncErrors**](docs/GitSyncErrorsApi.md#listgitsyncerrors) | **Get** /git-sync-errors | Lists Git to Harness Errors by file or connectivity errors for the given scope, Repo and Branch +*GitSyncErrorsApi* | [**ListGitToHarnessErrorForCommit**](docs/GitSyncErrorsApi.md#listgittoharnesserrorforcommit) | **Get** /git-sync-errors/commits/{commitId} | Lists Git to Harness Errors for the given Commit Id +*GitSyncErrorsApi* | [**ListGitToHarnessErrorsGroupedByCommits**](docs/GitSyncErrorsApi.md#listgittoharnesserrorsgroupedbycommits) | **Get** /git-sync-errors/aggregate | Lists Git to Harness Errors grouped by Commits for the given scope, Repo and Branch +*GitSyncSettingsApi* | [**CreateGitSyncSetting**](docs/GitSyncSettingsApi.md#creategitsyncsetting) | **Post** /git-sync-settings | Creates Git Sync Setting in a scope +*GitSyncSettingsApi* | [**GetGitSyncSettings**](docs/GitSyncSettingsApi.md#getgitsyncsettings) | **Get** /git-sync-settings | Get Git Sync Setting for the given scope +*GitSyncSettingsApi* | [**UpdateGitSyncSetting**](docs/GitSyncSettingsApi.md#updategitsyncsetting) | **Put** /git-sync-settings | Update existing Git Sync Setting by scope. Only changing execution on delegate is allowed +*InviteApi* | [**Accept**](docs/InviteApi.md#accept) | **Get** /invites/accept | +*InviteApi* | [**CompleteInvite**](docs/InviteApi.md#completeinvite) | **Get** /invites/complete | Complete the User Invite +*InviteApi* | [**DeleteInvite**](docs/InviteApi.md#deleteinvite) | **Delete** /invites/{inviteId} | Delete an Invite by Identifier +*InviteApi* | [**GetInvite**](docs/InviteApi.md#getinvite) | **Get** /invites/invite | Gets an Invite by either Invite Id or JwtToken +*InviteApi* | [**GetInvites**](docs/InviteApi.md#getinvites) | **Get** /invites | List all the Invites for a Project or Organization +*InviteApi* | [**GetPendingUsersAggregated**](docs/InviteApi.md#getpendingusersaggregated) | **Post** /invites/aggregate | List of all the Invites pending users +*InviteApi* | [**SendInvite**](docs/InviteApi.md#sendinvite) | **Post** /invites | Send a user Invite to either Project or Organization +*InviteApi* | [**UpdateInvite**](docs/InviteApi.md#updateinvite) | **Put** /invites/{inviteId} | Resend the Invite email +*InviteApi* | [**VerifyInviteViaNGAuthUi**](docs/InviteApi.md#verifyinviteviangauthui) | **Get** /invites/verify | *LicensesApi* | [**ExtendTrialLicense**](docs/LicensesApi.md#extendtriallicense) | **Post** /licenses/extend-trial | Extends Trial License For A Module *LicensesApi* | [**GetAccountLicenses**](docs/LicensesApi.md#getaccountlicenses) | **Get** /licenses/account | Gets All Module License Information in Account *LicensesApi* | [**GetEditionActions**](docs/LicensesApi.md#geteditionactions) | **Get** /licenses/actions | Get Allowed Actions Under Each Edition +*LicensesApi* | [**GetLastModifiedTimeForAllModuleTypes**](docs/LicensesApi.md#getlastmodifiedtimeforallmoduletypes) | **Post** /licenses/versions | Get Last Modified Time Under Each ModuleType *LicensesApi* | [**GetLicensesAndSummary**](docs/LicensesApi.md#getlicensesandsummary) | **Get** /licenses/{accountIdentifier}/summary | Gets Module Licenses With Summary By Account And ModuleType -*LicensesApi* | [**GetModuleLicenseByAccountAndModuleType**](docs/LicensesApi.md#getmodulelicensebyaccountandmoduletype) | **Get** /licenses | Gets Module License By Account And ModuleType *LicensesApi* | [**GetModuleLicenseById**](docs/LicensesApi.md#getmodulelicensebyid) | **Get** /licenses/{identifier} | Gets Module License *LicensesApi* | [**GetModuleLicensesByAccountAndModuleType**](docs/LicensesApi.md#getmodulelicensesbyaccountandmoduletype) | **Get** /licenses/modules/{accountIdentifier} | Gets Module Licenses By Account And ModuleType -*LicensesApi* | [**SoftDelete**](docs/LicensesApi.md#softdelete) | **Get** /licenses/{accountId}/soft-delete | *LicensesApi* | [**StartCommunityLicense**](docs/LicensesApi.md#startcommunitylicense) | **Post** /licenses/community | *LicensesApi* | [**StartFreeLicense**](docs/LicensesApi.md#startfreelicense) | **Post** /licenses/free | Starts Free License For A Module *LicensesApi* | [**StartTrialLicense**](docs/LicensesApi.md#starttriallicense) | **Post** /licenses/trial | Starts Trial License For A Module @@ -335,13 +126,30 @@ Class | Method | HTTP request | Description *OrganizationApi* | [**DeleteOrganization**](docs/OrganizationApi.md#deleteorganization) | **Delete** /organizations/{identifier} | Deletes Organization by identifier *OrganizationApi* | [**GetOrganization**](docs/OrganizationApi.md#getorganization) | **Get** /organizations/{identifier} | Get the Organization by accountIdentifier and orgIdentifier *OrganizationApi* | [**GetOrganizationList**](docs/OrganizationApi.md#getorganizationlist) | **Get** /organizations | Get the list of organizations satisfying the criteria (if any) in the request -*OrganizationApi* | [**ListAllOrganizations**](docs/OrganizationApi.md#listallorganizations) | **Get** /organizations/all-organizations | +*OrganizationApi* | [**ListAllOrganizations**](docs/OrganizationApi.md#listallorganizations) | **Post** /organizations/all-organizations | *OrganizationApi* | [**PutOrganization**](docs/OrganizationApi.md#putorganization) | **Put** /organizations/{identifier} | Updates the Organization -*ProjectApi* | [**DeleteProject**](docs/ProjectApi.md#deleteproject) | **Delete** /projects/{identifier} | Delete a project by identifier +*ProjectApi* | [**DeleteProject**](docs/ProjectApi.md#deleteproject) | **Delete** /projects/{identifier} | Delete a Project by identifier *ProjectApi* | [**GetProject**](docs/ProjectApi.md#getproject) | **Get** /projects/{identifier} | Gets a Project by identifier *ProjectApi* | [**GetProjectList**](docs/ProjectApi.md#getprojectlist) | **Get** /projects | List user's project *ProjectApi* | [**PostProject**](docs/ProjectApi.md#postproject) | **Post** /projects | Creates a Project -*ProjectApi* | [**PutProject**](docs/ProjectApi.md#putproject) | **Put** /projects/{identifier} | Update project by identifier +*ProjectApi* | [**PutProject**](docs/ProjectApi.md#putproject) | **Put** /projects/{identifier} | Update Project by identifier +*ScmApi* | [**CreatePR**](docs/ScmApi.md#createpr) | **Post** /scm/createPR | creates a Pull Request +*ScmApi* | [**GetFileContent**](docs/ScmApi.md#getfilecontent) | **Get** /scm/fileContent | Gets Git File Content +*ScmApi* | [**GetListOfBranchesByConnector**](docs/ScmApi.md#getlistofbranchesbyconnector) | **Get** /scm/listRepoBranches | Lists Branches of given Repo by referenced Connector Identifier +*ScmApi* | [**GetListOfBranchesByGitConfig**](docs/ScmApi.md#getlistofbranchesbygitconfig) | **Get** /scm/listBranchesByGitConfig | Lists Branches by given Git Sync Config Identifier +*ScmApi* | [**IsSaasGit**](docs/ScmApi.md#issaasgit) | **Post** /scm/isSaasGit | Checks if Saas is possible for given Repo Url +*ServicesApi* | [**CreateServiceV2**](docs/ServicesApi.md#createservicev2) | **Post** /servicesV2 | Create a Service +*ServicesApi* | [**CreateServicesV2**](docs/ServicesApi.md#createservicesv2) | **Post** /servicesV2/batch | Create Services +*ServicesApi* | [**DeleteServiceV2**](docs/ServicesApi.md#deleteservicev2) | **Delete** /servicesV2/{serviceIdentifier} | Delete a Service by identifier +*ServicesApi* | [**GetServiceAccessList**](docs/ServicesApi.md#getserviceaccesslist) | **Get** /servicesV2/list/access | Gets Service Access list +*ServicesApi* | [**GetServiceList**](docs/ServicesApi.md#getservicelist) | **Get** /servicesV2 | Gets Service list +*ServicesApi* | [**GetServiceV2**](docs/ServicesApi.md#getservicev2) | **Get** /servicesV2/{serviceIdentifier} | Gets a Service by identifier +*ServicesApi* | [**UpdateServiceV2**](docs/ServicesApi.md#updateservicev2) | **Put** /servicesV2 | Update a Service by identifier +*ServicesApi* | [**UpsertServiceV2**](docs/ServicesApi.md#upsertservicev2) | **Put** /servicesV2/upsert | Upsert a Service by identifier +*SourceCodeManagerApi* | [**CreateSourceCodeManager**](docs/SourceCodeManagerApi.md#createsourcecodemanager) | **Post** /source-code-manager | Creates Source Code Manager +*SourceCodeManagerApi* | [**DeleteSourceCodeManager**](docs/SourceCodeManagerApi.md#deletesourcecodemanager) | **Delete** /source-code-manager/{identifier} | Deletes the Source Code Manager corresponding to the specified Source Code Manager Id +*SourceCodeManagerApi* | [**GetSourceCodeManagers**](docs/SourceCodeManagerApi.md#getsourcecodemanagers) | **Get** /source-code-manager | Lists Source Code Managers for the given account +*SourceCodeManagerApi* | [**UpdateSourceCodeManager**](docs/SourceCodeManagerApi.md#updatesourcecodemanager) | **Put** /source-code-manager/{identifier} | Updates Source Code Manager Details with the given Source Code Manager Id *WebhookEventHandlerApi* | [**ProcessWebhookEvent**](docs/WebhookEventHandlerApi.md#processwebhookevent) | **Post** /webhook | Process event payload for webhook triggers. ## Documentation For Models @@ -351,648 +159,290 @@ Class | Method | HTTP request | Description - [AccountLicense](docs/AccountLicense.md) - [AccountPermissions](docs/AccountPermissions.md) - [AccountPreferences](docs/AccountPreferences.md) - - [AccountResourcesDto](docs/AccountResourcesDto.md) - [AclAggregateFilter](docs/AclAggregateFilter.md) - - [ActiveProjectsCountDto](docs/ActiveProjectsCountDto.md) - - [ActiveServiceInstanceSummary](docs/ActiveServiceInstanceSummary.md) - - [ActivityDetail](docs/ActivityDetail.md) - - [AddUsersDto](docs/AddUsersDto.md) - - [AddUsersResponse](docs/AddUsersResponse.md) - - [AdditionalMetadata](docs/AdditionalMetadata.md) - - [AggregateAclRequest](docs/AggregateAclRequest.md) - - [ApiKeyAggregateDto](docs/ApiKeyAggregateDto.md) - - [ApiKeyDto](docs/ApiKeyDto.md) - [AppDynamicsConnectorDto](docs/AppDynamicsConnectorDto.md) - [AppPermission](docs/AppPermission.md) - - [ArtifactSummary](docs/ArtifactSummary.md) - - [ArtifactoryAuthCredentialsDto](docs/ArtifactoryAuthCredentialsDto.md) - - [ArtifactoryAuthenticationDto](docs/ArtifactoryAuthenticationDto.md) - - [ArtifactoryConnectorDto](docs/ArtifactoryConnectorDto.md) - - [ArtifactoryUsernamePasswordAuthDto](docs/ArtifactoryUsernamePasswordAuthDto.md) - - [ArtifactsSummary](docs/ArtifactsSummary.md) + - [ArtifactoryAuthCredentials](docs/ArtifactoryAuthCredentials.md) + - [ArtifactoryAuthentication](docs/ArtifactoryAuthentication.md) + - [ArtifactoryConnector](docs/ArtifactoryConnector.md) + - [ArtifactoryUsernamePasswordAuth](docs/ArtifactoryUsernamePasswordAuth.md) - [AuthenticationSettingsResponse](docs/AuthenticationSettingsResponse.md) - [AuthenticationsettingsSamlmetadatauploadBody](docs/AuthenticationsettingsSamlmetadatauploadBody.md) - [AuthenticationsettingsSamlmetadatauploadBody1](docs/AuthenticationsettingsSamlmetadatauploadBody1.md) - - [AuthorInfo](docs/AuthorInfo.md) - - [AvailabilityRestrictionDto](docs/AvailabilityRestrictionDto.md) - - [AvailabilityRestrictionMetadataDto](docs/AvailabilityRestrictionMetadataDto.md) - - [AwsCodeCommitAuthenticationDto](docs/AwsCodeCommitAuthenticationDto.md) - - [AwsCodeCommitConnectorDto](docs/AwsCodeCommitConnectorDto.md) - - [AwsCodeCommitCredentialsDto](docs/AwsCodeCommitCredentialsDto.md) - - [AwsCodeCommitHttpsCredentialsDto](docs/AwsCodeCommitHttpsCredentialsDto.md) - - [AwsCodeCommitHttpsCredentialsSpecDto](docs/AwsCodeCommitHttpsCredentialsSpecDto.md) - - [AwsCodeCommitSecretKeyAccessKeyDto](docs/AwsCodeCommitSecretKeyAccessKeyDto.md) - - [AwsConnectorDto](docs/AwsConnectorDto.md) - - [AwsCredentialDto](docs/AwsCredentialDto.md) - - [AwsCredentialSpecDto](docs/AwsCredentialSpecDto.md) + - [AvailabilityRestriction](docs/AvailabilityRestriction.md) + - [AvailabilityRestrictionMetadata](docs/AvailabilityRestrictionMetadata.md) + - [AwsCodeCommitAuthentication](docs/AwsCodeCommitAuthentication.md) + - [AwsCodeCommitConnector](docs/AwsCodeCommitConnector.md) + - [AwsCodeCommitCredentials](docs/AwsCodeCommitCredentials.md) + - [AwsCodeCommitHttpsCredentials](docs/AwsCodeCommitHttpsCredentials.md) + - [AwsCodeCommitHttpsCredentialsSpec](docs/AwsCodeCommitHttpsCredentialsSpec.md) + - [AwsCodeCommitSecretKeyAccessKey](docs/AwsCodeCommitSecretKeyAccessKey.md) + - [AwsConnector](docs/AwsConnector.md) + - [AwsCredential](docs/AwsCredential.md) + - [AwsCredentialSpec](docs/AwsCredentialSpec.md) - [AwsCurAttributesDto](docs/AwsCurAttributesDto.md) - - [AwsKmsConfigDto](docs/AwsKmsConfigDto.md) - [AwsKmsConnectorCredentialDto](docs/AwsKmsConnectorCredentialDto.md) - [AwsKmsConnectorDto](docs/AwsKmsConnectorDto.md) - [AwsKmsCredentialSpecAssumeIamdto](docs/AwsKmsCredentialSpecAssumeIamdto.md) - [AwsKmsCredentialSpecAssumeStsdto](docs/AwsKmsCredentialSpecAssumeStsdto.md) - - [AwsKmsCredentialSpecConfig](docs/AwsKmsCredentialSpecConfig.md) - [AwsKmsCredentialSpecDto](docs/AwsKmsCredentialSpecDto.md) - [AwsKmsCredentialSpecManualConfigDto](docs/AwsKmsCredentialSpecManualConfigDto.md) - - [AwsKmsIamCredentialConfig](docs/AwsKmsIamCredentialConfig.md) - - [AwsKmsManualCredentialConfig](docs/AwsKmsManualCredentialConfig.md) - - [AwsKmsStsCredentialConfig](docs/AwsKmsStsCredentialConfig.md) - - [AwsManualConfigSpecDto](docs/AwsManualConfigSpecDto.md) + - [AwsManualConfigSpec](docs/AwsManualConfigSpec.md) - [AwsSecretManagerCredentialDto](docs/AwsSecretManagerCredentialDto.md) - [AwsSecretManagerCredentialSpecDto](docs/AwsSecretManagerCredentialSpecDto.md) - [AwsSecretManagerDto](docs/AwsSecretManagerDto.md) - [AwsSmCredentialSpecAssumeIamdto](docs/AwsSmCredentialSpecAssumeIamdto.md) - [AwsSmCredentialSpecAssumeStsdto](docs/AwsSmCredentialSpecAssumeStsdto.md) - [AwsSmCredentialSpecManualConfigDto](docs/AwsSmCredentialSpecManualConfigDto.md) - - [AzureKeyVaultConfigDto](docs/AzureKeyVaultConfigDto.md) - [AzureKeyVaultConnectorDto](docs/AzureKeyVaultConnectorDto.md) - - [BarrierInfoConfig](docs/BarrierInfoConfig.md) - - [BaseAwsKmsConfigDto](docs/BaseAwsKmsConfigDto.md) - - [BaseSshSpecDto](docs/BaseSshSpecDto.md) - [BillingExportSpecDto](docs/BillingExportSpecDto.md) - - [BitbucketApiAccessDto](docs/BitbucketApiAccessDto.md) - - [BitbucketApiAccessSpecDto](docs/BitbucketApiAccessSpecDto.md) - - [BitbucketAuthenticationDto](docs/BitbucketAuthenticationDto.md) - - [BitbucketCloudWebhookEvents](docs/BitbucketCloudWebhookEvents.md) - - [BitbucketCloudWebhookEventsOrBuilder](docs/BitbucketCloudWebhookEventsOrBuilder.md) - - [BitbucketConnectorDto](docs/BitbucketConnectorDto.md) - - [BitbucketCredentialsDto](docs/BitbucketCredentialsDto.md) - - [BitbucketHttpCredentialsDto](docs/BitbucketHttpCredentialsDto.md) - - [BitbucketHttpCredentialsSpecDto](docs/BitbucketHttpCredentialsSpecDto.md) - - [BitbucketServerWebhookEvents](docs/BitbucketServerWebhookEvents.md) - - [BitbucketServerWebhookEventsOrBuilder](docs/BitbucketServerWebhookEventsOrBuilder.md) - - [BitbucketSshCredentialsDto](docs/BitbucketSshCredentialsDto.md) - - [BitbucketUsernamePasswordDto](docs/BitbucketUsernamePasswordDto.md) - - [BitbucketUsernameTokenApiAccessDto](docs/BitbucketUsernameTokenApiAccessDto.md) - - [BuildIdAndInstanceCount](docs/BuildIdAndInstanceCount.md) - - [ByteString](docs/ByteString.md) + - [BitbucketApiAccess](docs/BitbucketApiAccess.md) + - [BitbucketAuthentication](docs/BitbucketAuthentication.md) + - [BitbucketConnector](docs/BitbucketConnector.md) + - [BitbucketCredentials](docs/BitbucketCredentials.md) + - [BitbucketHttpCredentials](docs/BitbucketHttpCredentials.md) + - [BitbucketHttpCredentialsSpec](docs/BitbucketHttpCredentialsSpec.md) + - [BitbucketSshCredentials](docs/BitbucketSshCredentials.md) + - [BitbucketUsernamePassword](docs/BitbucketUsernamePassword.md) + - [BitbucketUsernameTokenApiAccess](docs/BitbucketUsernameTokenApiAccess.md) - [CcmConnectorFilter](docs/CcmConnectorFilter.md) - - [CdLicenseSummaryDto](docs/CdLicenseSummaryDto.md) - - [CdModuleLicenseDto](docs/CdModuleLicenseDto.md) - - [CdPipelineModuleInfo](docs/CdPipelineModuleInfo.md) - - [CdStageModuleInfo](docs/CdStageModuleInfo.md) + - [CdLicenseSummary](docs/CdLicenseSummary.md) + - [CdModuleLicense](docs/CdModuleLicense.md) - [CeAwsConnectorDto](docs/CeAwsConnectorDto.md) - [CeAzureConnectorDto](docs/CeAzureConnectorDto.md) - [CeKubernetesClusterConfigDto](docs/CeKubernetesClusterConfigDto.md) - [CeLicenseInfo](docs/CeLicenseInfo.md) - - [CeLicenseSummaryDto](docs/CeLicenseSummaryDto.md) - - [CeModuleLicenseDto](docs/CeModuleLicenseDto.md) - - [CfLicenseSummaryDto](docs/CfLicenseSummaryDto.md) - - [CfModuleLicenseDto](docs/CfModuleLicenseDto.md) - - [CheckExpiryResultDto](docs/CheckExpiryResultDto.md) - - [CiLicenseSummaryDto](docs/CiLicenseSummaryDto.md) - - [CiModuleLicenseDto](docs/CiModuleLicenseDto.md) - - [ConnectedArgoGitOpsInfoDto](docs/ConnectedArgoGitOpsInfoDto.md) - - [ConnectivityCheckSummaryDto](docs/ConnectivityCheckSummaryDto.md) + - [CeLicenseSummary](docs/CeLicenseSummary.md) + - [CeModuleLicense](docs/CeModuleLicense.md) + - [CfLicenseSummary](docs/CfLicenseSummary.md) + - [CfModuleLicense](docs/CfModuleLicense.md) + - [CiLicenseSummary](docs/CiLicenseSummary.md) + - [CiModuleLicense](docs/CiModuleLicense.md) - [Connector](docs/Connector.md) - [ConnectorActivityDetails](docs/ConnectorActivityDetails.md) - [ConnectorCatalogueItem](docs/ConnectorCatalogueItem.md) - [ConnectorCatalogueRespone](docs/ConnectorCatalogueRespone.md) - - [ConnectorConfigDto](docs/ConnectorConfigDto.md) + - [ConnectorConfig](docs/ConnectorConfig.md) - [ConnectorConnectivityDetails](docs/ConnectorConnectivityDetails.md) - [ConnectorFilterProperties](docs/ConnectorFilterProperties.md) - - [ConnectorInfoDto](docs/ConnectorInfoDto.md) + - [ConnectorInfo](docs/ConnectorInfo.md) - [ConnectorResponse](docs/ConnectorResponse.md) - [ConnectorStatistics](docs/ConnectorStatistics.md) - [ConnectorStatusStats](docs/ConnectorStatusStats.md) - [ConnectorTypeStats](docs/ConnectorTypeStats.md) - [ConnectorValidationParams](docs/ConnectorValidationParams.md) - [ConnectorValidationResult](docs/ConnectorValidationResult.md) - - [CreateInviteDto](docs/CreateInviteDto.md) - - [CreatePrdto](docs/CreatePrdto.md) - - [CrossAccountAccessDto](docs/CrossAccountAccessDto.md) - - [CustomRestrictionDto](docs/CustomRestrictionDto.md) - - [CustomRestrictionEvaluationDto](docs/CustomRestrictionEvaluationDto.md) - - [CustomRestrictionMetadataDto](docs/CustomRestrictionMetadataDto.md) - - [CvLicenseSummaryDto](docs/CvLicenseSummaryDto.md) - - [CvModuleLicenseDto](docs/CvModuleLicenseDto.md) - - [DashboardExecutionStatusInfo](docs/DashboardExecutionStatusInfo.md) - - [DashboardWorkloadDeployment](docs/DashboardWorkloadDeployment.md) + - [CreateInvite](docs/CreateInvite.md) + - [CreatePr](docs/CreatePr.md) + - [CrossAccountAccess](docs/CrossAccountAccess.md) + - [CustomHealthConnectorDto](docs/CustomHealthConnectorDto.md) + - [CustomHealthKeyAndValue](docs/CustomHealthKeyAndValue.md) + - [CustomRestriction](docs/CustomRestriction.md) + - [CustomRestrictionMetadata](docs/CustomRestrictionMetadata.md) + - [CvLicenseSummary](docs/CvLicenseSummary.md) + - [CvModuleLicense](docs/CvModuleLicense.md) - [DatadogConnectorDto](docs/DatadogConnectorDto.md) - - [DecryptableEntity](docs/DecryptableEntity.md) - - [DecryptableEntityWithEncryptionConsumers](docs/DecryptableEntityWithEncryptionConsumers.md) - [DelegateConfiguration](docs/DelegateConfiguration.md) - [DelegateProfileDetailsNg](docs/DelegateProfileDetailsNg.md) - [DelegateProfileFilterPropertiesDto](docs/DelegateProfileFilterPropertiesDto.md) - - [DelegateResponseData](docs/DelegateResponseData.md) - - [Deployment](docs/Deployment.md) - - [DeploymentChangeRates](docs/DeploymentChangeRates.md) - - [DeploymentCount](docs/DeploymentCount.md) - - [DeploymentDateAndCount](docs/DeploymentDateAndCount.md) - - [DeploymentInfo](docs/DeploymentInfo.md) - - [DeploymentStatsSummary](docs/DeploymentStatsSummary.md) - - [DeploymentsInfo](docs/DeploymentsInfo.md) - - [Descriptor](docs/Descriptor.md) - - [DescriptorProto](docs/DescriptorProto.md) - - [DescriptorProtoOrBuilder](docs/DescriptorProtoOrBuilder.md) - - [DockerAuthCredentialsDto](docs/DockerAuthCredentialsDto.md) - - [DockerAuthenticationDto](docs/DockerAuthenticationDto.md) - - [DockerBuildDetailsDto](docs/DockerBuildDetailsDto.md) - - [DockerConnectorDto](docs/DockerConnectorDto.md) - - [DockerRequestDto](docs/DockerRequestDto.md) - - [DockerResponseDto](docs/DockerResponseDto.md) - - [DockerUserNamePasswordDto](docs/DockerUserNamePasswordDto.md) - - [DurationRestrictionDto](docs/DurationRestrictionDto.md) - - [DurationRestrictionMetadataDto](docs/DurationRestrictionMetadataDto.md) + - [DockerAuthCredentials](docs/DockerAuthCredentials.md) + - [DockerAuthentication](docs/DockerAuthentication.md) + - [DockerConnector](docs/DockerConnector.md) + - [DockerUserNamePassword](docs/DockerUserNamePassword.md) + - [DurationRestriction](docs/DurationRestriction.md) + - [DurationRestrictionMetadata](docs/DurationRestrictionMetadata.md) - [DynatraceConnectorDto](docs/DynatraceConnectorDto.md) - - [EcrBuildDetailsDto](docs/EcrBuildDetailsDto.md) - - [EcrListImagesDto](docs/EcrListImagesDto.md) - - [EcrRequestDto](docs/EcrRequestDto.md) - - [EcrResponseDto](docs/EcrResponseDto.md) - - [EditionActionDto](docs/EditionActionDto.md) - - [EmailConfigDto](docs/EmailConfigDto.md) + - [EditionAction](docs/EditionAction.md) - [EmbeddedUser](docs/EmbeddedUser.md) - [EmbeddedUserDetails](docs/EmbeddedUserDetails.md) - - [EncryptedDataDetail](docs/EncryptedDataDetail.md) - - [EncryptedDataParams](docs/EncryptedDataParams.md) - - [EncryptedRecordData](docs/EncryptedRecordData.md) - - [EncryptionConfig](docs/EncryptionConfig.md) - - [EntityDetail](docs/EntityDetail.md) - [EntityGitDetails](docs/EntityGitDetails.md) - [EntityReference](docs/EntityReference.md) - - [EntityReferencesDto](docs/EntityReferencesDto.md) - - [EntityReferredByPipelineSetupUsageDetail](docs/EntityReferredByPipelineSetupUsageDetail.md) - - [EntitySetupUsageBatchDto](docs/EntitySetupUsageBatchDto.md) - - [EntitySetupUsageDto](docs/EntitySetupUsageDto.md) - [EntityValidityDetails](docs/EntityValidityDetails.md) - - [EnumDescriptor](docs/EnumDescriptor.md) - - [EnumDescriptorProto](docs/EnumDescriptorProto.md) - - [EnumDescriptorProtoOrBuilder](docs/EnumDescriptorProtoOrBuilder.md) - - [EnumOptions](docs/EnumOptions.md) - - [EnumOptionsOrBuilder](docs/EnumOptionsOrBuilder.md) - - [EnumReservedRange](docs/EnumReservedRange.md) - - [EnumReservedRangeOrBuilder](docs/EnumReservedRangeOrBuilder.md) - - [EnumValueDescriptor](docs/EnumValueDescriptor.md) - - [EnumValueDescriptorProto](docs/EnumValueDescriptorProto.md) - - [EnumValueDescriptorProtoOrBuilder](docs/EnumValueDescriptorProtoOrBuilder.md) - - [EnumValueOptions](docs/EnumValueOptions.md) - - [EnumValueOptionsOrBuilder](docs/EnumValueOptionsOrBuilder.md) - - [EnvBuildIdAndInstanceCountInfo](docs/EnvBuildIdAndInstanceCountInfo.md) - - [EnvBuildIdAndInstanceCountInfoList](docs/EnvBuildIdAndInstanceCountInfoList.md) - - [EnvCount](docs/EnvCount.md) - [EnvFilter](docs/EnvFilter.md) - - [EnvIdCountPair](docs/EnvIdCountPair.md) - - [EnvironmentRequestDto](docs/EnvironmentRequestDto.md) + - [EnvironmentRequest](docs/EnvironmentRequest.md) - [EnvironmentResponse](docs/EnvironmentResponse.md) - - [EnvironmentResponseDto](docs/EnvironmentResponseDto.md) - [ErrorDetail](docs/ErrorDetail.md) - [ErrorMetadataDto](docs/ErrorMetadataDto.md) - - [ExecutionDeployment](docs/ExecutionDeployment.md) - - [ExecutionDeploymentInfo](docs/ExecutionDeploymentInfo.md) - - [ExecutionStatusInfo](docs/ExecutionStatusInfo.md) - - [ExtensionRange](docs/ExtensionRange.md) - - [ExtensionRangeOptions](docs/ExtensionRangeOptions.md) - - [ExtensionRangeOptionsOrBuilder](docs/ExtensionRangeOptionsOrBuilder.md) - - [ExtensionRangeOrBuilder](docs/ExtensionRangeOrBuilder.md) - [Failure](docs/Failure.md) + - [FeatureRestrictionDetailListRequest](docs/FeatureRestrictionDetailListRequest.md) - [FeatureRestrictionDetailRequest](docs/FeatureRestrictionDetailRequest.md) - [FeatureRestrictionDetails](docs/FeatureRestrictionDetails.md) - [FeatureRestrictionMetadata](docs/FeatureRestrictionMetadata.md) - - [FeatureRestrictionUsageDto](docs/FeatureRestrictionUsageDto.md) - [FeedbackForm](docs/FeedbackForm.md) - - [FieldDescriptor](docs/FieldDescriptor.md) - - [FieldDescriptorProto](docs/FieldDescriptorProto.md) - - [FieldDescriptorProtoOrBuilder](docs/FieldDescriptorProtoOrBuilder.md) - - [FieldOptions](docs/FieldOptions.md) - - [FieldOptionsOrBuilder](docs/FieldOptionsOrBuilder.md) - [FieldValues](docs/FieldValues.md) - - [FileDescriptor](docs/FileDescriptor.md) - - [FileDescriptorProto](docs/FileDescriptorProto.md) - - [FileOptions](docs/FileOptions.md) - - [FileOptionsOrBuilder](docs/FileOptionsOrBuilder.md) - - [FilesIdentifierBody](docs/FilesIdentifierBody.md) - [Filter](docs/Filter.md) - - [FilterDto](docs/FilterDto.md) - - [FilterPropertiesDto](docs/FilterPropertiesDto.md) - - [FlowControlConfig](docs/FlowControlConfig.md) + - [FilterProperties](docs/FilterProperties.md) - [FormDataContentDisposition](docs/FormDataContentDisposition.md) + - [FullSyncRequest](docs/FullSyncRequest.md) - [GatewayAccountRequestDto](docs/GatewayAccountRequestDto.md) - [GcpBillingExportSpecDto](docs/GcpBillingExportSpecDto.md) - [GcpCloudCostConnectorDto](docs/GcpCloudCostConnectorDto.md) - - [GcpConnectorCredentialDto](docs/GcpConnectorCredentialDto.md) - - [GcpConnectorDto](docs/GcpConnectorDto.md) - - [GcpCredentialSpecDto](docs/GcpCredentialSpecDto.md) - - [GcpKmsConfigDto](docs/GcpKmsConfigDto.md) + - [GcpConnector](docs/GcpConnector.md) + - [GcpConnectorCredential](docs/GcpConnectorCredential.md) + - [GcpCredentialSpec](docs/GcpCredentialSpec.md) - [GcpKmsConnectorDto](docs/GcpKmsConnectorDto.md) - - [GcpManualDetailsDto](docs/GcpManualDetailsDto.md) + - [GcpManualDetails](docs/GcpManualDetails.md) - [GcpResponse](docs/GcpResponse.md) - - [GcrBuildDetailsDto](docs/GcrBuildDetailsDto.md) - - [GcrRequestDto](docs/GcrRequestDto.md) - - [GcrResponseDto](docs/GcrResponseDto.md) - [GenericEntityFilter](docs/GenericEntityFilter.md) - - [GitAuthenticationDto](docs/GitAuthenticationDto.md) - - [GitBranchDto](docs/GitBranchDto.md) - - [GitBranchListDto](docs/GitBranchListDto.md) - - [GitConfigDto](docs/GitConfigDto.md) - - [GitEnabledDto](docs/GitEnabledDto.md) - - [GitEntityBranchSummaryFilterDto](docs/GitEntityBranchSummaryFilterDto.md) - - [GitEntitySummaryFilterDto](docs/GitEntitySummaryFilterDto.md) + - [GitAuthentication](docs/GitAuthentication.md) + - [GitBranch](docs/GitBranch.md) + - [GitBranchList](docs/GitBranchList.md) + - [GitConfig](docs/GitConfig.md) + - [GitEnabled](docs/GitEnabled.md) + - [GitEntityBranchSummaryFilter](docs/GitEntityBranchSummaryFilter.md) + - [GitEntitySummaryFilter](docs/GitEntitySummaryFilter.md) - [GitFileContent](docs/GitFileContent.md) - [GitHttpAuthenticationDto](docs/GitHttpAuthenticationDto.md) - - [GitInfo](docs/GitInfo.md) - - [GitOpsInfoDto](docs/GitOpsInfoDto.md) - - [GitOpsProviderDto](docs/GitOpsProviderDto.md) - - [GitOpsProviderResponseDto](docs/GitOpsProviderResponseDto.md) - [GitPrCreateRequest](docs/GitPrCreateRequest.md) - - [GitSshAuthenticationDto](docs/GitSshAuthenticationDto.md) - - [GitSyncConfigDto](docs/GitSyncConfigDto.md) - - [GitSyncEntityDto](docs/GitSyncEntityDto.md) - - [GitSyncEntityListDto](docs/GitSyncEntityListDto.md) - - [GitSyncErrorAggregateByCommitDto](docs/GitSyncErrorAggregateByCommitDto.md) - - [GitSyncErrorCountDto](docs/GitSyncErrorCountDto.md) - - [GitSyncErrorDetailsDto](docs/GitSyncErrorDetailsDto.md) - - [GitSyncErrorDto](docs/GitSyncErrorDto.md) - - [GitSyncFolderConfigDto](docs/GitSyncFolderConfigDto.md) - - [GitSyncRepoFilesDto](docs/GitSyncRepoFilesDto.md) - - [GitSyncRepoFilesListDto](docs/GitSyncRepoFilesListDto.md) - - [GitSyncSettingsDto](docs/GitSyncSettingsDto.md) - - [GithubApiAccessDto](docs/GithubApiAccessDto.md) - - [GithubApiAccessSpecDto](docs/GithubApiAccessSpecDto.md) - - [GithubAppSpecDto](docs/GithubAppSpecDto.md) - - [GithubAuthenticationDto](docs/GithubAuthenticationDto.md) - - [GithubConnectorDto](docs/GithubConnectorDto.md) - - [GithubCredentialsDto](docs/GithubCredentialsDto.md) - - [GithubHttpCredentialsDto](docs/GithubHttpCredentialsDto.md) - - [GithubHttpCredentialsSpecDto](docs/GithubHttpCredentialsSpecDto.md) - - [GithubSshCredentialsDto](docs/GithubSshCredentialsDto.md) - - [GithubTokenSpecDto](docs/GithubTokenSpecDto.md) - - [GithubUsernamePasswordDto](docs/GithubUsernamePasswordDto.md) - - [GithubUsernameTokenDto](docs/GithubUsernameTokenDto.md) - - [GithubWebhookEvents](docs/GithubWebhookEvents.md) - - [GithubWebhookEventsOrBuilder](docs/GithubWebhookEventsOrBuilder.md) - - [GitlabApiAccessDto](docs/GitlabApiAccessDto.md) - - [GitlabApiAccessSpecDto](docs/GitlabApiAccessSpecDto.md) - - [GitlabAuthenticationDto](docs/GitlabAuthenticationDto.md) - - [GitlabConnectorDto](docs/GitlabConnectorDto.md) - - [GitlabCredentialsDto](docs/GitlabCredentialsDto.md) - - [GitlabHttpCredentialsDto](docs/GitlabHttpCredentialsDto.md) - - [GitlabHttpCredentialsSpecDto](docs/GitlabHttpCredentialsSpecDto.md) - - [GitlabKerberosDto](docs/GitlabKerberosDto.md) - - [GitlabSshCredentialsDto](docs/GitlabSshCredentialsDto.md) - - [GitlabTokenSpecDto](docs/GitlabTokenSpecDto.md) - - [GitlabUsernamePasswordDto](docs/GitlabUsernamePasswordDto.md) - - [GitlabUsernameTokenDto](docs/GitlabUsernameTokenDto.md) - - [GitlabWebhookEvents](docs/GitlabWebhookEvents.md) - - [GitlabWebhookEventsOrBuilder](docs/GitlabWebhookEventsOrBuilder.md) - - [HarnessServiceInfoNg](docs/HarnessServiceInfoNg.md) - - [HealthDeploymentDashboard](docs/HealthDeploymentDashboard.md) - - [HealthDeploymentInfo](docs/HealthDeploymentInfo.md) - - [HttpHelmAuthCredentialsDto](docs/HttpHelmAuthCredentialsDto.md) - - [HttpHelmAuthenticationDto](docs/HttpHelmAuthenticationDto.md) - - [HttpHelmConnectorDto](docs/HttpHelmConnectorDto.md) - - [HttpHelmUsernamePasswordDto](docs/HttpHelmUsernamePasswordDto.md) - - [InfraExecutionSummary](docs/InfraExecutionSummary.md) - - [InfrastructureDetails](docs/InfrastructureDetails.md) - - [InputSetValidator](docs/InputSetValidator.md) - - [InstanceCountDetailsByEnvTypeAndServiceId](docs/InstanceCountDetailsByEnvTypeAndServiceId.md) - - [InstanceCountDetailsByEnvTypeBase](docs/InstanceCountDetailsByEnvTypeBase.md) - - [InstanceDetailsByBuildId](docs/InstanceDetailsByBuildId.md) - - [InstanceDetailsDto](docs/InstanceDetailsDto.md) - - [InstancesByBuildIdList](docs/InstancesByBuildIdList.md) + - [GitSshAuthentication](docs/GitSshAuthentication.md) + - [GitSyncConfig](docs/GitSyncConfig.md) + - [GitSyncEntity](docs/GitSyncEntity.md) + - [GitSyncEntityList](docs/GitSyncEntityList.md) + - [GitSyncError](docs/GitSyncError.md) + - [GitSyncErrorAggregateByCommit](docs/GitSyncErrorAggregateByCommit.md) + - [GitSyncErrorCount](docs/GitSyncErrorCount.md) + - [GitSyncErrorDetails](docs/GitSyncErrorDetails.md) + - [GitSyncFolderConfig](docs/GitSyncFolderConfig.md) + - [GitSyncRepoFiles](docs/GitSyncRepoFiles.md) + - [GitSyncRepoFilesList](docs/GitSyncRepoFilesList.md) + - [GitSyncSettings](docs/GitSyncSettings.md) + - [GithubApiAccess](docs/GithubApiAccess.md) + - [GithubApiAccessSpec](docs/GithubApiAccessSpec.md) + - [GithubAppSpec](docs/GithubAppSpec.md) + - [GithubAuthentication](docs/GithubAuthentication.md) + - [GithubConnector](docs/GithubConnector.md) + - [GithubCredentials](docs/GithubCredentials.md) + - [GithubHttpCredentials](docs/GithubHttpCredentials.md) + - [GithubHttpCredentialsSpec](docs/GithubHttpCredentialsSpec.md) + - [GithubSshCredentials](docs/GithubSshCredentials.md) + - [GithubTokenSpec](docs/GithubTokenSpec.md) + - [GithubUsernamePassword](docs/GithubUsernamePassword.md) + - [GithubUsernameToken](docs/GithubUsernameToken.md) + - [GitlabApiAccess](docs/GitlabApiAccess.md) + - [GitlabApiAccessSpec](docs/GitlabApiAccessSpec.md) + - [GitlabAuthentication](docs/GitlabAuthentication.md) + - [GitlabConnector](docs/GitlabConnector.md) + - [GitlabCredentials](docs/GitlabCredentials.md) + - [GitlabHttpCredentials](docs/GitlabHttpCredentials.md) + - [GitlabHttpCredentialsSpec](docs/GitlabHttpCredentialsSpec.md) + - [GitlabKerberos](docs/GitlabKerberos.md) + - [GitlabSshCredentials](docs/GitlabSshCredentials.md) + - [GitlabTokenSpec](docs/GitlabTokenSpec.md) + - [GitlabUsernamePassword](docs/GitlabUsernamePassword.md) + - [GitlabUsernameToken](docs/GitlabUsernameToken.md) + - [HttpHelmAuthCredentials](docs/HttpHelmAuthCredentials.md) + - [HttpHelmAuthentication](docs/HttpHelmAuthentication.md) + - [HttpHelmConnector](docs/HttpHelmConnector.md) + - [HttpHelmUsernamePassword](docs/HttpHelmUsernamePassword.md) + - [Invite](docs/Invite.md) - [InviteAcceptResponse](docs/InviteAcceptResponse.md) - - [InviteDto](docs/InviteDto.md) - - [JiraConnectorDto](docs/JiraConnectorDto.md) - - [JiraFieldAllowedValueNg](docs/JiraFieldAllowedValueNg.md) - - [JiraFieldNg](docs/JiraFieldNg.md) - - [JiraFieldSchemaNg](docs/JiraFieldSchemaNg.md) - - [JiraIssueCreateMetadataNg](docs/JiraIssueCreateMetadataNg.md) - - [JiraIssueTypeNg](docs/JiraIssueTypeNg.md) - - [JiraIssueUpdateMetadataNg](docs/JiraIssueUpdateMetadataNg.md) - - [JiraProjectBasicNg](docs/JiraProjectBasicNg.md) - - [JiraProjectNg](docs/JiraProjectNg.md) - - [JiraStatusCategoryNg](docs/JiraStatusCategoryNg.md) - - [JiraStatusNg](docs/JiraStatusNg.md) - - [JsonNode](docs/JsonNode.md) - - [K8sInfrastructureDetails](docs/K8sInfrastructureDetails.md) - - [KerberosConfigDto](docs/KerberosConfigDto.md) - - [KubernetesAuthCredentialDto](docs/KubernetesAuthCredentialDto.md) - - [KubernetesAuthDto](docs/KubernetesAuthDto.md) - - [KubernetesClientKeyCertDto](docs/KubernetesClientKeyCertDto.md) - - [KubernetesClusterConfigDto](docs/KubernetesClusterConfigDto.md) - - [KubernetesClusterDetailsDto](docs/KubernetesClusterDetailsDto.md) - - [KubernetesCredentialDto](docs/KubernetesCredentialDto.md) - - [KubernetesCredentialSpecDto](docs/KubernetesCredentialSpecDto.md) - - [KubernetesOpenIdConnectDto](docs/KubernetesOpenIdConnectDto.md) - - [KubernetesServiceAccountDto](docs/KubernetesServiceAccountDto.md) - - [KubernetesUserNamePasswordDto](docs/KubernetesUserNamePasswordDto.md) - - [LastWorkloadInfo](docs/LastWorkloadInfo.md) + - [JiraConnector](docs/JiraConnector.md) + - [KubernetesAuth](docs/KubernetesAuth.md) + - [KubernetesAuthCredential](docs/KubernetesAuthCredential.md) + - [KubernetesClientKeyCert](docs/KubernetesClientKeyCert.md) + - [KubernetesClusterConfig](docs/KubernetesClusterConfig.md) + - [KubernetesClusterDetails](docs/KubernetesClusterDetails.md) + - [KubernetesCredential](docs/KubernetesCredential.md) + - [KubernetesCredentialSpec](docs/KubernetesCredentialSpec.md) + - [KubernetesOpenIdConnect](docs/KubernetesOpenIdConnect.md) + - [KubernetesServiceAccount](docs/KubernetesServiceAccount.md) + - [KubernetesUserNamePassword](docs/KubernetesUserNamePassword.md) - [LicenseInfo](docs/LicenseInfo.md) - [LicensesWithSummary](docs/LicensesWithSummary.md) - - [LocalConfigDto](docs/LocalConfigDto.md) - [LocalConnectorDto](docs/LocalConnectorDto.md) - - [Location](docs/Location.md) - - [LocationOrBuilder](docs/LocationOrBuilder.md) - [LoginSettings](docs/LoginSettings.md) - [LoginTypeResponse](docs/LoginTypeResponse.md) - - [ManagedArgoGitOpsInfoDto](docs/ManagedArgoGitOpsInfoDto.md) - - [Message](docs/Message.md) - - [MessageLite](docs/MessageLite.md) - - [MessageOptions](docs/MessageOptions.md) - - [MessageOptionsOrBuilder](docs/MessageOptionsOrBuilder.md) - - [MethodDescriptor](docs/MethodDescriptor.md) - - [MethodDescriptorProto](docs/MethodDescriptorProto.md) - - [MethodDescriptorProtoOrBuilder](docs/MethodDescriptorProtoOrBuilder.md) - - [MethodOptions](docs/MethodOptions.md) - - [MethodOptionsOrBuilder](docs/MethodOptionsOrBuilder.md) - - [MicrosoftTeamsConfigDto](docs/MicrosoftTeamsConfigDto.md) - [ModelError](docs/ModelError.md) - [ModuleLicense](docs/ModuleLicense.md) - - [NamePart](docs/NamePart.md) - - [NamePartOrBuilder](docs/NamePartOrBuilder.md) - - [NativeEvents](docs/NativeEvents.md) - - [NativeEventsOrBuilder](docs/NativeEventsOrBuilder.md) - [NewRelicConnectorDto](docs/NewRelicConnectorDto.md) - - [NexusAuthCredentialsDto](docs/NexusAuthCredentialsDto.md) - - [NexusAuthenticationDto](docs/NexusAuthenticationDto.md) - - [NexusConnectorDto](docs/NexusConnectorDto.md) - - [NexusUsernamePasswordAuthDto](docs/NexusUsernamePasswordAuthDto.md) - - [NgAccess](docs/NgAccess.md) - - [NgAccessWithEncryptionConsumer](docs/NgAccessWithEncryptionConsumer.md) - - [NgActivityDto](docs/NgActivityDto.md) - - [NgActivitySummaryDto](docs/NgActivitySummaryDto.md) + - [NexusAuthCredentials](docs/NexusAuthCredentials.md) + - [NexusAuthentication](docs/NexusAuthentication.md) + - [NexusConnector](docs/NexusConnector.md) + - [NexusUsernamePasswordAuth](docs/NexusUsernamePasswordAuth.md) - [NgAuthSettings](docs/NgAuthSettings.md) - - [NgProperties](docs/NgProperties.md) - - [NgTag](docs/NgTag.md) - - [NgVariable](docs/NgVariable.md) - - [NotificationChannelWrapper](docs/NotificationChannelWrapper.md) - - [NotificationRules](docs/NotificationRules.md) - - [NotificationSettingConfig](docs/NotificationSettingConfig.md) - - [NotificationSettingConfigDto](docs/NotificationSettingConfigDto.md) - [NotificationSettings](docs/NotificationSettings.md) - - [NumberNgVariable](docs/NumberNgVariable.md) - [OAuthSettings](docs/OAuthSettings.md) - - [OAuthSignupDto](docs/OAuthSignupDto.md) - - [OneofDescriptor](docs/OneofDescriptor.md) - - [OneofDescriptorProto](docs/OneofDescriptorProto.md) - - [OneofDescriptorProtoOrBuilder](docs/OneofDescriptorProtoOrBuilder.md) - - [OneofOptions](docs/OneofOptions.md) - - [OneofOptionsOrBuilder](docs/OneofOptionsOrBuilder.md) - - [OrgProjectIdentifier](docs/OrgProjectIdentifier.md) - [Organization](docs/Organization.md) - - [OrganizationAggregateDto](docs/OrganizationAggregateDto.md) - [OrganizationRequest](docs/OrganizationRequest.md) - [OrganizationResponse](docs/OrganizationResponse.md) - - [PageEntitySetupUsageDto](docs/PageEntitySetupUsageDto.md) - - [PageNgActivityDto](docs/PageNgActivityDto.md) - - [PageNgActivitySummaryDto](docs/PageNgActivitySummaryDto.md) - - [PageResponseApiKeyAggregateDto](docs/PageResponseApiKeyAggregateDto.md) - [PageResponseConnectorResponse](docs/PageResponseConnectorResponse.md) - [PageResponseEnvironmentResponse](docs/PageResponseEnvironmentResponse.md) - - [PageResponseEnvironmentResponseDto](docs/PageResponseEnvironmentResponseDto.md) - - [PageResponseFilterDto](docs/PageResponseFilterDto.md) - - [PageResponseGitBranchDto](docs/PageResponseGitBranchDto.md) - - [PageResponseGitOpsProviderResponseDto](docs/PageResponseGitOpsProviderResponseDto.md) - - [PageResponseGitSyncEntityListDto](docs/PageResponseGitSyncEntityListDto.md) - - [PageResponseGitSyncErrorAggregateByCommitDto](docs/PageResponseGitSyncErrorAggregateByCommitDto.md) - - [PageResponseGitSyncErrorDto](docs/PageResponseGitSyncErrorDto.md) - - [PageResponseInviteDto](docs/PageResponseInviteDto.md) - - [PageResponseOrganizationAggregateDto](docs/PageResponseOrganizationAggregateDto.md) + - [PageResponseFilter](docs/PageResponseFilter.md) + - [PageResponseGitBranch](docs/PageResponseGitBranch.md) + - [PageResponseGitSyncEntityList](docs/PageResponseGitSyncEntityList.md) + - [PageResponseGitSyncError](docs/PageResponseGitSyncError.md) + - [PageResponseGitSyncErrorAggregateByCommit](docs/PageResponseGitSyncErrorAggregateByCommit.md) + - [PageResponseInvite](docs/PageResponseInvite.md) - [PageResponseOrganizationResponse](docs/PageResponseOrganizationResponse.md) - - [PageResponseProject](docs/PageResponseProject.md) - - [PageResponseProjectAggregateDto](docs/PageResponseProjectAggregateDto.md) - [PageResponseProjectResponse](docs/PageResponseProjectResponse.md) - - [PageResponseRoleAssignmentResponse](docs/PageResponseRoleAssignmentResponse.md) - - [PageResponseSecretResponseWrapper](docs/PageResponseSecretResponseWrapper.md) - - [PageResponseServiceAccountAggregateDto](docs/PageResponseServiceAccountAggregateDto.md) - [PageResponseServiceResponse](docs/PageResponseServiceResponse.md) - - [PageResponseServiceResponseDto](docs/PageResponseServiceResponseDto.md) - - [PageResponseTokenAggregateDto](docs/PageResponseTokenAggregateDto.md) - - [PageResponseUserAggregateDto](docs/PageResponseUserAggregateDto.md) - - [PageResponseUserGroupAggregateDto](docs/PageResponseUserGroupAggregateDto.md) - - [PageResponseUserGroupDto](docs/PageResponseUserGroupDto.md) - - [PageResponseUserMetadataDto](docs/PageResponseUserMetadataDto.md) - - [Pageable](docs/Pageable.md) - - [PagerDutyConfigDto](docs/PagerDutyConfigDto.md) - [PagerDutyConnectorDto](docs/PagerDutyConnectorDto.md) - - [ParameterFieldDouble](docs/ParameterFieldDouble.md) - - [ParameterFieldNotificationChannelWrapper](docs/ParameterFieldNotificationChannelWrapper.md) - - [ParameterFieldObject](docs/ParameterFieldObject.md) - - [ParameterFieldSecretRefData](docs/ParameterFieldSecretRefData.md) - - [ParameterFieldString](docs/ParameterFieldString.md) - - [ParameterFieldTimeout](docs/ParameterFieldTimeout.md) - - [Parser](docs/Parser.md) - - [ParserBitbucketCloudWebhookEvents](docs/ParserBitbucketCloudWebhookEvents.md) - - [ParserBitbucketServerWebhookEvents](docs/ParserBitbucketServerWebhookEvents.md) - - [ParserDescriptorProto](docs/ParserDescriptorProto.md) - - [ParserEnumDescriptorProto](docs/ParserEnumDescriptorProto.md) - - [ParserEnumOptions](docs/ParserEnumOptions.md) - - [ParserEnumReservedRange](docs/ParserEnumReservedRange.md) - - [ParserEnumValueDescriptorProto](docs/ParserEnumValueDescriptorProto.md) - - [ParserEnumValueOptions](docs/ParserEnumValueOptions.md) - - [ParserExtensionRange](docs/ParserExtensionRange.md) - - [ParserExtensionRangeOptions](docs/ParserExtensionRangeOptions.md) - - [ParserFieldDescriptorProto](docs/ParserFieldDescriptorProto.md) - - [ParserFieldOptions](docs/ParserFieldOptions.md) - - [ParserFileDescriptorProto](docs/ParserFileDescriptorProto.md) - - [ParserFileOptions](docs/ParserFileOptions.md) - - [ParserGithubWebhookEvents](docs/ParserGithubWebhookEvents.md) - - [ParserGitlabWebhookEvents](docs/ParserGitlabWebhookEvents.md) - - [ParserLocation](docs/ParserLocation.md) - - [ParserMessage](docs/ParserMessage.md) - - [ParserMessageLite](docs/ParserMessageLite.md) - - [ParserMessageOptions](docs/ParserMessageOptions.md) - - [ParserMethodDescriptorProto](docs/ParserMethodDescriptorProto.md) - - [ParserMethodOptions](docs/ParserMethodOptions.md) - - [ParserNamePart](docs/ParserNamePart.md) - - [ParserNativeEvents](docs/ParserNativeEvents.md) - - [ParserOneofDescriptorProto](docs/ParserOneofDescriptorProto.md) - - [ParserOneofOptions](docs/ParserOneofOptions.md) - - [ParserReservedRange](docs/ParserReservedRange.md) - - [ParserServiceDescriptorProto](docs/ParserServiceDescriptorProto.md) - - [ParserServiceOptions](docs/ParserServiceOptions.md) - - [ParserSourceCodeInfo](docs/ParserSourceCodeInfo.md) - - [ParserUninterpretedOption](docs/ParserUninterpretedOption.md) - - [ParserWebhookResponse](docs/ParserWebhookResponse.md) - - [PartialSchemaDto](docs/PartialSchemaDto.md) - - [PasswordChangeDto](docs/PasswordChangeDto.md) - [PasswordExpirationPolicy](docs/PasswordExpirationPolicy.md) - [PasswordStrengthPolicy](docs/PasswordStrengthPolicy.md) - - [PipelineConfig](docs/PipelineConfig.md) - - [PipelineEvent](docs/PipelineEvent.md) - - [PipelineExecutionDashboardInfo](docs/PipelineExecutionDashboardInfo.md) - - [PipelineInfoConfig](docs/PipelineInfoConfig.md) - - [PipelinesExecutionDashboardInfo](docs/PipelinesExecutionDashboardInfo.md) - - [PmsEmailChannel](docs/PmsEmailChannel.md) - - [PmsMsTeamChannel](docs/PmsMsTeamChannel.md) - - [PmsNotificationChannel](docs/PmsNotificationChannel.md) - - [PmsPagerDutyChannel](docs/PmsPagerDutyChannel.md) - - [PmsSlackChannel](docs/PmsSlackChannel.md) - - [PollingResponseDto](docs/PollingResponseDto.md) - - [Principal](docs/Principal.md) - [Project](docs/Project.md) - - [ProjectAggregateDto](docs/ProjectAggregateDto.md) - - [ProjectDashBoardInfo](docs/ProjectDashBoardInfo.md) - [ProjectRequest](docs/ProjectRequest.md) - [ProjectResponse](docs/ProjectResponse.md) - - [ProjectsDashboardInfo](docs/ProjectsDashboardInfo.md) - [PrometheusConnectorDto](docs/PrometheusConnectorDto.md) - - [RateLimitRestrictionDto](docs/RateLimitRestrictionDto.md) - - [RateLimitRestrictionMetadataDto](docs/RateLimitRestrictionMetadataDto.md) - - [ReservedRange](docs/ReservedRange.md) - - [ReservedRangeOrBuilder](docs/ReservedRangeOrBuilder.md) - - [ResourceGroup](docs/ResourceGroup.md) + - [RateLimitProtection](docs/RateLimitProtection.md) + - [RateLimitRestriction](docs/RateLimitRestriction.md) + - [RateLimitRestrictionMetadata](docs/RateLimitRestrictionMetadata.md) - [ResponseDtoAccount](docs/ResponseDtoAccount.md) - [ResponseDtoAccountLicense](docs/ResponseDtoAccountLicense.md) - - [ResponseDtoAccountResourcesDto](docs/ResponseDtoAccountResourcesDto.md) - - [ResponseDtoActiveProjectsCountDto](docs/ResponseDtoActiveProjectsCountDto.md) - - [ResponseDtoActiveServiceInstanceSummary](docs/ResponseDtoActiveServiceInstanceSummary.md) - - [ResponseDtoAddUsersResponse](docs/ResponseDtoAddUsersResponse.md) - - [ResponseDtoApiKeyAggregateDto](docs/ResponseDtoApiKeyAggregateDto.md) - - [ResponseDtoApiKeyDto](docs/ResponseDtoApiKeyDto.md) - [ResponseDtoBoolean](docs/ResponseDtoBoolean.md) - - [ResponseDtoCheckExpiryResultDto](docs/ResponseDtoCheckExpiryResultDto.md) - - [ResponseDtoConnectivityCheckSummaryDto](docs/ResponseDtoConnectivityCheckSummaryDto.md) - [ResponseDtoConnectorCatalogueRespone](docs/ResponseDtoConnectorCatalogueRespone.md) - [ResponseDtoConnectorResponse](docs/ResponseDtoConnectorResponse.md) - [ResponseDtoConnectorStatistics](docs/ResponseDtoConnectorStatistics.md) - [ResponseDtoConnectorValidationParams](docs/ResponseDtoConnectorValidationParams.md) - [ResponseDtoConnectorValidationResult](docs/ResponseDtoConnectorValidationResult.md) - - [ResponseDtoCreatePrdto](docs/ResponseDtoCreatePrdto.md) - - [ResponseDtoDashboardExecutionStatusInfo](docs/ResponseDtoDashboardExecutionStatusInfo.md) - - [ResponseDtoDashboardWorkloadDeployment](docs/ResponseDtoDashboardWorkloadDeployment.md) - - [ResponseDtoDecryptableEntity](docs/ResponseDtoDecryptableEntity.md) - - [ResponseDtoDeploymentStatsSummary](docs/ResponseDtoDeploymentStatsSummary.md) - - [ResponseDtoDeploymentsInfo](docs/ResponseDtoDeploymentsInfo.md) - - [ResponseDtoDockerBuildDetailsDto](docs/ResponseDtoDockerBuildDetailsDto.md) - - [ResponseDtoDockerResponseDto](docs/ResponseDtoDockerResponseDto.md) - - [ResponseDtoEcrBuildDetailsDto](docs/ResponseDtoEcrBuildDetailsDto.md) - - [ResponseDtoEcrListImagesDto](docs/ResponseDtoEcrListImagesDto.md) - - [ResponseDtoEcrResponseDto](docs/ResponseDtoEcrResponseDto.md) - - [ResponseDtoEntityReferencesDto](docs/ResponseDtoEntityReferencesDto.md) - - [ResponseDtoEntitySetupUsageDto](docs/ResponseDtoEntitySetupUsageDto.md) - - [ResponseDtoEnvBuildIdAndInstanceCountInfoList](docs/ResponseDtoEnvBuildIdAndInstanceCountInfoList.md) - - [ResponseDtoEnvCount](docs/ResponseDtoEnvCount.md) + - [ResponseDtoCreatePr](docs/ResponseDtoCreatePr.md) - [ResponseDtoEnvironmentResponse](docs/ResponseDtoEnvironmentResponse.md) - - [ResponseDtoEnvironmentResponseDto](docs/ResponseDtoEnvironmentResponseDto.md) - - [ResponseDtoExecutionDeploymentInfo](docs/ResponseDtoExecutionDeploymentInfo.md) - [ResponseDtoFeatureRestrictionDetails](docs/ResponseDtoFeatureRestrictionDetails.md) - - [ResponseDtoFeatureRestrictionMetadata](docs/ResponseDtoFeatureRestrictionMetadata.md) - - [ResponseDtoFeatureRestrictionUsageDto](docs/ResponseDtoFeatureRestrictionUsageDto.md) - [ResponseDtoFieldValues](docs/ResponseDtoFieldValues.md) - - [ResponseDtoFilterDto](docs/ResponseDtoFilterDto.md) + - [ResponseDtoFilter](docs/ResponseDtoFilter.md) - [ResponseDtoGcpResponse](docs/ResponseDtoGcpResponse.md) - - [ResponseDtoGcrBuildDetailsDto](docs/ResponseDtoGcrBuildDetailsDto.md) - - [ResponseDtoGcrResponseDto](docs/ResponseDtoGcrResponseDto.md) - - [ResponseDtoGitBranchListDto](docs/ResponseDtoGitBranchListDto.md) + - [ResponseDtoGitBranchList](docs/ResponseDtoGitBranchList.md) - [ResponseDtoGitFileContent](docs/ResponseDtoGitFileContent.md) - - [ResponseDtoGitOpsProviderResponseDto](docs/ResponseDtoGitOpsProviderResponseDto.md) - - [ResponseDtoGitSyncErrorCountDto](docs/ResponseDtoGitSyncErrorCountDto.md) - - [ResponseDtoGitSyncRepoFilesListDto](docs/ResponseDtoGitSyncRepoFilesListDto.md) - - [ResponseDtoGitSyncSettingsDto](docs/ResponseDtoGitSyncSettingsDto.md) - - [ResponseDtoHealthDeploymentDashboard](docs/ResponseDtoHealthDeploymentDashboard.md) - - [ResponseDtoInstanceCountDetailsByEnvTypeAndServiceId](docs/ResponseDtoInstanceCountDetailsByEnvTypeAndServiceId.md) - - [ResponseDtoInstancesByBuildIdList](docs/ResponseDtoInstancesByBuildIdList.md) + - [ResponseDtoGitSyncErrorCount](docs/ResponseDtoGitSyncErrorCount.md) + - [ResponseDtoGitSyncRepoFilesList](docs/ResponseDtoGitSyncRepoFilesList.md) + - [ResponseDtoGitSyncSettings](docs/ResponseDtoGitSyncSettings.md) + - [ResponseDtoInvite](docs/ResponseDtoInvite.md) - [ResponseDtoInviteAcceptResponse](docs/ResponseDtoInviteAcceptResponse.md) - - [ResponseDtoInviteDto](docs/ResponseDtoInviteDto.md) - - [ResponseDtoJiraIssueCreateMetadataNg](docs/ResponseDtoJiraIssueCreateMetadataNg.md) - - [ResponseDtoJiraIssueUpdateMetadataNg](docs/ResponseDtoJiraIssueUpdateMetadataNg.md) - - [ResponseDtoJsonNode](docs/ResponseDtoJsonNode.md) - [ResponseDtoLicensesWithSummary](docs/ResponseDtoLicensesWithSummary.md) - - [ResponseDtoListApiKeyDto](docs/ResponseDtoListApiKeyDto.md) - [ResponseDtoListConnectorResponse](docs/ResponseDtoListConnectorResponse.md) - - [ResponseDtoListEncryptedDataDetail](docs/ResponseDtoListEncryptedDataDetail.md) - - [ResponseDtoListEntitySetupUsageDto](docs/ResponseDtoListEntitySetupUsageDto.md) - [ResponseDtoListEnvironmentResponse](docs/ResponseDtoListEnvironmentResponse.md) - - [ResponseDtoListExecutionStatus](docs/ResponseDtoListExecutionStatus.md) - [ResponseDtoListFeatureRestrictionDetails](docs/ResponseDtoListFeatureRestrictionDetails.md) - [ResponseDtoListFeatureRestrictionMetadata](docs/ResponseDtoListFeatureRestrictionMetadata.md) - - [ResponseDtoListGitSyncEntityListDto](docs/ResponseDtoListGitSyncEntityListDto.md) + - [ResponseDtoListGitSyncEntityList](docs/ResponseDtoListGitSyncEntityList.md) - [ResponseDtoListInviteOperationResponse](docs/ResponseDtoListInviteOperationResponse.md) - - [ResponseDtoListJiraProjectBasicNg](docs/ResponseDtoListJiraProjectBasicNg.md) - - [ResponseDtoListJiraStatusNg](docs/ResponseDtoListJiraStatusNg.md) - [ResponseDtoListModuleLicense](docs/ResponseDtoListModuleLicense.md) - - [ResponseDtoListProject](docs/ResponseDtoListProject.md) - - [ResponseDtoListRoleAssignmentResponse](docs/ResponseDtoListRoleAssignmentResponse.md) - - [ResponseDtoListServiceAccountDto](docs/ResponseDtoListServiceAccountDto.md) - - [ResponseDtoListServiceDefinitionType](docs/ResponseDtoListServiceDefinitionType.md) - [ResponseDtoListServiceResponse](docs/ResponseDtoListServiceResponse.md) - - [ResponseDtoListSourceCodeManagerDto](docs/ResponseDtoListSourceCodeManagerDto.md) + - [ResponseDtoListSourceCodeManager](docs/ResponseDtoListSourceCodeManager.md) - [ResponseDtoListString](docs/ResponseDtoListString.md) - - [ResponseDtoListUserGroupAggregateDto](docs/ResponseDtoListUserGroupAggregateDto.md) - - [ResponseDtoListUserGroupDto](docs/ResponseDtoListUserGroupDto.md) - - [ResponseDtoMapEditionSetEditionActionDto](docs/ResponseDtoMapEditionSetEditionActionDto.md) - - [ResponseDtoMapServiceDefinitionTypeListExecutionStrategyType](docs/ResponseDtoMapServiceDefinitionTypeListExecutionStrategyType.md) - - [ResponseDtoMapStringString](docs/ResponseDtoMapStringString.md) + - [ResponseDtoMapEditionSetEditionAction](docs/ResponseDtoMapEditionSetEditionAction.md) + - [ResponseDtoMapModuleTypeLong](docs/ResponseDtoMapModuleTypeLong.md) - [ResponseDtoModuleLicense](docs/ResponseDtoModuleLicense.md) - - [ResponseDtoOptionalHarnessServiceInfoNg](docs/ResponseDtoOptionalHarnessServiceInfoNg.md) - - [ResponseDtoOptionalInviteDto](docs/ResponseDtoOptionalInviteDto.md) - - [ResponseDtoOrganizationAggregateDto](docs/ResponseDtoOrganizationAggregateDto.md) + - [ResponseDtoOptionalInvite](docs/ResponseDtoOptionalInvite.md) - [ResponseDtoOrganizationResponse](docs/ResponseDtoOrganizationResponse.md) - - [ResponseDtoPageEntitySetupUsageDto](docs/ResponseDtoPageEntitySetupUsageDto.md) - - [ResponseDtoPageNgActivityDto](docs/ResponseDtoPageNgActivityDto.md) - - [ResponseDtoPageNgActivitySummaryDto](docs/ResponseDtoPageNgActivitySummaryDto.md) - - [ResponseDtoPageResponseApiKeyAggregateDto](docs/ResponseDtoPageResponseApiKeyAggregateDto.md) - [ResponseDtoPageResponseConnectorResponse](docs/ResponseDtoPageResponseConnectorResponse.md) - [ResponseDtoPageResponseEnvironmentResponse](docs/ResponseDtoPageResponseEnvironmentResponse.md) - - [ResponseDtoPageResponseEnvironmentResponseDto](docs/ResponseDtoPageResponseEnvironmentResponseDto.md) - - [ResponseDtoPageResponseFilterDto](docs/ResponseDtoPageResponseFilterDto.md) - - [ResponseDtoPageResponseGitOpsProviderResponseDto](docs/ResponseDtoPageResponseGitOpsProviderResponseDto.md) - - [ResponseDtoPageResponseGitSyncEntityListDto](docs/ResponseDtoPageResponseGitSyncEntityListDto.md) - - [ResponseDtoPageResponseGitSyncErrorAggregateByCommitDto](docs/ResponseDtoPageResponseGitSyncErrorAggregateByCommitDto.md) - - [ResponseDtoPageResponseGitSyncErrorDto](docs/ResponseDtoPageResponseGitSyncErrorDto.md) - - [ResponseDtoPageResponseInviteDto](docs/ResponseDtoPageResponseInviteDto.md) - - [ResponseDtoPageResponseOrganizationAggregateDto](docs/ResponseDtoPageResponseOrganizationAggregateDto.md) + - [ResponseDtoPageResponseFilter](docs/ResponseDtoPageResponseFilter.md) + - [ResponseDtoPageResponseGitSyncEntityList](docs/ResponseDtoPageResponseGitSyncEntityList.md) + - [ResponseDtoPageResponseGitSyncError](docs/ResponseDtoPageResponseGitSyncError.md) + - [ResponseDtoPageResponseGitSyncErrorAggregateByCommit](docs/ResponseDtoPageResponseGitSyncErrorAggregateByCommit.md) + - [ResponseDtoPageResponseInvite](docs/ResponseDtoPageResponseInvite.md) - [ResponseDtoPageResponseOrganizationResponse](docs/ResponseDtoPageResponseOrganizationResponse.md) - - [ResponseDtoPageResponseProject](docs/ResponseDtoPageResponseProject.md) - - [ResponseDtoPageResponseProjectAggregateDto](docs/ResponseDtoPageResponseProjectAggregateDto.md) - [ResponseDtoPageResponseProjectResponse](docs/ResponseDtoPageResponseProjectResponse.md) - - [ResponseDtoPageResponseRoleAssignmentResponse](docs/ResponseDtoPageResponseRoleAssignmentResponse.md) - - [ResponseDtoPageResponseSecretResponseWrapper](docs/ResponseDtoPageResponseSecretResponseWrapper.md) - - [ResponseDtoPageResponseServiceAccountAggregateDto](docs/ResponseDtoPageResponseServiceAccountAggregateDto.md) - [ResponseDtoPageResponseServiceResponse](docs/ResponseDtoPageResponseServiceResponse.md) - - [ResponseDtoPageResponseServiceResponseDto](docs/ResponseDtoPageResponseServiceResponseDto.md) - - [ResponseDtoPageResponseTokenAggregateDto](docs/ResponseDtoPageResponseTokenAggregateDto.md) - - [ResponseDtoPageResponseUserAggregateDto](docs/ResponseDtoPageResponseUserAggregateDto.md) - - [ResponseDtoPageResponseUserGroupAggregateDto](docs/ResponseDtoPageResponseUserGroupAggregateDto.md) - - [ResponseDtoPageResponseUserGroupDto](docs/ResponseDtoPageResponseUserGroupDto.md) - - [ResponseDtoPageResponseUserMetadataDto](docs/ResponseDtoPageResponseUserMetadataDto.md) - - [ResponseDtoPartialSchemaDto](docs/ResponseDtoPartialSchemaDto.md) - - [ResponseDtoPasswordChangeResponse](docs/ResponseDtoPasswordChangeResponse.md) - - [ResponseDtoPipelineConfig](docs/ResponseDtoPipelineConfig.md) - - [ResponseDtoPipelinesExecutionDashboardInfo](docs/ResponseDtoPipelinesExecutionDashboardInfo.md) - - [ResponseDtoPollingResponseDto](docs/ResponseDtoPollingResponseDto.md) - - [ResponseDtoProjectAggregateDto](docs/ResponseDtoProjectAggregateDto.md) - [ResponseDtoProjectResponse](docs/ResponseDtoProjectResponse.md) - - [ResponseDtoProjectsDashboardInfo](docs/ResponseDtoProjectsDashboardInfo.md) - - [ResponseDtoRestrictionMetadataMapResponseDto](docs/ResponseDtoRestrictionMetadataMapResponseDto.md) - - [ResponseDtoRoleAssignmentAggregateResponse](docs/ResponseDtoRoleAssignmentAggregateResponse.md) - - [ResponseDtoRoleAssignmentResponse](docs/ResponseDtoRoleAssignmentResponse.md) - [ResponseDtoSaasGitDto](docs/ResponseDtoSaasGitDto.md) - - [ResponseDtoSecretManagerConfigDto](docs/ResponseDtoSecretManagerConfigDto.md) - - [ResponseDtoSecretManagerMetadataDto](docs/ResponseDtoSecretManagerMetadataDto.md) - - [ResponseDtoSecretResponseWrapper](docs/ResponseDtoSecretResponseWrapper.md) - - [ResponseDtoSecretValidationResultDto](docs/ResponseDtoSecretValidationResultDto.md) - - [ResponseDtoServiceAccountAggregateDto](docs/ResponseDtoServiceAccountAggregateDto.md) - - [ResponseDtoServiceAccountDto](docs/ResponseDtoServiceAccountDto.md) - - [ResponseDtoServiceDeploymentInfoDto](docs/ResponseDtoServiceDeploymentInfoDto.md) - - [ResponseDtoServiceDeploymentListInfo](docs/ResponseDtoServiceDeploymentListInfo.md) - - [ResponseDtoServiceDetailsInfoDto](docs/ResponseDtoServiceDetailsInfoDto.md) - - [ResponseDtoServiceHeaderInfo](docs/ResponseDtoServiceHeaderInfo.md) - [ResponseDtoServiceResponse](docs/ResponseDtoServiceResponse.md) - - [ResponseDtoServiceResponseDto](docs/ResponseDtoServiceResponseDto.md) - - [ResponseDtoServicesCount](docs/ResponseDtoServicesCount.md) - - [ResponseDtoServicesDashboardInfo](docs/ResponseDtoServicesDashboardInfo.md) - - [ResponseDtoSourceCodeManagerDto](docs/ResponseDtoSourceCodeManagerDto.md) - - [ResponseDtoStepCategory](docs/ResponseDtoStepCategory.md) + - [ResponseDtoSourceCodeManager](docs/ResponseDtoSourceCodeManager.md) - [ResponseDtoString](docs/ResponseDtoString.md) - - [ResponseDtoTimeValuePairListDtoEnvIdCountPair](docs/ResponseDtoTimeValuePairListDtoEnvIdCountPair.md) - - [ResponseDtoTimeValuePairListDtoInteger](docs/ResponseDtoTimeValuePairListDtoInteger.md) - - [ResponseDtoTokenDto](docs/ResponseDtoTokenDto.md) - - [ResponseDtoTwoFactorAuthSettingsInfo](docs/ResponseDtoTwoFactorAuthSettingsInfo.md) - - [ResponseDtoUpsertWebhookResponseDto](docs/ResponseDtoUpsertWebhookResponseDto.md) - - [ResponseDtoUserAggregateDto](docs/ResponseDtoUserAggregateDto.md) - - [ResponseDtoUserGroupAggregateDto](docs/ResponseDtoUserGroupAggregateDto.md) - - [ResponseDtoUserGroupDto](docs/ResponseDtoUserGroupDto.md) - - [ResponseDtoUserInfo](docs/ResponseDtoUserInfo.md) - - [ResponseDtoYamlSnippetsDto](docs/ResponseDtoYamlSnippetsDto.md) - - [ResponseDtocdPipelineModuleInfo](docs/ResponseDtocdPipelineModuleInfo.md) - - [ResponseDtocdStageModuleInfo](docs/ResponseDtocdStageModuleInfo.md) - - [ResponseDtongActivityDto](docs/ResponseDtongActivityDto.md) + - [ResponseDtoTriggerFullSyncResponse](docs/ResponseDtoTriggerFullSyncResponse.md) - [ResponseMessage](docs/ResponseMessage.md) - [ResponseMessageException](docs/ResponseMessageException.md) - [ResponseMessageExceptionStackTrace](docs/ResponseMessageExceptionStackTrace.md) - [ResponseMessageExceptionSuppressed](docs/ResponseMessageExceptionSuppressed.md) - - [RestResponse](docs/RestResponse.md) - [RestResponseAuthenticationSettingsResponse](docs/RestResponseAuthenticationSettingsResponse.md) - [RestResponseBoolean](docs/RestResponseBoolean.md) - [RestResponseDelegateProfileDetailsNg](docs/RestResponseDelegateProfileDetailsNg.md) @@ -1001,143 +451,43 @@ Class | Method | HTTP request | Description - [RestResponsePageResponseDelegateProfileDetailsNg](docs/RestResponsePageResponseDelegateProfileDetailsNg.md) - [RestResponsePasswordStrengthPolicy](docs/RestResponsePasswordStrengthPolicy.md) - [RestResponseSsoConfig](docs/RestResponseSsoConfig.md) - - [RestResponseUserGroup](docs/RestResponseUserGroup.md) - - [RestResponseUserInfo](docs/RestResponseUserInfo.md) - - [RestResponseVerifyTokenResponseDto](docs/RestResponseVerifyTokenResponseDto.md) - [RestResponseVoid](docs/RestResponseVoid.md) - - [RestrictionDto](docs/RestrictionDto.md) - - [RestrictionMetadataDto](docs/RestrictionMetadataDto.md) - - [RestrictionMetadataMapRequestDto](docs/RestrictionMetadataMapRequestDto.md) - - [RestrictionMetadataMapResponseDto](docs/RestrictionMetadataMapResponseDto.md) - - [Role](docs/Role.md) - - [RoleAssignment](docs/RoleAssignment.md) - - [RoleAssignmentAggregateResponse](docs/RoleAssignmentAggregateResponse.md) - - [RoleAssignmentCreateRequest](docs/RoleAssignmentCreateRequest.md) - - [RoleAssignmentFilter](docs/RoleAssignmentFilter.md) - - [RoleAssignmentMetadataDto](docs/RoleAssignmentMetadataDto.md) - - [RoleAssignmentResponse](docs/RoleAssignmentResponse.md) + - [Restriction](docs/Restriction.md) + - [RestrictionMetadata](docs/RestrictionMetadata.md) - [RoleBinding](docs/RoleBinding.md) - - [RoleResponse](docs/RoleResponse.md) - [SaasGitDto](docs/SaasGitDto.md) - - [SamlLinkGroupRequest](docs/SamlLinkGroupRequest.md) - [SampleErrorMetadataDto](docs/SampleErrorMetadataDto.md) - - [Scope](docs/Scope.md) - [ScopingRuleDetailsNg](docs/ScopingRuleDetailsNg.md) - [SearchFilter](docs/SearchFilter.md) - - [SecretDtov2](docs/SecretDtov2.md) - - [SecretFileSpecDto](docs/SecretFileSpecDto.md) - - [SecretManagerConfigDto](docs/SecretManagerConfigDto.md) - - [SecretManagerMetadataDto](docs/SecretManagerMetadataDto.md) - - [SecretManagerMetadataRequestDto](docs/SecretManagerMetadataRequestDto.md) - - [SecretManagerMetadataRequestSpecDto](docs/SecretManagerMetadataRequestSpecDto.md) - - [SecretManagerMetadataSpecDto](docs/SecretManagerMetadataSpecDto.md) - - [SecretNgVariable](docs/SecretNgVariable.md) - - [SecretReferredByConnectorSetupUsageDetail](docs/SecretReferredByConnectorSetupUsageDetail.md) - - [SecretRequestWrapper](docs/SecretRequestWrapper.md) - - [SecretResourceFilterDto](docs/SecretResourceFilterDto.md) - - [SecretResponseWrapper](docs/SecretResponseWrapper.md) - - [SecretSpecDto](docs/SecretSpecDto.md) - - [SecretTextSpecDto](docs/SecretTextSpecDto.md) - - [SecretUniqueIdentifier](docs/SecretUniqueIdentifier.md) - - [SecretValidationMetaData](docs/SecretValidationMetaData.md) - - [SecretValidationResultDto](docs/SecretValidationResultDto.md) - - [SecretsFilesBody](docs/SecretsFilesBody.md) - - [ServiceAccountAggregateDto](docs/ServiceAccountAggregateDto.md) - [ServiceAccountConfig](docs/ServiceAccountConfig.md) - - [ServiceAccountDto](docs/ServiceAccountDto.md) - - [ServiceDashboardInfo](docs/ServiceDashboardInfo.md) - - [ServiceDeployment](docs/ServiceDeployment.md) - - [ServiceDeploymentInfo](docs/ServiceDeploymentInfo.md) - - [ServiceDeploymentInfoDto](docs/ServiceDeploymentInfoDto.md) - - [ServiceDeploymentListInfo](docs/ServiceDeploymentListInfo.md) - - [ServiceDescriptor](docs/ServiceDescriptor.md) - - [ServiceDescriptorProto](docs/ServiceDescriptorProto.md) - - [ServiceDescriptorProtoOrBuilder](docs/ServiceDescriptorProtoOrBuilder.md) - - [ServiceDetailsDto](docs/ServiceDetailsDto.md) - - [ServiceDetailsInfoDto](docs/ServiceDetailsInfoDto.md) - - [ServiceExecutionSummary](docs/ServiceExecutionSummary.md) - - [ServiceHeaderInfo](docs/ServiceHeaderInfo.md) - - [ServiceOptions](docs/ServiceOptions.md) - - [ServiceOptionsOrBuilder](docs/ServiceOptionsOrBuilder.md) - - [ServicePipelineInfo](docs/ServicePipelineInfo.md) - - [ServiceRequestDto](docs/ServiceRequestDto.md) + - [ServiceRequest](docs/ServiceRequest.md) - [ServiceResponse](docs/ServiceResponse.md) - - [ServiceResponseDto](docs/ServiceResponseDto.md) - - [ServicesCount](docs/ServicesCount.md) - - [ServicesDashboardInfo](docs/ServicesDashboardInfo.md) - - [SetupUsageDetail](docs/SetupUsageDetail.md) - - [SignupDto](docs/SignupDto.md) - - [SlackConfigDto](docs/SlackConfigDto.md) - [SlackNotificationSetting](docs/SlackNotificationSetting.md) - - [Sort](docs/Sort.md) - [SortOrder](docs/SortOrder.md) - - [SourceCodeInfo](docs/SourceCodeInfo.md) - - [SourceCodeInfoOrBuilder](docs/SourceCodeInfoOrBuilder.md) + - [SourceCodeManager](docs/SourceCodeManager.md) - [SourceCodeManagerAuthentication](docs/SourceCodeManagerAuthentication.md) - - [SourceCodeManagerDto](docs/SourceCodeManagerDto.md) - [SplunkConnectorDto](docs/SplunkConnectorDto.md) - - [SshAuthDto](docs/SshAuthDto.md) - - [SshConfigDto](docs/SshConfigDto.md) - - [SshCredentialSpecDto](docs/SshCredentialSpecDto.md) - - [SshKeyPathCredentialDto](docs/SshKeyPathCredentialDto.md) - - [SshKeyReferenceCredentialDto](docs/SshKeyReferenceCredentialDto.md) - - [SshKeySpecDto](docs/SshKeySpecDto.md) - - [SshPasswordCredentialDto](docs/SshPasswordCredentialDto.md) - [SsoConfig](docs/SsoConfig.md) - [SsoRequest](docs/SsoRequest.md) - [SsoSettings](docs/SsoSettings.md) - - [StageElementWrapperConfig](docs/StageElementWrapperConfig.md) - [StartTrial](docs/StartTrial.md) - - [StaticLimitRestrictionDto](docs/StaticLimitRestrictionDto.md) - - [StaticLimitRestrictionMetadataDto](docs/StaticLimitRestrictionMetadataDto.md) - - [StepCategory](docs/StepCategory.md) - - [StepData](docs/StepData.md) - - [StringNgVariable](docs/StringNgVariable.md) + - [StaticLimitRestriction](docs/StaticLimitRestriction.md) + - [StaticLimitRestrictionMetadata](docs/StaticLimitRestrictionMetadata.md) - [SumoLogicConnectorDto](docs/SumoLogicConnectorDto.md) - [TechStack](docs/TechStack.md) - - [TgtGenerationSpecDto](docs/TgtGenerationSpecDto.md) - - [TgtKeyTabFilePathSpecDto](docs/TgtKeyTabFilePathSpecDto.md) - - [TgtPasswordSpecDto](docs/TgtPasswordSpecDto.md) - - [TimeBasedDeploymentInfo](docs/TimeBasedDeploymentInfo.md) - [TimeUnit](docs/TimeUnit.md) - - [TimeValuePairEnvIdCountPair](docs/TimeValuePairEnvIdCountPair.md) - - [TimeValuePairInteger](docs/TimeValuePairInteger.md) - - [TimeValuePairListDtoEnvIdCountPair](docs/TimeValuePairListDtoEnvIdCountPair.md) - - [TimeValuePairListDtoInteger](docs/TimeValuePairListDtoInteger.md) - - [TokenAggregateDto](docs/TokenAggregateDto.md) - - [TokenDto](docs/TokenDto.md) - - [TotalDeploymentInfo](docs/TotalDeploymentInfo.md) - [TrialSignupOptions](docs/TrialSignupOptions.md) + - [TriggerFullSyncResponse](docs/TriggerFullSyncResponse.md) - [TwoFactorAdminOverrideSettings](docs/TwoFactorAdminOverrideSettings.md) - - [TwoFactorAuthSettingsInfo](docs/TwoFactorAuthSettingsInfo.md) - - [UninterpretedOption](docs/UninterpretedOption.md) - - [UninterpretedOptionOrBuilder](docs/UninterpretedOptionOrBuilder.md) - - [UnknownFieldSet](docs/UnknownFieldSet.md) - - [UpsertWebhookRequestDto](docs/UpsertWebhookRequestDto.md) - - [UpsertWebhookResponseDto](docs/UpsertWebhookResponseDto.md) - [User](docs/User.md) - - [UserAggregateDto](docs/UserAggregateDto.md) - - [UserFilter](docs/UserFilter.md) - [UserGroup](docs/UserGroup.md) - - [UserGroupAggregateDto](docs/UserGroupAggregateDto.md) - - [UserGroupDto](docs/UserGroupDto.md) - - [UserGroupFilterDto](docs/UserGroupFilterDto.md) - [UserInfo](docs/UserInfo.md) - [UserLockoutInfo](docs/UserLockoutInfo.md) - [UserLockoutPolicy](docs/UserLockoutPolicy.md) - - [UserMetadataDto](docs/UserMetadataDto.md) - [UtmInfo](docs/UtmInfo.md) - [ValidationError](docs/ValidationError.md) - - [VaultConfigDto](docs/VaultConfigDto.md) - [VaultConnectorDto](docs/VaultConnectorDto.md) - - [VerifyTokenResponseDto](docs/VerifyTokenResponseDto.md) - - [WebhookResponse](docs/WebhookResponse.md) - [WorkflowFilter](docs/WorkflowFilter.md) - - [WorkloadCountInfo](docs/WorkloadCountInfo.md) - - [WorkloadDateCountInfo](docs/WorkloadDateCountInfo.md) - - [WorkloadDeploymentInfo](docs/WorkloadDeploymentInfo.md) - - [YamlSnippetMetaDataDto](docs/YamlSnippetMetaDataDto.md) - - [YamlSnippetsDto](docs/YamlSnippetsDto.md) ## Documentation For Authorization Endpoints do not require authorization. diff --git a/harness/nextgen/api_authentication_settings.go b/harness/nextgen/api_authentication_settings.go index fe6b0f8b..f2aaa592 100644 --- a/harness/nextgen/api_authentication_settings.go +++ b/harness/nextgen/api_authentication_settings.go @@ -31,7 +31,7 @@ type AuthenticationSettingsApiService service AuthenticationSettingsApiService Deletes Saml meta data by accountIdentifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *AuthenticationSettingsApiDeleteSamlMetaDataOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity @return RestResponseSsoConfig */ @@ -144,7 +144,7 @@ func (a *AuthenticationSettingsApiService) DeleteSamlMetaData(ctx context.Contex AuthenticationSettingsApiService Get the authentication settings by accountIdentifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *AuthenticationSettingsApiGetAuthenticationSettingsOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity @return RestResponseAuthenticationSettingsResponse */ @@ -257,7 +257,7 @@ func (a *AuthenticationSettingsApiService) GetAuthenticationSettings(ctx context AuthenticationSettingsApiService Get the password strength settings by accountIdentifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *AuthenticationSettingsApiGetPasswordStrengthSettingsOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity @return RestResponsePasswordStrengthPolicy */ @@ -370,7 +370,7 @@ func (a *AuthenticationSettingsApiService) GetPasswordStrengthSettings(ctx conte AuthenticationSettingsApiService Get the Saml login test by accountId * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *AuthenticationSettingsApiGetSamlLoginTestOpts - Optional Parameters: - * @param "AccountId" (optional.String) - + * @param "AccountId" (optional.String) - Account Identifier for the entity @return RestResponseLoginTypeResponse */ @@ -482,10 +482,10 @@ func (a *AuthenticationSettingsApiService) GetSamlLoginTest(ctx context.Context, /* AuthenticationSettingsApiService Updates the login settings * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body This is the updated Login Settings. This should have all the fields not just the updated ones - * @param loginSettingsId + * @param body This is the updated Login Settings. Please provide values for all fields, not just the fields you are updating + * @param loginSettingsId Login Settings Identifier * @param optional nil or *AuthenticationSettingsApiPutLoginSettingsOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity @return RestResponseLoginSettings */ @@ -601,7 +601,7 @@ func (a *AuthenticationSettingsApiService) PutLoginSettings(ctx context.Context, AuthenticationSettingsApiService Deletes Oauth mechanism by accountIdentifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *AuthenticationSettingsApiRemoveOauthMechanismOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity @return RestResponseBoolean */ @@ -715,7 +715,7 @@ AuthenticationSettingsApiService set two factor auth at account lever by account * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *AuthenticationSettingsApiSetTwoFactorAuthAtAccountLevelOpts - Optional Parameters: * @param "Body" (optional.Interface of TwoFactorAdminOverrideSettings) - - * @param "AccountIdentifier" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity @return RestResponseBoolean */ @@ -835,8 +835,8 @@ func (a *AuthenticationSettingsApiService) SetTwoFactorAuthAtAccountLevel(ctx co AuthenticationSettingsApiService Updates the Auth mechanism by accountIdentifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *AuthenticationSettingsApiUpdateAuthMechanismOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "AuthenticationMechanism" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "AuthenticationMechanism" (optional.String) - Type of Authentication Mechanism SSO or NON_SSO @return RestResponseBoolean */ @@ -954,7 +954,7 @@ AuthenticationSettingsApiService Updates the Oauth providers by accountIdentifie * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *AuthenticationSettingsApiUpdateOauthProvidersOpts - Optional Parameters: * @param "Body" (optional.Interface of OAuthSettings) - - * @param "AccountIdentifier" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity @return RestResponseBoolean */ @@ -1071,7 +1071,7 @@ func (a *AuthenticationSettingsApiService) UpdateOauthProviders(ctx context.Cont } /* -AuthenticationSettingsApiService Uploads the saml metadata by accountId +AuthenticationSettingsApiService Updates the saml metadata by accountId * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *AuthenticationSettingsApiUpdateSamlMetaDataOpts - Optional Parameters: * @param "File" (optional.Interface of FormDataContentDisposition) - @@ -1079,7 +1079,8 @@ AuthenticationSettingsApiService Uploads the saml metadata by accountId * @param "GroupMembershipAttr" (optional.String) - * @param "AuthorizationEnabled" (optional.Bool) - * @param "LogoutUrl" (optional.String) - - * @param "AccountId" (optional.String) - + * @param "EntityIdentifier" (optional.String) - + * @param "AccountId" (optional.String) - Account Identifier for the entity @return RestResponseSsoConfig */ @@ -1089,6 +1090,7 @@ type AuthenticationSettingsApiUpdateSamlMetaDataOpts struct { GroupMembershipAttr optional.String AuthorizationEnabled optional.Bool LogoutUrl optional.String + EntityIdentifier optional.String AccountId optional.String } @@ -1143,6 +1145,9 @@ func (a *AuthenticationSettingsApiService) UpdateSamlMetaData(ctx context.Contex if localVarOptionals != nil && localVarOptionals.LogoutUrl.IsSet() { localVarFormParams.Add("logoutUrl", parameterToString(localVarOptionals.LogoutUrl.Value(), "")) } + if localVarOptionals != nil && localVarOptionals.EntityIdentifier.IsSet() { + localVarFormParams.Add("entityIdentifier", parameterToString(localVarOptionals.EntityIdentifier.Value(), "")) + } r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) if err != nil { return localVarReturnValue, nil, err @@ -1212,8 +1217,8 @@ func (a *AuthenticationSettingsApiService) UpdateSamlMetaData(ctx context.Contex AuthenticationSettingsApiService Updates the Whitelisted domains by accountIdentifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *AuthenticationSettingsApiUpdateWhitelistedDomainsOpts - Optional Parameters: - * @param "Body" (optional.Interface of []string) - Set of whiteListed domains that needs to be for the account - * @param "AccountIdentifier" (optional.String) - + * @param "Body" (optional.Interface of []string) - Set of whitelisted domains and IPs for the account + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity @return RestResponseBoolean */ @@ -1330,7 +1335,7 @@ func (a *AuthenticationSettingsApiService) UpdateWhitelistedDomains(ctx context. } /* -AuthenticationSettingsApiService +AuthenticationSettingsApiService Uploads the saml metadata by accountId * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *AuthenticationSettingsApiUploadSamlMetaDataOpts - Optional Parameters: * @param "File" (optional.Interface of FormDataContentDisposition) - @@ -1338,8 +1343,9 @@ AuthenticationSettingsApiService * @param "GroupMembershipAttr" (optional.String) - * @param "AuthorizationEnabled" (optional.Bool) - * @param "LogoutUrl" (optional.String) - - * @param "AccountId" (optional.String) - - + * @param "EntityIdentifier" (optional.String) - + * @param "AccountId" (optional.String) - Account Identifier for the entity +@return RestResponseSsoConfig */ type AuthenticationSettingsApiUploadSamlMetaDataOpts struct { @@ -1348,15 +1354,17 @@ type AuthenticationSettingsApiUploadSamlMetaDataOpts struct { GroupMembershipAttr optional.String AuthorizationEnabled optional.Bool LogoutUrl optional.String + EntityIdentifier optional.String AccountId optional.String } -func (a *AuthenticationSettingsApiService) UploadSamlMetaData(ctx context.Context, localVarOptionals *AuthenticationSettingsApiUploadSamlMetaDataOpts) (*http.Response, error) { +func (a *AuthenticationSettingsApiService) UploadSamlMetaData(ctx context.Context, localVarOptionals *AuthenticationSettingsApiUploadSamlMetaDataOpts) (RestResponseSsoConfig, *http.Response, error) { var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue RestResponseSsoConfig ) // create path and map variables @@ -1401,20 +1409,31 @@ func (a *AuthenticationSettingsApiService) UploadSamlMetaData(ctx context.Contex if localVarOptionals != nil && localVarOptionals.LogoutUrl.IsSet() { localVarFormParams.Add("logoutUrl", parameterToString(localVarOptionals.LogoutUrl.Value(), "")) } + if localVarOptionals != nil && localVarOptionals.EntityIdentifier.IsSet() { + localVarFormParams.Add("entityIdentifier", parameterToString(localVarOptionals.EntityIdentifier.Value(), "")) + } r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) if err != nil { - return nil, err + return localVarReturnValue, nil, err } localVarHttpResponse, err := a.client.callAPI(r) if err != nil || localVarHttpResponse == nil { - return localVarHttpResponse, err + return localVarReturnValue, localVarHttpResponse, err } localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) localVarHttpResponse.Body.Close() if err != nil { - return localVarHttpResponse, err + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } } if localVarHttpResponse.StatusCode >= 300 { @@ -1427,23 +1446,33 @@ func (a *AuthenticationSettingsApiService) UploadSamlMetaData(ctx context.Contex err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr } newErr.model = v - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr } if localVarHttpResponse.StatusCode == 500 { var v ModelError err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v RestResponseSsoConfig + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr } newErr.model = v - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr } - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr } - return localVarHttpResponse, nil + return localVarReturnValue, localVarHttpResponse, nil } diff --git a/harness/nextgen/api_connectors.go b/harness/nextgen/api_connectors.go index f8ceac7f..16d65e40 100644 --- a/harness/nextgen/api_connectors.go +++ b/harness/nextgen/api_connectors.go @@ -30,15 +30,16 @@ type ConnectorsApiService service /* ConnectorsApiService Creates a Connector * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body Details of the Connector to be created + * @param body Details of the Connector to create * @param optional nil or *ConnectorsApiCreateConnectorOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "RootFolder" (optional.String) - - * @param "FilePath" (optional.String) - - * @param "CommitMsg" (optional.String) - - * @param "BaseBranch" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "RootFolder" (optional.String) - Default Folder Path + * @param "FilePath" (optional.String) - File Path + * @param "CommitMsg" (optional.String) - File Path + * @param "IsNewBranch" (optional.Bool) - Checks the new branch + * @param "BaseBranch" (optional.String) - Default Branch @return ResponseDtoConnectorResponse */ @@ -49,6 +50,7 @@ type ConnectorsApiCreateConnectorOpts struct { RootFolder optional.String FilePath optional.String CommitMsg optional.String + IsNewBranch optional.Bool BaseBranch optional.String } @@ -86,6 +88,9 @@ func (a *ConnectorsApiService) CreateConnector(ctx context.Context, body Connect if localVarOptionals != nil && localVarOptionals.CommitMsg.IsSet() { localVarQueryParams.Add("commitMsg", parameterToString(localVarOptionals.CommitMsg.Value(), "")) } + if localVarOptionals != nil && localVarOptionals.IsNewBranch.IsSet() { + localVarQueryParams.Add("isNewBranch", parameterToString(localVarOptionals.IsNewBranch.Value(), "")) + } if localVarOptionals != nil && localVarOptionals.BaseBranch.IsSet() { localVarQueryParams.Add("baseBranch", parameterToString(localVarOptionals.BaseBranch.Value(), "")) } @@ -176,17 +181,17 @@ func (a *ConnectorsApiService) CreateConnector(ctx context.Context, body Connect /* ConnectorsApiService Deletes Connector by identifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param identifier + * @param accountIdentifier Account Identifier for the entity + * @param identifier Connector Identifier * @param optional nil or *ConnectorsApiDeleteConnectorOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "RootFolder" (optional.String) - - * @param "FilePath" (optional.String) - - * @param "CommitMsg" (optional.String) - - * @param "LastObjectId" (optional.String) - + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "RootFolder" (optional.String) - Default Folder Path + * @param "FilePath" (optional.String) - File Path + * @param "CommitMsg" (optional.String) - Commit Message + * @param "LastObjectId" (optional.String) - Last Object Id @return ResponseDtoBoolean */ @@ -328,7 +333,7 @@ func (a *ConnectorsApiService) DeleteConnector(ctx context.Context, accountIdent /* ConnectorsApiService Get the allowed field values by Connector Type * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param connectorType + * @param connectorType Connector type @return ResponseDtoFieldValues */ func (a *ConnectorsApiService) GetAllAllowedFieldValues(ctx context.Context, connectorType string) (ResponseDtoFieldValues, *http.Response, error) { @@ -434,9 +439,9 @@ func (a *ConnectorsApiService) GetAllAllowedFieldValues(ctx context.Context, con ConnectorsApiService Get the Template URL of connector * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *ConnectorsApiGetCEAwsTemplateOpts - Optional Parameters: - * @param "EventsEnabled" (optional.Bool) - - * @param "CurEnabled" (optional.Bool) - - * @param "OptimizationEnabled" (optional.Bool) - + * @param "EventsEnabled" (optional.Bool) - Specify whether or not to enable events + * @param "CurEnabled" (optional.Bool) - Specify whether or not to enable CUR + * @param "OptimizationEnabled" (optional.Bool) - Specify whether or not to enable optimization @return ResponseDtoString */ @@ -556,14 +561,14 @@ func (a *ConnectorsApiService) GetCEAwsTemplate(ctx context.Context, localVarOpt /* ConnectorsApiService get the Connector by accountIdentifier and connectorIdentifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier + * @param identifier Connector Identifier * @param optional nil or *ConnectorsApiGetConnectorOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "GetDefaultFromOtherRepo" (optional.Bool) - if true, return all the default entities @return ResponseDtoConnectorResponse */ @@ -697,7 +702,7 @@ func (a *ConnectorsApiService) GetConnector(ctx context.Context, identifier stri ConnectorsApiService gets the connector catalogue by accountIdentifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *ConnectorsApiGetConnectorCatalogueOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity @return ResponseDtoConnectorCatalogueRespone */ @@ -807,21 +812,21 @@ func (a *ConnectorsApiService) GetConnectorCatalogue(ctx context.Context, localV } /* -ConnectorsApiService Get the list of connectors satisfying the criteria (if any) in the request +ConnectorsApiService Get the list of Connectors satisfying the criteria (if any) in the request * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *ConnectorsApiGetConnectorListOpts - Optional Parameters: - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "Type_" (optional.String) - - * @param "Category" (optional.String) - - * @param "SourceCategory" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - + * @param "PageIndex" (optional.Int32) - Page number of navigation. If left empty, default value of 0 is assumed + * @param "PageSize" (optional.Int32) - Number of entries per page. If left empty, default value of 100 is assumed + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "SearchTerm" (optional.String) - Filter Connectors by searching for this word in Name, Id, and Tag + * @param "Type_" (optional.String) - Filter Connectors by type + * @param "Category" (optional.String) - Filter Connectors by category + * @param "SourceCategory" (optional.String) - Filter Connectors by Source Category. Available Source Categories are CLOUD_PROVIDER, SECRET_MANAGER, CLOUD_COST, ARTIFACTORY, CODE_REPO, MONITORING and TICKETING + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "GetDefaultFromOtherRepo" (optional.Bool) - if true, return all the default entities @return ResponseDtoPageResponseConnectorResponse */ @@ -975,22 +980,22 @@ func (a *ConnectorsApiService) GetConnectorList(ctx context.Context, localVarOpt } /* -ConnectorsApiService Get the list of connectors satisfying the criteria (if any) in the request +ConnectorsApiService Get the list of Connectors satisfying the criteria (if any) in the request * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param body Details of the filters applied * @param optional nil or *ConnectorsApiGetConnectorListV2Opts - Optional Parameters: - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "AccountIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - + * @param "PageIndex" (optional.Int32) - Page number of navigation. If left empty, default value of 0 is assumed + * @param "PageSize" (optional.Int32) - Number of entries per page. If left empty, default value of 100 is assumed + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "SearchTerm" (optional.String) - Filter Connectors based on this word in Connectors name, id and tag + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity * @param "FilterIdentifier" (optional.String) - - * @param "IncludeAllConnectorsAvailableAtScope" (optional.Bool) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - - * @param "GetDistinctFromBranches" (optional.Bool) - + * @param "IncludeAllConnectorsAvailableAtScope" (optional.Bool) - Specify whether or not to include all the Connectors accessible at the scope. For eg if set as true, at the Project scope we will get org and account Connector also in the response + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "GetDefaultFromOtherRepo" (optional.Bool) - if true, return all the default entities + * @param "GetDistinctFromBranches" (optional.Bool) - This when set to true along with GitSync enabled for the Connector, you can to get other Connectors too which are not from same repo - branch but different repo's default branch @return ResponseDtoPageResponseConnectorResponse */ @@ -1149,12 +1154,12 @@ func (a *ConnectorsApiService) GetConnectorListV2(ctx context.Context, body Conn ConnectorsApiService gets the connector's statistics by accountIdentifier, projectIdentifier and orgIdentifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *ConnectorsApiGetConnectorStatisticsOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "GetDefaultFromOtherRepo" (optional.Bool) - if true, return all the default entities @return ResponseDtoConnectorStatistics */ @@ -1286,11 +1291,11 @@ func (a *ConnectorsApiService) GetConnectorStatistics(ctx context.Context, local /* ConnectorsApiService * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier + * @param identifier Connector Identifier * @param optional nil or *ConnectorsApiGetConnectorValidationParamsOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity */ @@ -1390,16 +1395,16 @@ func (a *ConnectorsApiService) GetConnectorValidationParams(ctx context.Context, } /* -ConnectorsApiService Tests the connection of the connector by Identifier +ConnectorsApiService Tests the connection of the Connector by Identifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier + * @param identifier Connector Identifier * @param optional nil or *ConnectorsApiGetTestConnectionResultOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "GetDefaultFromOtherRepo" (optional.Bool) - if true, return all the default entities @return ResponseDtoConnectorValidationResult */ @@ -1532,12 +1537,12 @@ func (a *ConnectorsApiService) GetTestConnectionResult(ctx context.Context, iden /* ConnectorsApiService Tests the created Connector's connection * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier + * @param identifier Connector Identifier * @param optional nil or *ConnectorsApiGetTestGitRepoConnectionResultOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "RepoURL" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "RepoURL" (optional.String) - URL of the repository, specify only in the case of Account Type Git Connector @return ResponseDtoConnectorValidationResult */ @@ -1662,9 +1667,9 @@ func (a *ConnectorsApiService) GetTestGitRepoConnectionResult(ctx context.Contex /* ConnectorsApiService Get the list of connectors by FQN satisfying the criteria (if any) in the request * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body List of connectorsFQN as strings + * @param body List of ConnectorsFQN as strings * @param optional nil or *ConnectorsApiListConnectorByFQNOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity @return ResponseDtoListConnectorResponse */ @@ -1778,16 +1783,16 @@ func (a *ConnectorsApiService) ListConnectorByFQN(ctx context.Context, body []st /* ConnectorsApiService Updates the Connector * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body This is the updated Connector. This should have all the fields not just the updated ones + * @param body This is the updated Connector. Please provide values for all fields, not just the fields you are updating * @param optional nil or *ConnectorsApiPutConnectorOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "RootFolder" (optional.String) - - * @param "FilePath" (optional.String) - - * @param "CommitMsg" (optional.String) - - * @param "LastObjectId" (optional.String) - - * @param "BaseBranch" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "RootFolder" (optional.String) - Default Folder Path + * @param "FilePath" (optional.String) - Default Folder Path + * @param "CommitMsg" (optional.String) - Commit Message + * @param "LastObjectId" (optional.String) - Last Object Id + * @param "BaseBranch" (optional.String) - Default Branch @return ResponseDtoConnectorResponse */ @@ -1930,10 +1935,10 @@ func (a *ConnectorsApiService) PutConnector(ctx context.Context, body Connector, ConnectorsApiService validate the Connector by accountIdentifier and connectorIdentifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param optional nil or *ConnectorsApiValidateTheIdentifierIsUniqueOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifier" (optional.String) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Identifier" (optional.String) - Connector Identifier @return ResponseDtoBoolean */ diff --git a/harness/nextgen/api_default.go b/harness/nextgen/api_default.go deleted file mode 100644 index a3ffb671..00000000 --- a/harness/nextgen/api_default.go +++ /dev/null @@ -1,25605 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -import ( - "context" - "fmt" - "github.com/antihax/optional" - "io/ioutil" - "net/http" - "net/url" - "strings" -) - -// Linger please -var ( - _ context.Context -) - -type DefaultApiService service - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param token -@return ResponseDtoInviteAcceptResponse -*/ -func (a *DefaultApiService) Accept(ctx context.Context, token string) (ResponseDtoInviteAcceptResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoInviteAcceptResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/invites/accept" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("token", parameterToString(token, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoInviteAcceptResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param identifier - * @param userIdentifier - * @param optional nil or *DefaultApiAddMemberOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoUserGroupDto -*/ - -type DefaultApiAddMemberOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) AddMember(ctx context.Context, accountIdentifier string, identifier string, userIdentifier string, localVarOptionals *DefaultApiAddMemberOpts) (ResponseDtoUserGroupDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserGroupDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups/{identifier}/member/{userIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - localVarPath = strings.Replace(localVarPath, "{"+"userIdentifier"+"}", fmt.Sprintf("%v", userIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserGroupDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param accountIdentifier - * @param optional nil or *DefaultApiAddUsersOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoAddUsersResponse -*/ - -type DefaultApiAddUsersOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) AddUsers(ctx context.Context, body AddUsersDto, accountIdentifier string, localVarOptionals *DefaultApiAddUsersOpts) (ResponseDtoAddUsersResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoAddUsersResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/users" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoAddUsersResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiChangeUserPasswordOpts - Optional Parameters: - * @param "Body" (optional.Interface of PasswordChangeDto) - -@return ResponseDtoPasswordChangeResponse -*/ - -type DefaultApiChangeUserPasswordOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) ChangeUserPassword(ctx context.Context, localVarOptionals *DefaultApiChangeUserPasswordOpts) (ResponseDtoPasswordChangeResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPasswordChangeResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/password" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPasswordChangeResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiCheckIfLastAdminOpts - Optional Parameters: - * @param "UserId" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiCheckIfLastAdminOpts struct { - UserId optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) CheckIfLastAdmin(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiCheckIfLastAdminOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/last-admin" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.UserId.IsSet() { - localVarQueryParams.Add("userId", parameterToString(localVarOptionals.UserId.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param identifier - * @param userIdentifier - * @param optional nil or *DefaultApiCheckMemberOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiCheckMemberOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) CheckMember(ctx context.Context, accountIdentifier string, identifier string, userIdentifier string, localVarOptionals *DefaultApiCheckMemberOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups/{identifier}/member/{userIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - localVarPath = strings.Replace(localVarPath, "{"+"userIdentifier"+"}", fmt.Sprintf("%v", userIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiCheckUserMembershipOpts - Optional Parameters: - * @param "UserId" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiCheckUserMembershipOpts struct { - UserId optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) CheckUserMembership(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiCheckUserMembershipOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/usermembership" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.UserId.IsSet() { - localVarQueryParams.Add("userId", parameterToString(localVarOptionals.UserId.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiCommunitySignupOpts - Optional Parameters: - * @param "Body" (optional.Interface of SignupDto) - -@return RestResponseUserInfo -*/ - -type DefaultApiCommunitySignupOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) CommunitySignup(ctx context.Context, localVarOptionals *DefaultApiCommunitySignupOpts) (RestResponseUserInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RestResponseUserInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/signup/community" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v RestResponseUserInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiCompleteInviteOpts - Optional Parameters: - * @param "Token" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiCompleteInviteOpts struct { - Token optional.String -} - -func (a *DefaultApiService) CompleteInvite(ctx context.Context, localVarOptionals *DefaultApiCompleteInviteOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/invites/complete" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.Token.IsSet() { - localVarQueryParams.Add("token", parameterToString(localVarOptionals.Token.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param token -@return RestResponseUserInfo -*/ -func (a *DefaultApiService) CompleteSignupInvite(ctx context.Context, token string) (RestResponseUserInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RestResponseUserInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/signup/complete/{token}" - localVarPath = strings.Replace(localVarPath, "{"+"token"+"}", fmt.Sprintf("%v", token), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v RestResponseUserInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param accountIdentifier -@return ResponseDtoFilterDto -*/ -func (a *DefaultApiService) Create(ctx context.Context, body FilterDto, accountIdentifier string) (ResponseDtoFilterDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoFilterDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/filters" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoFilterDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiCreate1Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "RootFolder" (optional.String) - - * @param "FilePath" (optional.String) - - * @param "CommitMsg" (optional.String) - - * @param "BaseBranch" (optional.String) - -@return ResponseDtoGitOpsProviderResponseDto -*/ - -type DefaultApiCreate1Opts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Branch optional.String - RepoIdentifier optional.String - RootFolder optional.String - FilePath optional.String - CommitMsg optional.String - BaseBranch optional.String -} - -func (a *DefaultApiService) Create1(ctx context.Context, body GitOpsProviderDto, localVarOptionals *DefaultApiCreate1Opts) (ResponseDtoGitOpsProviderResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGitOpsProviderResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/gitopsproviders" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RootFolder.IsSet() { - localVarQueryParams.Add("rootFolder", parameterToString(localVarOptionals.RootFolder.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.FilePath.IsSet() { - localVarQueryParams.Add("filePath", parameterToString(localVarOptionals.FilePath.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.CommitMsg.IsSet() { - localVarQueryParams.Add("commitMsg", parameterToString(localVarOptionals.CommitMsg.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.BaseBranch.IsSet() { - localVarQueryParams.Add("baseBranch", parameterToString(localVarOptionals.BaseBranch.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGitOpsProviderResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param accountIdentifier - * @param optional nil or *DefaultApiCreate10Opts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoUserGroupDto -*/ - -type DefaultApiCreate10Opts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Create10(ctx context.Context, body UserGroupDto, accountIdentifier string, localVarOptionals *DefaultApiCreate10Opts) (ResponseDtoUserGroupDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserGroupDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserGroupDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiCreate11Opts - Optional Parameters: - * @param "AccountId" (optional.String) - -@return ResponseDtoServiceResponseDto -*/ - -type DefaultApiCreate11Opts struct { - AccountId optional.String -} - -func (a *DefaultApiService) Create11(ctx context.Context, body ServiceRequestDto, localVarOptionals *DefaultApiCreate11Opts) (ResponseDtoServiceResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/services" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiCreate12Opts - Optional Parameters: - * @param "Body" (optional.Interface of ServiceRequestDto) - - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoServiceResponse -*/ - -type DefaultApiCreate12Opts struct { - Body optional.Interface - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Create12(ctx context.Context, localVarOptionals *DefaultApiCreate12Opts) (ResponseDtoServiceResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/servicesV2" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body -@return ResponseDtoGitSyncSettingsDto -*/ -func (a *DefaultApiService) Create2(ctx context.Context, body GitSyncSettingsDto) (ResponseDtoGitSyncSettingsDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGitSyncSettingsDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-settings" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGitSyncSettingsDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiCreate3Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - -@return GitSyncConfigDto -*/ - -type DefaultApiCreate3Opts struct { - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Create3(ctx context.Context, body GitSyncConfigDto, localVarOptionals *DefaultApiCreate3Opts) (GitSyncConfigDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue GitSyncConfigDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v GitSyncConfigDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiCreate4Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoModuleLicense -*/ - -type DefaultApiCreate4Opts struct { - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Create4(ctx context.Context, body ModuleLicense, localVarOptionals *DefaultApiCreate4Opts) (ResponseDtoModuleLicense, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoModuleLicense - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/admin/licenses" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoModuleLicense - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiCreate5Opts - Optional Parameters: - * @param "Body" (optional.Interface of RoleAssignmentCreateRequest) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Managed" (optional.Bool) - -@return ResponseDtoListRoleAssignmentResponse -*/ - -type DefaultApiCreate5Opts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String - Managed optional.Bool -} - -func (a *DefaultApiService) Create5(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiCreate5Opts) (ResponseDtoListRoleAssignmentResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListRoleAssignmentResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/roleassignments/multi/internal" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Managed.IsSet() { - localVarQueryParams.Add("managed", parameterToString(localVarOptionals.Managed.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListRoleAssignmentResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiCreate6Opts - Optional Parameters: - * @param "Body" (optional.Interface of RoleAssignment) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoRoleAssignmentResponse -*/ - -type DefaultApiCreate6Opts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Create6(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiCreate6Opts) (ResponseDtoRoleAssignmentResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoRoleAssignmentResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/roleassignments" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoRoleAssignmentResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiCreate7Opts - Optional Parameters: - * @param "AccountId" (optional.String) - -@return ResponseDtoEnvironmentResponseDto -*/ - -type DefaultApiCreate7Opts struct { - AccountId optional.String -} - -func (a *DefaultApiService) Create7(ctx context.Context, body EnvironmentRequestDto, localVarOptionals *DefaultApiCreate7Opts) (ResponseDtoEnvironmentResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEnvironmentResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environments" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEnvironmentResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiCreate8Opts - Optional Parameters: - * @param "Body" (optional.Interface of EnvironmentRequestDto) - - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoEnvironmentResponse -*/ - -type DefaultApiCreate8Opts struct { - Body optional.Interface - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Create8(ctx context.Context, localVarOptionals *DefaultApiCreate8Opts) (ResponseDtoEnvironmentResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEnvironmentResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environmentsV2" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEnvironmentResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param accountIdentifier - * @param optional nil or *DefaultApiCreate9Opts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "PrivateSecret" (optional.Bool) - -@return ResponseDtoSecretResponseWrapper -*/ - -type DefaultApiCreate9Opts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - PrivateSecret optional.Bool -} - -func (a *DefaultApiService) Create9(ctx context.Context, body SecretRequestWrapper, accountIdentifier string, localVarOptionals *DefaultApiCreate9Opts) (ResponseDtoSecretResponseWrapper, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSecretResponseWrapper - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PrivateSecret.IsSet() { - localVarQueryParams.Add("privateSecret", parameterToString(localVarOptionals.PrivateSecret.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSecretResponseWrapper - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiCreateApiKeyOpts - Optional Parameters: - * @param "Body" (optional.Interface of ApiKeyDto) - -@return ResponseDtoApiKeyDto -*/ - -type DefaultApiCreateApiKeyOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) CreateApiKey(ctx context.Context, localVarOptionals *DefaultApiCreateApiKeyOpts) (ResponseDtoApiKeyDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoApiKeyDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/apikey" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoApiKeyDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param accountIdentifier - * @param optional nil or *DefaultApiCreateInvitationsOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoListInviteOperationResponse -*/ - -type DefaultApiCreateInvitationsOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) CreateInvitations(ctx context.Context, body CreateInviteDto, accountIdentifier string, localVarOptionals *DefaultApiCreateInvitationsOpts) (ResponseDtoListInviteOperationResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListInviteOperationResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/invites" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListInviteOperationResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body -@return ResponseDtoCreatePrdto -*/ -func (a *DefaultApiService) CreatePR(ctx context.Context, body GitPrCreateRequest) (ResponseDtoCreatePrdto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoCreatePrdto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/scm/createPR" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoCreatePrdto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiCreateSecretFileOpts - Optional Parameters: - * @param "File" (optional.Interface of interface{}) - - * @param "Spec" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "PrivateSecret" (optional.Bool) - -@return ResponseDtoSecretResponseWrapper -*/ - -type DefaultApiCreateSecretFileOpts struct { - File optional.Interface - Spec optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - PrivateSecret optional.Bool -} - -func (a *DefaultApiService) CreateSecretFile(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiCreateSecretFileOpts) (ResponseDtoSecretResponseWrapper, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSecretResponseWrapper - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/files" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PrivateSecret.IsSet() { - localVarQueryParams.Add("privateSecret", parameterToString(localVarOptionals.PrivateSecret.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"multipart/form-data"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.File.IsSet() { - localVarFormParams.Add("file", parameterToString(localVarOptionals.File.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Spec.IsSet() { - localVarFormParams.Add("spec", parameterToString(localVarOptionals.Spec.Value(), "")) - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSecretResponseWrapper - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiCreateServiceAccountOpts - Optional Parameters: - * @param "Body" (optional.Interface of ServiceAccountDto) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoServiceAccountDto -*/ - -type DefaultApiCreateServiceAccountOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) CreateServiceAccount(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiCreateServiceAccountOpts) (ResponseDtoServiceAccountDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceAccountDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/serviceaccount" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceAccountDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiCreateServicesOpts - Optional Parameters: - * @param "AccountId" (optional.String) - -@return ResponseDtoPageResponseServiceResponseDto -*/ - -type DefaultApiCreateServicesOpts struct { - AccountId optional.String -} - -func (a *DefaultApiService) CreateServices(ctx context.Context, body []ServiceRequestDto, localVarOptionals *DefaultApiCreateServicesOpts) (ResponseDtoPageResponseServiceResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseServiceResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/services/batch" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseServiceResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiCreateServices1Opts - Optional Parameters: - * @param "Body" (optional.Interface of []ServiceRequestDto) - - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoPageResponseServiceResponse -*/ - -type DefaultApiCreateServices1Opts struct { - Body optional.Interface - AccountIdentifier optional.String -} - -func (a *DefaultApiService) CreateServices1(ctx context.Context, localVarOptionals *DefaultApiCreateServices1Opts) (ResponseDtoPageResponseServiceResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/servicesV2/batch" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseServiceResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiCreateTokenOpts - Optional Parameters: - * @param "Body" (optional.Interface of TokenDto) - -@return ResponseDtoString -*/ - -type DefaultApiCreateTokenOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) CreateToken(ctx context.Context, localVarOptionals *DefaultApiCreateTokenOpts) (ResponseDtoString, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoString - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/token" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoString - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiCreateViaYamlOpts - Optional Parameters: - * @param "Body" (optional.Interface of SecretRequestWrapper) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "PrivateSecret" (optional.Bool) - -@return ResponseDtoSecretResponseWrapper -*/ - -type DefaultApiCreateViaYamlOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String - PrivateSecret optional.Bool -} - -func (a *DefaultApiService) CreateViaYaml(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiCreateViaYamlOpts) (ResponseDtoSecretResponseWrapper, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSecretResponseWrapper - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/yaml" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PrivateSecret.IsSet() { - localVarQueryParams.Add("privateSecret", parameterToString(localVarOptionals.PrivateSecret.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSecretResponseWrapper - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiDecryptEncryptedDetailsOpts - Optional Parameters: - * @param "Body" (optional.Interface of DecryptableEntityWithEncryptionConsumers) - - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoDecryptableEntity -*/ - -type DefaultApiDecryptEncryptedDetailsOpts struct { - Body optional.Interface - AccountIdentifier optional.String -} - -func (a *DefaultApiService) DecryptEncryptedDetails(ctx context.Context, localVarOptionals *DefaultApiDecryptEncryptedDetailsOpts) (ResponseDtoDecryptableEntity, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoDecryptableEntity - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/decrypt-encryption-details" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/x-kryo"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/x-kryo"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoDecryptableEntity - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param type_ - * @param optional nil or *DefaultApiDeleteOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiDeleteOpts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Delete(ctx context.Context, identifier string, type_ string, localVarOptionals *DefaultApiDeleteOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/filters/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - localVarQueryParams.Add("type", parameterToString(type_, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param optional nil or *DefaultApiDelete1Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiDelete1Opts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Delete1(ctx context.Context, identifier string, localVarOptionals *DefaultApiDelete1Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/gitopsproviders/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier -@return ResponseDtoBoolean -*/ -func (a *DefaultApiService) Delete10(ctx context.Context, identifier string, accountIdentifier string) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/source-code-manager/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiDelete2Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "ReferredEntityFQN" (optional.String) - - * @param "ReferredEntityType" (optional.String) - - * @param "ReferredByEntityFQN" (optional.String) - - * @param "ReferredByEntityType" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiDelete2Opts struct { - AccountIdentifier optional.String - ReferredEntityFQN optional.String - ReferredEntityType optional.String - ReferredByEntityFQN optional.String - ReferredByEntityType optional.String -} - -func (a *DefaultApiService) Delete2(ctx context.Context, localVarOptionals *DefaultApiDelete2Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/entitySetupUsage/internal" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ReferredEntityFQN.IsSet() { - localVarQueryParams.Add("referredEntityFQN", parameterToString(localVarOptionals.ReferredEntityFQN.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ReferredEntityType.IsSet() { - localVarQueryParams.Add("referredEntityType", parameterToString(localVarOptionals.ReferredEntityType.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ReferredByEntityFQN.IsSet() { - localVarQueryParams.Add("referredByEntityFQN", parameterToString(localVarOptionals.ReferredByEntityFQN.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ReferredByEntityType.IsSet() { - localVarQueryParams.Add("referredByEntityType", parameterToString(localVarOptionals.ReferredByEntityType.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param environmentIdentifier - * @param optional nil or *DefaultApiDelete3Opts - Optional Parameters: - * @param "IfMatch" (optional.String) - - * @param "AccountId" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiDelete3Opts struct { - IfMatch optional.String - AccountId optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Delete3(ctx context.Context, environmentIdentifier string, localVarOptionals *DefaultApiDelete3Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environments/{environmentIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"environmentIdentifier"+"}", fmt.Sprintf("%v", environmentIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param environmentIdentifier - * @param optional nil or *DefaultApiDelete4Opts - Optional Parameters: - * @param "IfMatch" (optional.String) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiDelete4Opts struct { - IfMatch optional.String - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Delete4(ctx context.Context, environmentIdentifier string, localVarOptionals *DefaultApiDelete4Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environmentsV2/{environmentIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"environmentIdentifier"+"}", fmt.Sprintf("%v", environmentIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param inviteId -@return ResponseDtoOptionalInviteDto -*/ -func (a *DefaultApiService) Delete5(ctx context.Context, inviteId string) (ResponseDtoOptionalInviteDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoOptionalInviteDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/invites/{inviteId}" - localVarPath = strings.Replace(localVarPath, "{"+"inviteId"+"}", fmt.Sprintf("%v", inviteId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoOptionalInviteDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier - * @param optional nil or *DefaultApiDelete6Opts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiDelete6Opts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Delete6(ctx context.Context, identifier string, accountIdentifier string, localVarOptionals *DefaultApiDelete6Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param optional nil or *DefaultApiDelete7Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoUserGroupDto -*/ - -type DefaultApiDelete7Opts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Delete7(ctx context.Context, identifier string, localVarOptionals *DefaultApiDelete7Opts) (ResponseDtoUserGroupDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserGroupDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserGroupDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param serviceIdentifier - * @param optional nil or *DefaultApiDelete8Opts - Optional Parameters: - * @param "IfMatch" (optional.String) - - * @param "AccountId" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiDelete8Opts struct { - IfMatch optional.String - AccountId optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Delete8(ctx context.Context, serviceIdentifier string, localVarOptionals *DefaultApiDelete8Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/services/{serviceIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"serviceIdentifier"+"}", fmt.Sprintf("%v", serviceIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param serviceIdentifier - * @param optional nil or *DefaultApiDelete9Opts - Optional Parameters: - * @param "IfMatch" (optional.String) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiDelete9Opts struct { - IfMatch optional.String - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Delete9(ctx context.Context, serviceIdentifier string, localVarOptionals *DefaultApiDelete9Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/servicesV2/{serviceIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"serviceIdentifier"+"}", fmt.Sprintf("%v", serviceIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param apiKeyType - * @param parentIdentifier - * @param identifier - * @param optional nil or *DefaultApiDeleteApiKeyOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiDeleteApiKeyOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) DeleteApiKey(ctx context.Context, accountIdentifier string, apiKeyType string, parentIdentifier string, identifier string, localVarOptionals *DefaultApiDeleteApiKeyOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/apikey/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - localVarQueryParams.Add("apiKeyType", parameterToString(apiKeyType, "")) - localVarQueryParams.Add("parentIdentifier", parameterToString(parentIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param identifier - * @param optional nil or *DefaultApiDeleteServiceAccountOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiDeleteServiceAccountOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) DeleteServiceAccount(ctx context.Context, accountIdentifier string, identifier string, localVarOptionals *DefaultApiDeleteServiceAccountOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/serviceaccount/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier - * @param apiKeyType - * @param parentIdentifier - * @param apiKeyIdentifier - * @param optional nil or *DefaultApiDeleteTokenOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiDeleteTokenOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) DeleteToken(ctx context.Context, identifier string, accountIdentifier string, apiKeyType string, parentIdentifier string, apiKeyIdentifier string, localVarOptionals *DefaultApiDeleteTokenOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/token/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - localVarQueryParams.Add("apiKeyType", parameterToString(apiKeyType, "")) - localVarQueryParams.Add("parentIdentifier", parameterToString(parentIdentifier, "")) - localVarQueryParams.Add("apiKeyIdentifier", parameterToString(apiKeyIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiDisableTFAOpts - Optional Parameters: - * @param "RoutingId" (optional.String) - -@return ResponseDtoUserInfo -*/ - -type DefaultApiDisableTFAOpts struct { - RoutingId optional.String -} - -func (a *DefaultApiService) DisableTFA(ctx context.Context, localVarOptionals *DefaultApiDisableTFAOpts) (ResponseDtoUserInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/disable-two-factor-auth" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.RoutingId.IsSet() { - localVarQueryParams.Add("routingId", parameterToString(localVarOptionals.RoutingId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). -@return ResponseDtoPipelineConfig -*/ -func (a *DefaultApiService) DummyApiForSwaggerSchemaCheck(ctx context.Context) (ResponseDtoPipelineConfig, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPipelineConfig - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/executions/dummyApiForSwaggerSchemaCheck" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPipelineConfig - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param accountIdentifier - * @param featureRestrictionName -@return ResponseDtoBoolean -*/ -func (a *DefaultApiService) EvaluateCustomFeatureRestriction(ctx context.Context, body CustomRestrictionEvaluationDto, accountIdentifier string, featureRestrictionName string) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/enforcement/client/custom/{featureRestrictionName}" - localVarPath = strings.Replace(localVarPath, "{"+"featureRestrictionName"+"}", fmt.Sprintf("%v", featureRestrictionName), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param type_ - * @param optional nil or *DefaultApiGetOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoFilterDto -*/ - -type DefaultApiGetOpts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Get(ctx context.Context, identifier string, type_ string, localVarOptionals *DefaultApiGetOpts) (ResponseDtoFilterDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoFilterDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/filters/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - localVarQueryParams.Add("type", parameterToString(type_, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoFilterDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param optional nil or *DefaultApiGet1Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoGitOpsProviderResponseDto -*/ - -type DefaultApiGet1Opts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Get1(ctx context.Context, identifier string, localVarOptionals *DefaultApiGet1Opts) (ResponseDtoGitOpsProviderResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGitOpsProviderResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/gitopsproviders/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGitOpsProviderResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param optional nil or *DefaultApiGet10Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoUserGroupDto -*/ - -type DefaultApiGet10Opts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Get10(ctx context.Context, identifier string, localVarOptionals *DefaultApiGet10Opts) (ResponseDtoUserGroupDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserGroupDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserGroupDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param serviceIdentifier - * @param optional nil or *DefaultApiGet11Opts - Optional Parameters: - * @param "AccountId" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Deleted" (optional.Bool) - -@return ResponseDtoServiceResponseDto -*/ - -type DefaultApiGet11Opts struct { - AccountId optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Deleted optional.Bool -} - -func (a *DefaultApiService) Get11(ctx context.Context, serviceIdentifier string, localVarOptionals *DefaultApiGet11Opts) (ResponseDtoServiceResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/services/{serviceIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"serviceIdentifier"+"}", fmt.Sprintf("%v", serviceIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Deleted.IsSet() { - localVarQueryParams.Add("deleted", parameterToString(localVarOptionals.Deleted.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param serviceIdentifier - * @param optional nil or *DefaultApiGet12Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Deleted" (optional.Bool) - -@return ResponseDtoServiceResponse -*/ - -type DefaultApiGet12Opts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Deleted optional.Bool -} - -func (a *DefaultApiService) Get12(ctx context.Context, serviceIdentifier string, localVarOptionals *DefaultApiGet12Opts) (ResponseDtoServiceResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/servicesV2/{serviceIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"serviceIdentifier"+"}", fmt.Sprintf("%v", serviceIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Deleted.IsSet() { - localVarQueryParams.Add("deleted", parameterToString(localVarOptionals.Deleted.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier -@return ResponseDtoListSourceCodeManagerDto -*/ -func (a *DefaultApiService) Get13(ctx context.Context, accountIdentifier string) (ResponseDtoListSourceCodeManagerDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListSourceCodeManagerDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/source-code-manager" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListSourceCodeManagerDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiGet2Opts - Optional Parameters: - * @param "ProjectIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoGitSyncSettingsDto -*/ - -type DefaultApiGet2Opts struct { - ProjectIdentifier optional.String - OrgIdentifier optional.String - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Get2(ctx context.Context, localVarOptionals *DefaultApiGet2Opts) (ResponseDtoGitSyncSettingsDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGitSyncSettingsDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-settings" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGitSyncSettingsDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiGet3Opts - Optional Parameters: - * @param "Body" (optional.Interface of RoleAssignmentFilter) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoPageResponseRoleAssignmentResponse -*/ - -type DefaultApiGet3Opts struct { - Body optional.Interface - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Get3(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiGet3Opts) (ResponseDtoPageResponseRoleAssignmentResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseRoleAssignmentResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/roleassignments/filter" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseRoleAssignmentResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param environmentIdentifier - * @param optional nil or *DefaultApiGet4Opts - Optional Parameters: - * @param "AccountId" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Deleted" (optional.Bool) - -@return ResponseDtoEnvironmentResponseDto -*/ - -type DefaultApiGet4Opts struct { - AccountId optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Deleted optional.Bool -} - -func (a *DefaultApiService) Get4(ctx context.Context, environmentIdentifier string, localVarOptionals *DefaultApiGet4Opts) (ResponseDtoEnvironmentResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEnvironmentResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environments/{environmentIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"environmentIdentifier"+"}", fmt.Sprintf("%v", environmentIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Deleted.IsSet() { - localVarQueryParams.Add("deleted", parameterToString(localVarOptionals.Deleted.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEnvironmentResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param environmentIdentifier - * @param optional nil or *DefaultApiGet5Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Deleted" (optional.Bool) - -@return ResponseDtoEnvironmentResponse -*/ - -type DefaultApiGet5Opts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Deleted optional.Bool -} - -func (a *DefaultApiService) Get5(ctx context.Context, environmentIdentifier string, localVarOptionals *DefaultApiGet5Opts) (ResponseDtoEnvironmentResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEnvironmentResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environmentsV2/{environmentIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"environmentIdentifier"+"}", fmt.Sprintf("%v", environmentIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Deleted.IsSet() { - localVarQueryParams.Add("deleted", parameterToString(localVarOptionals.Deleted.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEnvironmentResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). -@return ResponseDtoString -*/ -func (a *DefaultApiService) Get6(ctx context.Context) (ResponseDtoString, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoString - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/health" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoString - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier - * @param optional nil or *DefaultApiGet7Opts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - -@return ResponseDtoProjectAggregateDto -*/ - -type DefaultApiGet7Opts struct { - OrgIdentifier optional.String -} - -func (a *DefaultApiService) Get7(ctx context.Context, identifier string, accountIdentifier string, localVarOptionals *DefaultApiGet7Opts) (ResponseDtoProjectAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoProjectAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/aggregate/projects/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoProjectAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier -@return ResponseDtoOrganizationAggregateDto -*/ -func (a *DefaultApiService) Get8(ctx context.Context, identifier string, accountIdentifier string) (ResponseDtoOrganizationAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoOrganizationAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/aggregate/organizations/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoOrganizationAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier - * @param optional nil or *DefaultApiGet9Opts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoSecretResponseWrapper -*/ - -type DefaultApiGet9Opts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Get9(ctx context.Context, identifier string, accountIdentifier string, localVarOptionals *DefaultApiGet9Opts) (ResponseDtoSecretResponseWrapper, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSecretResponseWrapper - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSecretResponseWrapper - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiGetAccessibleProjectsCountOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "UserId" (optional.String) - - * @param "StartTime" (optional.Int64) - - * @param "EndTime" (optional.Int64) - -@return ResponseDtoActiveProjectsCountDto -*/ - -type DefaultApiGetAccessibleProjectsCountOpts struct { - AccountIdentifier optional.String - UserId optional.String - StartTime optional.Int64 - EndTime optional.Int64 -} - -func (a *DefaultApiService) GetAccessibleProjectsCount(ctx context.Context, localVarOptionals *DefaultApiGetAccessibleProjectsCountOpts) (ResponseDtoActiveProjectsCountDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoActiveProjectsCountDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/projects-count" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.UserId.IsSet() { - localVarQueryParams.Add("userId", parameterToString(localVarOptionals.UserId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.StartTime.IsSet() { - localVarQueryParams.Add("startTime", parameterToString(localVarOptionals.StartTime.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.EndTime.IsSet() { - localVarQueryParams.Add("endTime", parameterToString(localVarOptionals.EndTime.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoActiveProjectsCountDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier -@return ResponseDtoAccountLicense -*/ -func (a *DefaultApiService) GetAccountLicensesDTO(ctx context.Context, accountIdentifier string) (ResponseDtoAccountLicense, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoAccountLicense - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/admin/licenses/{accountIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"accountIdentifier"+"}", fmt.Sprintf("%v", accountIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoAccountLicense - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier -@return ResponseDtoAccountResourcesDto -*/ -func (a *DefaultApiService) GetAccountResourcesCount(ctx context.Context, accountIdentifier string) (ResponseDtoAccountResourcesDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoAccountResourcesDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/aggregate/account-resources" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoAccountResourcesDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgProjectIdentifiers -@return ResponseDtoPipelinesExecutionDashboardInfo -*/ -func (a *DefaultApiService) GetActiveDeploymentStats(ctx context.Context, accountIdentifier string, orgProjectIdentifiers []OrgProjectIdentifier) (ResponseDtoPipelinesExecutionDashboardInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPipelinesExecutionDashboardInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/landingDashboards/activeDeploymentStats" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgProjectIdentifiers", parameterToString(orgProjectIdentifiers, "multi")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPipelinesExecutionDashboardInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param serviceId - * @param envId - * @param buildIds -@return ResponseDtoInstancesByBuildIdList -*/ -func (a *DefaultApiService) GetActiveInstancesByServiceIdEnvIdAndBuildIds(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, serviceId string, envId string, buildIds []string) (ResponseDtoInstancesByBuildIdList, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoInstancesByBuildIdList - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/getInstancesByServiceEnvAndBuilds" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("serviceId", parameterToString(serviceId, "")) - localVarQueryParams.Add("envId", parameterToString(envId, "")) - localVarQueryParams.Add("buildIds", parameterToString(buildIds, "multi")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoInstancesByBuildIdList - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param serviceId -@return ResponseDtoInstanceCountDetailsByEnvTypeAndServiceId -*/ -func (a *DefaultApiService) GetActiveServiceInstanceCountBreakdown(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, serviceId []string) (ResponseDtoInstanceCountDetailsByEnvTypeAndServiceId, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoInstanceCountDetailsByEnvTypeAndServiceId - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/getInstanceCountDetailsByService" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("serviceId", parameterToString(serviceId, "multi")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoInstanceCountDetailsByEnvTypeAndServiceId - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param serviceId - * @param timestamp -@return ResponseDtoActiveServiceInstanceSummary -*/ -func (a *DefaultApiService) GetActiveServiceInstanceSummary(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, serviceId string, timestamp int64) (ResponseDtoActiveServiceInstanceSummary, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoActiveServiceInstanceSummary - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/getActiveServiceInstanceSummary" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("serviceId", parameterToString(serviceId, "")) - localVarQueryParams.Add("timestamp", parameterToString(timestamp, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoActiveServiceInstanceSummary - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgProjectIdentifiers - * @param startTime - * @param endTime - * @param sortBy -@return ResponseDtoServicesDashboardInfo -*/ -func (a *DefaultApiService) GetActiveServices(ctx context.Context, accountIdentifier string, orgProjectIdentifiers []OrgProjectIdentifier, startTime int64, endTime int64, sortBy string) (ResponseDtoServicesDashboardInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServicesDashboardInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/landingDashboards/activeServices" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgProjectIdentifiers", parameterToString(orgProjectIdentifiers, "multi")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - localVarQueryParams.Add("sortBy", parameterToString(sortBy, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServicesDashboardInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param startTime - * @param endTime - * @param timeGroupType - * @param referredEntityType - * @param optional nil or *DefaultApiGetActivitiesSummaryOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifier" (optional.String) - - * @param "ReferredByEntityType" (optional.String) - -@return ResponseDtoPageNgActivitySummaryDto -*/ - -type DefaultApiGetActivitiesSummaryOpts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifier optional.String - ReferredByEntityType optional.String -} - -func (a *DefaultApiService) GetActivitiesSummary(ctx context.Context, startTime int64, endTime int64, timeGroupType string, referredEntityType string, localVarOptionals *DefaultApiGetActivitiesSummaryOpts) (ResponseDtoPageNgActivitySummaryDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageNgActivitySummaryDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/activityHistory/summary" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Identifier.IsSet() { - localVarQueryParams.Add("identifier", parameterToString(localVarOptionals.Identifier.Value(), "")) - } - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - localVarQueryParams.Add("timeGroupType", parameterToString(timeGroupType, "")) - localVarQueryParams.Add("referredEntityType", parameterToString(referredEntityType, "")) - if localVarOptionals != nil && localVarOptionals.ReferredByEntityType.IsSet() { - localVarQueryParams.Add("referredByEntityType", parameterToString(localVarOptionals.ReferredByEntityType.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageNgActivitySummaryDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiGetAggregatedOpts - Optional Parameters: - * @param "Body" (optional.Interface of RoleAssignmentFilter) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoRoleAssignmentAggregateResponse -*/ - -type DefaultApiGetAggregatedOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) GetAggregated(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiGetAggregatedOpts) (ResponseDtoRoleAssignmentAggregateResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoRoleAssignmentAggregateResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/roleassignments/aggregate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoRoleAssignmentAggregateResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param apiKeyType - * @param parentIdentifier - * @param identifier - * @param optional nil or *DefaultApiGetAggregatedApiKeyOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoApiKeyAggregateDto -*/ - -type DefaultApiGetAggregatedApiKeyOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) GetAggregatedApiKey(ctx context.Context, accountIdentifier string, apiKeyType string, parentIdentifier string, identifier string, localVarOptionals *DefaultApiGetAggregatedApiKeyOpts) (ResponseDtoApiKeyAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoApiKeyAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/apikey/aggregate/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - localVarQueryParams.Add("apiKeyType", parameterToString(apiKeyType, "")) - localVarQueryParams.Add("parentIdentifier", parameterToString(parentIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoApiKeyAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param identifier - * @param optional nil or *DefaultApiGetAggregatedServiceAccountOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoServiceAccountAggregateDto -*/ - -type DefaultApiGetAggregatedServiceAccountOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) GetAggregatedServiceAccount(ctx context.Context, accountIdentifier string, identifier string, localVarOptionals *DefaultApiGetAggregatedServiceAccountOpts) (ResponseDtoServiceAccountAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceAccountAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/serviceaccount/aggregate/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceAccountAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param userId - * @param accountIdentifier - * @param optional nil or *DefaultApiGetAggregatedUserOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoUserAggregateDto -*/ - -type DefaultApiGetAggregatedUserOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) GetAggregatedUser(ctx context.Context, userId string, accountIdentifier string, localVarOptionals *DefaultApiGetAggregatedUserOpts) (ResponseDtoUserAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/aggregate/{userId}" - localVarPath = strings.Replace(localVarPath, "{"+"userId"+"}", fmt.Sprintf("%v", userId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiGetAggregatedUsersOpts - Optional Parameters: - * @param "Body" (optional.Interface of AclAggregateFilter) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - -@return ResponseDtoPageResponseUserAggregateDto -*/ - -type DefaultApiGetAggregatedUsersOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String - SearchTerm optional.String - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface -} - -func (a *DefaultApiService) GetAggregatedUsers(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiGetAggregatedUsersOpts) (ResponseDtoPageResponseUserAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseUserAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/aggregate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseUserAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param region - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier -@return ResponseDtoMapStringString -*/ -func (a *DefaultApiService) GetBuckets(ctx context.Context, region string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string) (ResponseDtoMapStringString, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoMapStringString - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/buckets/s3/getBuckets" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("region", parameterToString(region, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoMapStringString - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiGetBuildDetailsOpts - Optional Parameters: - * @param "ImagePath" (optional.String) - - * @param "ConnectorRef" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoDockerResponseDto -*/ - -type DefaultApiGetBuildDetailsOpts struct { - ImagePath optional.String - ConnectorRef optional.String - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) GetBuildDetails(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiGetBuildDetailsOpts) (ResponseDtoDockerResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoDockerResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/docker/getBuildDetails" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ImagePath.IsSet() { - localVarQueryParams.Add("imagePath", parameterToString(localVarOptionals.ImagePath.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ConnectorRef.IsSet() { - localVarQueryParams.Add("connectorRef", parameterToString(localVarOptionals.ConnectorRef.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoDockerResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param imagePath - * @param region - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiGetBuildDetails1Opts - Optional Parameters: - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoEcrResponseDto -*/ - -type DefaultApiGetBuildDetails1Opts struct { - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) GetBuildDetails1(ctx context.Context, imagePath string, region string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiGetBuildDetails1Opts) (ResponseDtoEcrResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEcrResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/ecr/getBuildDetails" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("region", parameterToString(region, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEcrResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param imagePath - * @param registryHostname - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiGetBuildDetails2Opts - Optional Parameters: - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoGcrResponseDto -*/ - -type DefaultApiGetBuildDetails2Opts struct { - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) GetBuildDetails2(ctx context.Context, imagePath string, registryHostname string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiGetBuildDetails2Opts) (ResponseDtoGcrResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGcrResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/gcr/getBuildDetails" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("registryHostname", parameterToString(registryHostname, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGcrResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param imagePath - * @param registryHostname - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param pipelineIdentifier - * @param fqnPath - * @param optional nil or *DefaultApiGetBuildDetails3Opts - Optional Parameters: - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoGcrResponseDto -*/ - -type DefaultApiGetBuildDetails3Opts struct { - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) GetBuildDetails3(ctx context.Context, body string, imagePath string, registryHostname string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string, pipelineIdentifier string, fqnPath string, localVarOptionals *DefaultApiGetBuildDetails3Opts) (ResponseDtoGcrResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGcrResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/gcr/getBuildDetailsV2" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("registryHostname", parameterToString(registryHostname, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("pipelineIdentifier", parameterToString(pipelineIdentifier, "")) - localVarQueryParams.Add("fqnPath", parameterToString(fqnPath, "")) - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGcrResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param pipelineIdentifier - * @param fqnPath - * @param optional nil or *DefaultApiGetBuildDetailsV2Opts - Optional Parameters: - * @param "ImagePath" (optional.String) - - * @param "ConnectorRef" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoDockerResponseDto -*/ - -type DefaultApiGetBuildDetailsV2Opts struct { - ImagePath optional.String - ConnectorRef optional.String - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) GetBuildDetailsV2(ctx context.Context, body string, accountIdentifier string, orgIdentifier string, projectIdentifier string, pipelineIdentifier string, fqnPath string, localVarOptionals *DefaultApiGetBuildDetailsV2Opts) (ResponseDtoDockerResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoDockerResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/docker/getBuildDetailsV2" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ImagePath.IsSet() { - localVarQueryParams.Add("imagePath", parameterToString(localVarOptionals.ImagePath.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ConnectorRef.IsSet() { - localVarQueryParams.Add("connectorRef", parameterToString(localVarOptionals.ConnectorRef.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("pipelineIdentifier", parameterToString(pipelineIdentifier, "")) - localVarQueryParams.Add("fqnPath", parameterToString(fqnPath, "")) - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoDockerResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param imagePath - * @param region - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param pipelineIdentifier - * @param fqnPath - * @param optional nil or *DefaultApiGetBuildDetailsV21Opts - Optional Parameters: - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoEcrResponseDto -*/ - -type DefaultApiGetBuildDetailsV21Opts struct { - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) GetBuildDetailsV21(ctx context.Context, body string, imagePath string, region string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string, pipelineIdentifier string, fqnPath string, localVarOptionals *DefaultApiGetBuildDetailsV21Opts) (ResponseDtoEcrResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEcrResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/ecr/getBuildDetailsV2" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("region", parameterToString(region, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("pipelineIdentifier", parameterToString(pipelineIdentifier, "")) - localVarQueryParams.Add("fqnPath", parameterToString(fqnPath, "")) - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEcrResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param startTime - * @param endTime - * @param optional nil or *DefaultApiGetConnectivitySummaryOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifier" (optional.String) - -@return ResponseDtoConnectivityCheckSummaryDto -*/ - -type DefaultApiGetConnectivitySummaryOpts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifier optional.String -} - -func (a *DefaultApiService) GetConnectivitySummary(ctx context.Context, startTime int64, endTime int64, localVarOptionals *DefaultApiGetConnectivitySummaryOpts) (ResponseDtoConnectivityCheckSummaryDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoConnectivityCheckSummaryDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/activityHistory/connectivityCheckSummary" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Identifier.IsSet() { - localVarQueryParams.Add("identifier", parameterToString(localVarOptionals.Identifier.Value(), "")) - } - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoConnectivityCheckSummaryDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiGetCurrentGenUsersOpts - Optional Parameters: - * @param "SearchString" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - -@return ResponseDtoPageResponseUserMetadataDto -*/ - -type DefaultApiGetCurrentGenUsersOpts struct { - SearchString optional.String - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface -} - -func (a *DefaultApiService) GetCurrentGenUsers(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiGetCurrentGenUsersOpts) (ResponseDtoPageResponseUserMetadataDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseUserMetadataDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/currentgen" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.SearchString.IsSet() { - localVarQueryParams.Add("searchString", parameterToString(localVarOptionals.SearchString.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseUserMetadataDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param startTime - * @param endTime -@return ResponseDtoExecutionDeploymentInfo -*/ -func (a *DefaultApiService) GetDeploymentExecution(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, startTime int64, endTime int64) (ResponseDtoExecutionDeploymentInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoExecutionDeploymentInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/deploymentExecution" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoExecutionDeploymentInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param startTime - * @param endTime - * @param optional nil or *DefaultApiGetDeploymentExecutionInfoOpts - Optional Parameters: - * @param "ServiceId" (optional.String) - - * @param "BucketSizeInDays" (optional.Int64) - -@return ResponseDtoServiceDeploymentListInfo -*/ - -type DefaultApiGetDeploymentExecutionInfoOpts struct { - ServiceId optional.String - BucketSizeInDays optional.Int64 -} - -func (a *DefaultApiService) GetDeploymentExecutionInfo(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, startTime int64, endTime int64, localVarOptionals *DefaultApiGetDeploymentExecutionInfoOpts) (ResponseDtoServiceDeploymentListInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceDeploymentListInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/serviceDeploymentsInfo" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - if localVarOptionals != nil && localVarOptionals.ServiceId.IsSet() { - localVarQueryParams.Add("serviceId", parameterToString(localVarOptionals.ServiceId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.BucketSizeInDays.IsSet() { - localVarQueryParams.Add("bucketSizeInDays", parameterToString(localVarOptionals.BucketSizeInDays.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceDeploymentListInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param startTime - * @param endTime -@return ResponseDtoHealthDeploymentDashboard -*/ -func (a *DefaultApiService) GetDeploymentHealth(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, startTime int64, endTime int64) (ResponseDtoHealthDeploymentDashboard, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoHealthDeploymentDashboard - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/deploymentHealth" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoHealthDeploymentDashboard - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgProjectIdentifiers - * @param startTime - * @param endTime - * @param groupBy -@return ResponseDtoDeploymentStatsSummary -*/ -func (a *DefaultApiService) GetDeploymentStatsSummary(ctx context.Context, accountIdentifier string, orgProjectIdentifiers []OrgProjectIdentifier, startTime int64, endTime int64, groupBy string) (ResponseDtoDeploymentStatsSummary, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoDeploymentStatsSummary - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/landingDashboards/deploymentStatsSummary" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgProjectIdentifiers", parameterToString(orgProjectIdentifiers, "multi")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - localVarQueryParams.Add("groupBy", parameterToString(groupBy, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoDeploymentStatsSummary - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiGetDeploymentsOpts - Optional Parameters: - * @param "Top" (optional.Int64) - -@return ResponseDtoDashboardExecutionStatusInfo -*/ - -type DefaultApiGetDeploymentsOpts struct { - Top optional.Int64 -} - -func (a *DefaultApiService) GetDeployments(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiGetDeploymentsOpts) (ResponseDtoDashboardExecutionStatusInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoDashboardExecutionStatusInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/getDeployments" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.Top.IsSet() { - localVarQueryParams.Add("top", parameterToString(localVarOptionals.Top.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoDashboardExecutionStatusInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param serviceId - * @param startTime - * @param endTime -@return ResponseDtoDeploymentsInfo -*/ -func (a *DefaultApiService) GetDeploymentsByServiceId(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, serviceId string, startTime int64, endTime int64) (ResponseDtoDeploymentsInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoDeploymentsInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/getDeploymentsByServiceId" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("serviceId", parameterToString(serviceId, "")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoDeploymentsInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). -@return ResponseDtocdPipelineModuleInfo -*/ -func (a *DefaultApiService) GetDummyCDPipelineModuleInfo(ctx context.Context) (ResponseDtocdPipelineModuleInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtocdPipelineModuleInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/executions/dummyCDPipelineModuleInfo" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtocdPipelineModuleInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). -@return ResponseDtocdStageModuleInfo -*/ -func (a *DefaultApiService) GetDummyCDStageModuleInfo(ctx context.Context) (ResponseDtocdStageModuleInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtocdStageModuleInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/executions/dummyCDStageModuleInfo" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtocdStageModuleInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body -@return ResponseDtoListEncryptedDataDetail -*/ -func (a *DefaultApiService) GetEncryptionDetails(ctx context.Context, body NgAccessWithEncryptionConsumer) (ResponseDtoListEncryptedDataDetail, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListEncryptedDataDetail - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/encryption-details" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/x-kryo"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/x-kryo"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListEncryptedDataDetail - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param serviceId -@return ResponseDtoEnvBuildIdAndInstanceCountInfoList -*/ -func (a *DefaultApiService) GetEnvBuildInstanceCount(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, serviceId string) (ResponseDtoEnvBuildIdAndInstanceCountInfoList, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEnvBuildIdAndInstanceCountInfoList - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/getEnvBuildInstanceCountByService" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("serviceId", parameterToString(serviceId, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEnvBuildIdAndInstanceCountInfoList - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgProjectIdentifiers - * @param startTime - * @param endTime -@return ResponseDtoEnvCount -*/ -func (a *DefaultApiService) GetEnvCount(ctx context.Context, accountIdentifier string, orgProjectIdentifiers []OrgProjectIdentifier, startTime int64, endTime int64) (ResponseDtoEnvCount, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEnvCount - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/landingDashboards/envCount" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgProjectIdentifiers", parameterToString(orgProjectIdentifiers, "multi")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEnvCount - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiGetErrorCountOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoGitSyncErrorCountDto -*/ - -type DefaultApiGetErrorCountOpts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - SearchTerm optional.String - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) GetErrorCount(ctx context.Context, localVarOptionals *DefaultApiGetErrorCountOpts) (ResponseDtoGitSyncErrorCountDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGitSyncErrorCountDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-errors/count" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGitSyncErrorCountDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). -@return ResponseDtoListExecutionStatus -*/ -func (a *DefaultApiService) GetExecutionStatuses(ctx context.Context) (ResponseDtoListExecutionStatus, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListExecutionStatus - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/executions/executionStatus" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListExecutionStatus - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). -@return ResponseDtoMapServiceDefinitionTypeListExecutionStrategyType -*/ -func (a *DefaultApiService) GetExecutionStrategyList(ctx context.Context) (ResponseDtoMapServiceDefinitionTypeListExecutionStrategyType, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoMapServiceDefinitionTypeListExecutionStrategyType - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/pipelines/configuration/strategies" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoMapServiceDefinitionTypeListExecutionStrategyType - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param serviceDefinitionType - * @param strategyType - * @param optional nil or *DefaultApiGetExecutionStrategyYamlOpts - Optional Parameters: - * @param "IncludeVerify" (optional.Bool) - -@return ResponseDtoString -*/ - -type DefaultApiGetExecutionStrategyYamlOpts struct { - IncludeVerify optional.Bool -} - -func (a *DefaultApiService) GetExecutionStrategyYaml(ctx context.Context, serviceDefinitionType string, strategyType string, localVarOptionals *DefaultApiGetExecutionStrategyYamlOpts) (ResponseDtoString, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoString - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/pipelines/configuration/strategies/yaml-snippets" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("serviceDefinitionType", parameterToString(serviceDefinitionType, "")) - localVarQueryParams.Add("strategyType", parameterToString(strategyType, "")) - if localVarOptionals != nil && localVarOptionals.IncludeVerify.IsSet() { - localVarQueryParams.Add("includeVerify", parameterToString(localVarOptionals.IncludeVerify.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoString - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param accountIdentifier - * @param featureRestrictionName -@return ResponseDtoFeatureRestrictionUsageDto -*/ -func (a *DefaultApiService) GetFeatureUsage(ctx context.Context, body RestrictionMetadataDto, accountIdentifier string, featureRestrictionName string) (ResponseDtoFeatureRestrictionUsageDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoFeatureRestrictionUsageDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/enforcement/client/usage/{featureRestrictionName}" - localVarPath = strings.Replace(localVarPath, "{"+"featureRestrictionName"+"}", fmt.Sprintf("%v", featureRestrictionName), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoFeatureRestrictionUsageDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param yamlGitConfigIdentifier - * @param accountIdentifier - * @param filePath - * @param optional nil or *DefaultApiGetFileContentOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "CommitId" (optional.String) - -@return ResponseDtoGitFileContent -*/ - -type DefaultApiGetFileContentOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - Branch optional.String - CommitId optional.String -} - -func (a *DefaultApiService) GetFileContent(ctx context.Context, yamlGitConfigIdentifier string, accountIdentifier string, filePath string, localVarOptionals *DefaultApiGetFileContentOpts) (ResponseDtoGitFileContent, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGitFileContent - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/scm/fileContent" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("yamlGitConfigIdentifier", parameterToString(yamlGitConfigIdentifier, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - localVarQueryParams.Add("filePath", parameterToString(filePath, "")) - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.CommitId.IsSet() { - localVarQueryParams.Add("commitId", parameterToString(localVarOptionals.CommitId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGitFileContent - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param region - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier -@return ResponseDtoEcrListImagesDto -*/ -func (a *DefaultApiService) GetImages(ctx context.Context, region string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string) (ResponseDtoEcrListImagesDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEcrListImagesDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/ecr/getImages" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("region", parameterToString(region, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEcrListImagesDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param serviceId - * @param startTime - * @param endTime -@return ResponseDtoTimeValuePairListDtoEnvIdCountPair -*/ -func (a *DefaultApiService) GetInstanceCountHistory(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, serviceId string, startTime int64, endTime int64) (ResponseDtoTimeValuePairListDtoEnvIdCountPair, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoTimeValuePairListDtoEnvIdCountPair - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/getInstanceCountHistory" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("serviceId", parameterToString(serviceId, "")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoTimeValuePairListDtoEnvIdCountPair - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param serviceId - * @param startTime - * @param endTime -@return ResponseDtoTimeValuePairListDtoInteger -*/ -func (a *DefaultApiService) GetInstanceGrowthTrend(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, serviceId string, startTime int64, endTime int64) (ResponseDtoTimeValuePairListDtoInteger, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoTimeValuePairListDtoInteger - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/getInstanceGrowthTrend" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("serviceId", parameterToString(serviceId, "")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoTimeValuePairListDtoInteger - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param instanceInfoPodName - * @param instanceInfoNamespace -@return ResponseDtoOptionalHarnessServiceInfoNg -*/ -func (a *DefaultApiService) GetInstanceNGData(ctx context.Context, accountIdentifier string, instanceInfoPodName string, instanceInfoNamespace string) (ResponseDtoOptionalHarnessServiceInfoNg, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoOptionalHarnessServiceInfoNg - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/instanceng" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("instanceInfoPodName", parameterToString(instanceInfoPodName, "")) - localVarQueryParams.Add("instanceInfoNamespace", parameterToString(instanceInfoNamespace, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoOptionalHarnessServiceInfoNg - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiGetInviteWithTokenOpts - Optional Parameters: - * @param "InviteId" (optional.String) - - * @param "Jwttoken" (optional.String) - -@return ResponseDtoInviteDto -*/ - -type DefaultApiGetInviteWithTokenOpts struct { - InviteId optional.String - Jwttoken optional.String -} - -func (a *DefaultApiService) GetInviteWithToken(ctx context.Context, localVarOptionals *DefaultApiGetInviteWithTokenOpts) (ResponseDtoInviteDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoInviteDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/invites/invite" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.InviteId.IsSet() { - localVarQueryParams.Add("inviteId", parameterToString(localVarOptionals.InviteId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Jwttoken.IsSet() { - localVarQueryParams.Add("jwttoken", parameterToString(localVarOptionals.Jwttoken.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoInviteDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiGetInvitesOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - -@return ResponseDtoPageResponseInviteDto -*/ - -type DefaultApiGetInvitesOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface -} - -func (a *DefaultApiService) GetInvites(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiGetInvitesOpts) (ResponseDtoPageResponseInviteDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseInviteDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/invites" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseInviteDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param connectorRef - * @param accountIdentifier - * @param optional nil or *DefaultApiGetIssueCreateMetadataOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "ProjectKey" (optional.String) - - * @param "IssueType" (optional.String) - - * @param "Expand" (optional.String) - - * @param "FetchStatus" (optional.Bool) - - * @param "IgnoreComment" (optional.Bool) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoJiraIssueCreateMetadataNg -*/ - -type DefaultApiGetIssueCreateMetadataOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - ProjectKey optional.String - IssueType optional.String - Expand optional.String - FetchStatus optional.Bool - IgnoreComment optional.Bool - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) GetIssueCreateMetadata(ctx context.Context, connectorRef string, accountIdentifier string, localVarOptionals *DefaultApiGetIssueCreateMetadataOpts) (ResponseDtoJiraIssueCreateMetadataNg, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoJiraIssueCreateMetadataNg - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/jira/createMetadata" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectKey.IsSet() { - localVarQueryParams.Add("projectKey", parameterToString(localVarOptionals.ProjectKey.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.IssueType.IsSet() { - localVarQueryParams.Add("issueType", parameterToString(localVarOptionals.IssueType.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Expand.IsSet() { - localVarQueryParams.Add("expand", parameterToString(localVarOptionals.Expand.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.FetchStatus.IsSet() { - localVarQueryParams.Add("fetchStatus", parameterToString(localVarOptionals.FetchStatus.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.IgnoreComment.IsSet() { - localVarQueryParams.Add("ignoreComment", parameterToString(localVarOptionals.IgnoreComment.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoJiraIssueCreateMetadataNg - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param connectorRef - * @param accountIdentifier - * @param optional nil or *DefaultApiGetIssueUpdateMetadataOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "IssueKey" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoJiraIssueUpdateMetadataNg -*/ - -type DefaultApiGetIssueUpdateMetadataOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - IssueKey optional.String - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) GetIssueUpdateMetadata(ctx context.Context, connectorRef string, accountIdentifier string, localVarOptionals *DefaultApiGetIssueUpdateMetadataOpts) (ResponseDtoJiraIssueUpdateMetadataNg, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoJiraIssueUpdateMetadataNg - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/jira/updateMetadata" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.IssueKey.IsSet() { - localVarQueryParams.Add("issueKey", parameterToString(localVarOptionals.IssueKey.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoJiraIssueUpdateMetadataNg - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiGetLabelsOpts - Optional Parameters: - * @param "Body" (optional.Interface of DockerRequestDto) - - * @param "ImagePath" (optional.String) - - * @param "ConnectorRef" (optional.String) - -@return ResponseDtoDockerResponseDto -*/ - -type DefaultApiGetLabelsOpts struct { - Body optional.Interface - ImagePath optional.String - ConnectorRef optional.String -} - -func (a *DefaultApiService) GetLabels(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiGetLabelsOpts) (ResponseDtoDockerResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoDockerResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/docker/getLabels" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ImagePath.IsSet() { - localVarQueryParams.Add("imagePath", parameterToString(localVarOptionals.ImagePath.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ConnectorRef.IsSet() { - localVarQueryParams.Add("connectorRef", parameterToString(localVarOptionals.ConnectorRef.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoDockerResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiGetLastSuccessfulBuildOpts - Optional Parameters: - * @param "Body" (optional.Interface of DockerRequestDto) - - * @param "ImagePath" (optional.String) - - * @param "ConnectorRef" (optional.String) - -@return ResponseDtoDockerBuildDetailsDto -*/ - -type DefaultApiGetLastSuccessfulBuildOpts struct { - Body optional.Interface - ImagePath optional.String - ConnectorRef optional.String -} - -func (a *DefaultApiService) GetLastSuccessfulBuild(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiGetLastSuccessfulBuildOpts) (ResponseDtoDockerBuildDetailsDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoDockerBuildDetailsDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/docker/getLastSuccessfulBuild" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ImagePath.IsSet() { - localVarQueryParams.Add("imagePath", parameterToString(localVarOptionals.ImagePath.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ConnectorRef.IsSet() { - localVarQueryParams.Add("connectorRef", parameterToString(localVarOptionals.ConnectorRef.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoDockerBuildDetailsDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param imagePath - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiGetLastSuccessfulBuild1Opts - Optional Parameters: - * @param "Body" (optional.Interface of EcrRequestDto) - -@return ResponseDtoEcrBuildDetailsDto -*/ - -type DefaultApiGetLastSuccessfulBuild1Opts struct { - Body optional.Interface -} - -func (a *DefaultApiService) GetLastSuccessfulBuild1(ctx context.Context, imagePath string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiGetLastSuccessfulBuild1Opts) (ResponseDtoEcrBuildDetailsDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEcrBuildDetailsDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/ecr/getLastSuccessfulBuild" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEcrBuildDetailsDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param imagePath - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiGetLastSuccessfulBuild2Opts - Optional Parameters: - * @param "Body" (optional.Interface of GcrRequestDto) - -@return ResponseDtoGcrBuildDetailsDto -*/ - -type DefaultApiGetLastSuccessfulBuild2Opts struct { - Body optional.Interface -} - -func (a *DefaultApiService) GetLastSuccessfulBuild2(ctx context.Context, imagePath string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiGetLastSuccessfulBuild2Opts) (ResponseDtoGcrBuildDetailsDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGcrBuildDetailsDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/gcr/getLastSuccessfulBuild" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGcrBuildDetailsDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiGetListBucketsOpts - Optional Parameters: - * @param "ConnectorRef" (optional.String) - -@return ResponseDtoMapStringString -*/ - -type DefaultApiGetListBucketsOpts struct { - ConnectorRef optional.String -} - -func (a *DefaultApiService) GetListBuckets(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiGetListBucketsOpts) (ResponseDtoMapStringString, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoMapStringString - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/buckets/gcs" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ConnectorRef.IsSet() { - localVarQueryParams.Add("connectorRef", parameterToString(localVarOptionals.ConnectorRef.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoMapStringString - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiGetPendingInvitesOpts - Optional Parameters: - * @param "Body" (optional.Interface of AclAggregateFilter) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - -@return ResponseDtoPageResponseInviteDto -*/ - -type DefaultApiGetPendingInvitesOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String - SearchTerm optional.String - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface -} - -func (a *DefaultApiService) GetPendingInvites(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiGetPendingInvitesOpts) (ResponseDtoPageResponseInviteDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseInviteDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/invites/aggregate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseInviteDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param connectorRef - * @param accountIdentifier - * @param optional nil or *DefaultApiGetProjectsOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoListJiraProjectBasicNg -*/ - -type DefaultApiGetProjectsOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) GetProjects(ctx context.Context, connectorRef string, accountIdentifier string, localVarOptionals *DefaultApiGetProjectsOpts) (ResponseDtoListJiraProjectBasicNg, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListJiraProjectBasicNg - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/jira/projects" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListJiraProjectBasicNg - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService Gets Yaml for Execution Strategy based on Provisioner Type - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param provisionerType -@return ResponseDtoString -*/ -func (a *DefaultApiService) GetProvisionerExecutionStrategyYaml(ctx context.Context, provisionerType string) (ResponseDtoString, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoString - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/pipelines/configuration/strategies/provisioner-yaml-snippets" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("provisionerType", parameterToString(provisionerType, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoString - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService Get provisioner steps - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). -@return ResponseDtoStepCategory -*/ -func (a *DefaultApiService) GetProvisionerSteps(ctx context.Context) (ResponseDtoStepCategory, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoStepCategory - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/pipelines/configuration/provisioner-steps" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoStepCategory - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiGetSchemaFileOpts - Optional Parameters: - * @param "Filename" (optional.String) - - -*/ - -type DefaultApiGetSchemaFileOpts struct { - Filename optional.String -} - -func (a *DefaultApiService) GetSchemaFile(ctx context.Context, localVarOptionals *DefaultApiGetSchemaFileOpts) (*http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/yamlschema/schemafile" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.Filename.IsSet() { - localVarQueryParams.Add("filename", parameterToString(localVarOptionals.Filename.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/octet-stream"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - return localVarHttpResponse, newErr - } - - return localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param accountIdentifier -@return ResponseDtoSecretManagerMetadataDto -*/ -func (a *DefaultApiService) GetSecretEngines(ctx context.Context, body SecretManagerMetadataRequestDto, accountIdentifier string) (ResponseDtoSecretManagerMetadataDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSecretManagerMetadataDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/secret-managers/meta-data" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSecretManagerMetadataDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier - * @param optional nil or *DefaultApiGetSecretManagerOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "MaskSecrets" (optional.Bool) - -@return ResponseDtoSecretManagerConfigDto -*/ - -type DefaultApiGetSecretManagerOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - MaskSecrets optional.Bool -} - -func (a *DefaultApiService) GetSecretManager(ctx context.Context, identifier string, accountIdentifier string, localVarOptionals *DefaultApiGetSecretManagerOpts) (ResponseDtoSecretManagerConfigDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSecretManagerConfigDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/secret-managers/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.MaskSecrets.IsSet() { - localVarQueryParams.Add("maskSecrets", parameterToString(localVarOptionals.MaskSecrets.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSecretManagerConfigDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). -@return ResponseDtoListServiceDefinitionType -*/ -func (a *DefaultApiService) GetServiceDefinitionTypes(ctx context.Context) (ResponseDtoListServiceDefinitionType, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListServiceDefinitionType - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/pipelines/configuration/serviceDefinitionTypes" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListServiceDefinitionType - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param startTime - * @param endTime - * @param optional nil or *DefaultApiGetServiceDeploymentOpts - Optional Parameters: - * @param "ServiceId" (optional.String) - - * @param "BucketSizeInDays" (optional.Int64) - -@return ResponseDtoServiceDeploymentInfoDto -*/ - -type DefaultApiGetServiceDeploymentOpts struct { - ServiceId optional.String - BucketSizeInDays optional.Int64 -} - -func (a *DefaultApiService) GetServiceDeployment(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, startTime int64, endTime int64, localVarOptionals *DefaultApiGetServiceDeploymentOpts) (ResponseDtoServiceDeploymentInfoDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceDeploymentInfoDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/serviceDeployments" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - if localVarOptionals != nil && localVarOptionals.ServiceId.IsSet() { - localVarQueryParams.Add("serviceId", parameterToString(localVarOptionals.ServiceId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.BucketSizeInDays.IsSet() { - localVarQueryParams.Add("bucketSizeInDays", parameterToString(localVarOptionals.BucketSizeInDays.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceDeploymentInfoDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param startTime - * @param endTime -@return ResponseDtoServiceDetailsInfoDto -*/ -func (a *DefaultApiService) GetServiceDeployments(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, startTime int64, endTime int64) (ResponseDtoServiceDetailsInfoDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceDetailsInfoDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/serviceDetails" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceDetailsInfoDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param serviceId -@return ResponseDtoServiceHeaderInfo -*/ -func (a *DefaultApiService) GetServiceHeaderInfo(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, serviceId string) (ResponseDtoServiceHeaderInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceHeaderInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/getServiceHeaderInfo" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("serviceId", parameterToString(serviceId, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceHeaderInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgProjectIdentifiers - * @param startTime - * @param endTime -@return ResponseDtoServicesCount -*/ -func (a *DefaultApiService) GetServicesCount(ctx context.Context, accountIdentifier string, orgProjectIdentifiers []OrgProjectIdentifier, startTime int64, endTime int64) (ResponseDtoServicesCount, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServicesCount - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/landingDashboards/servicesCount" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgProjectIdentifiers", parameterToString(orgProjectIdentifiers, "multi")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServicesCount - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param startTime - * @param endTime - * @param timeGroupByType -@return ResponseDtoTimeValuePairListDtoInteger -*/ -func (a *DefaultApiService) GetServicesGrowthTrend(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, startTime int64, endTime int64, timeGroupByType string) (ResponseDtoTimeValuePairListDtoInteger, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoTimeValuePairListDtoInteger - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/getServicesGrowthTrend" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - localVarQueryParams.Add("timeGroupByType", parameterToString(timeGroupByType, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoTimeValuePairListDtoInteger - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param connectorRef - * @param accountIdentifier - * @param optional nil or *DefaultApiGetStatusesOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "ProjectKey" (optional.String) - - * @param "IssueType" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoListJiraStatusNg -*/ - -type DefaultApiGetStatusesOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - ProjectKey optional.String - IssueType optional.String - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) GetStatuses(ctx context.Context, connectorRef string, accountIdentifier string, localVarOptionals *DefaultApiGetStatusesOpts) (ResponseDtoListJiraStatusNg, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListJiraStatusNg - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/jira/statuses" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectKey.IsSet() { - localVarQueryParams.Add("projectKey", parameterToString(localVarOptionals.ProjectKey.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.IssueType.IsSet() { - localVarQueryParams.Add("issueType", parameterToString(localVarOptionals.IssueType.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListJiraStatusNg - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param serviceDefinitionType -@return ResponseDtoStepCategory -*/ -func (a *DefaultApiService) GetSteps(ctx context.Context, serviceDefinitionType string) (ResponseDtoStepCategory, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoStepCategory - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/pipelines/configuration/steps" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("serviceDefinitionType", parameterToString(serviceDefinitionType, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoStepCategory - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiGetTokenOpts - Optional Parameters: - * @param "TokenId" (optional.String) - -@return ResponseDtoTokenDto -*/ - -type DefaultApiGetTokenOpts struct { - TokenId optional.String -} - -func (a *DefaultApiService) GetToken(ctx context.Context, localVarOptionals *DefaultApiGetTokenOpts) (ResponseDtoTokenDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoTokenDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/token" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.TokenId.IsSet() { - localVarQueryParams.Add("tokenId", parameterToString(localVarOptionals.TokenId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoTokenDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgProjectIdentifiers - * @param startTime - * @param endTime -@return ResponseDtoProjectsDashboardInfo -*/ -func (a *DefaultApiService) GetTopProjects(ctx context.Context, accountIdentifier string, orgProjectIdentifiers []OrgProjectIdentifier, startTime int64, endTime int64) (ResponseDtoProjectsDashboardInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoProjectsDashboardInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/landingDashboards/topProjects" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgProjectIdentifiers", parameterToString(orgProjectIdentifiers, "multi")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoProjectsDashboardInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param authMechanism -@return ResponseDtoTwoFactorAuthSettingsInfo -*/ -func (a *DefaultApiService) GetTwoFactorAuthSettingsInfo(ctx context.Context, authMechanism string) (ResponseDtoTwoFactorAuthSettingsInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoTwoFactorAuthSettingsInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/two-factor-auth/{authMechanism}" - localVarPath = strings.Replace(localVarPath, "{"+"authMechanism"+"}", fmt.Sprintf("%v", authMechanism), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoTwoFactorAuthSettingsInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiGetUserAllProjectsInfoOpts - Optional Parameters: - * @param "AccountId" (optional.String) - - * @param "UserId" (optional.String) - -@return ResponseDtoListProject -*/ - -type DefaultApiGetUserAllProjectsInfoOpts struct { - AccountId optional.String - UserId optional.String -} - -func (a *DefaultApiService) GetUserAllProjectsInfo(ctx context.Context, localVarOptionals *DefaultApiGetUserAllProjectsInfoOpts) (ResponseDtoListProject, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListProject - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/all-projects" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.UserId.IsSet() { - localVarQueryParams.Add("userId", parameterToString(localVarOptionals.UserId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListProject - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). -@return ResponseDtoUserInfo -*/ -func (a *DefaultApiService) GetUserInfo(ctx context.Context) (ResponseDtoUserInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/currentUser" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiGetUserProjectInfoOpts - Optional Parameters: - * @param "AccountId" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - -@return ResponseDtoPageResponseProject -*/ - -type DefaultApiGetUserProjectInfoOpts struct { - AccountId optional.String - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface -} - -func (a *DefaultApiService) GetUserProjectInfo(ctx context.Context, localVarOptionals *DefaultApiGetUserProjectInfoOpts) (ResponseDtoPageResponseProject, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseProject - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/projects" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseProject - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiGetUsersOpts - Optional Parameters: - * @param "Body" (optional.Interface of UserFilter) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - -@return ResponseDtoPageResponseUserMetadataDto -*/ - -type DefaultApiGetUsersOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface -} - -func (a *DefaultApiService) GetUsers(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiGetUsersOpts) (ResponseDtoPageResponseUserMetadataDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseUserMetadataDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/batch" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseUserMetadataDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param identifier - * @param optional nil or *DefaultApiGetUsersInUserGroupOpts - Optional Parameters: - * @param "Body" (optional.Interface of UserFilter) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - -@return ResponseDtoPageResponseUserMetadataDto -*/ - -type DefaultApiGetUsersInUserGroupOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface -} - -func (a *DefaultApiService) GetUsersInUserGroup(ctx context.Context, accountIdentifier string, identifier string, localVarOptionals *DefaultApiGetUsersInUserGroupOpts) (ResponseDtoPageResponseUserMetadataDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseUserMetadataDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups/{identifier}/users" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseUserMetadataDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param startTime - * @param endTime - * @param optional nil or *DefaultApiGetWorkloadsOpts - Optional Parameters: - * @param "EnvironmentType" (optional.String) - -@return ResponseDtoDashboardWorkloadDeployment -*/ - -type DefaultApiGetWorkloadsOpts struct { - EnvironmentType optional.String -} - -func (a *DefaultApiService) GetWorkloads(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, startTime int64, endTime int64, localVarOptionals *DefaultApiGetWorkloadsOpts) (ResponseDtoDashboardWorkloadDeployment, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoDashboardWorkloadDeployment - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/dashboard/getWorkloads" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - if localVarOptionals != nil && localVarOptionals.EnvironmentType.IsSet() { - localVarQueryParams.Add("environmentType", parameterToString(localVarOptionals.EnvironmentType.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoDashboardWorkloadDeployment - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiGetYamlSchemaOpts - Optional Parameters: - * @param "ProjectIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "Scope" (optional.String) - -@return ResponseDtoPartialSchemaDto -*/ - -type DefaultApiGetYamlSchemaOpts struct { - ProjectIdentifier optional.String - OrgIdentifier optional.String - Scope optional.String -} - -func (a *DefaultApiService) GetYamlSchema(ctx context.Context, localVarOptionals *DefaultApiGetYamlSchemaOpts) (ResponseDtoPartialSchemaDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPartialSchemaDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/partial-yaml-schema" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Scope.IsSet() { - localVarQueryParams.Add("scope", parameterToString(localVarOptionals.Scope.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPartialSchemaDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param entityType - * @param optional nil or *DefaultApiGetYamlSchema1Opts - Optional Parameters: - * @param "Subtype" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "Scope" (optional.String) - - * @param "Identifier" (optional.String) - -@return ResponseDtoJsonNode -*/ - -type DefaultApiGetYamlSchema1Opts struct { - Subtype optional.String - ProjectIdentifier optional.String - OrgIdentifier optional.String - Scope optional.String - Identifier optional.String -} - -func (a *DefaultApiService) GetYamlSchema1(ctx context.Context, entityType string, localVarOptionals *DefaultApiGetYamlSchema1Opts) (ResponseDtoJsonNode, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoJsonNode - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/yaml-schema" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("entityType", parameterToString(entityType, "")) - if localVarOptionals != nil && localVarOptionals.Subtype.IsSet() { - localVarQueryParams.Add("subtype", parameterToString(localVarOptionals.Subtype.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Scope.IsSet() { - localVarQueryParams.Add("scope", parameterToString(localVarOptionals.Scope.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Identifier.IsSet() { - localVarQueryParams.Add("identifier", parameterToString(localVarOptionals.Identifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoJsonNode - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param optional nil or *DefaultApiGetYamlSnippetOpts - Optional Parameters: - * @param "ProjectIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "Scope" (optional.String) - -@return ResponseDtoJsonNode -*/ - -type DefaultApiGetYamlSnippetOpts struct { - ProjectIdentifier optional.String - OrgIdentifier optional.String - Scope optional.String -} - -func (a *DefaultApiService) GetYamlSnippet(ctx context.Context, identifier string, localVarOptionals *DefaultApiGetYamlSnippetOpts) (ResponseDtoJsonNode, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoJsonNode - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/yaml-snippet/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Scope.IsSet() { - localVarQueryParams.Add("scope", parameterToString(localVarOptionals.Scope.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoJsonNode - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param tags -@return ResponseDtoYamlSnippetsDto -*/ -func (a *DefaultApiService) GetYamlSnippetsMetaData(ctx context.Context, tags []string) (ResponseDtoYamlSnippetsDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoYamlSnippetsDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/yaml-snippet" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("tags", parameterToString(tags, "multi")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoYamlSnippetsDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiIsEntityReferencedOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "ReferredEntityFQN" (optional.String) - - * @param "ReferredEntityType" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiIsEntityReferencedOpts struct { - AccountIdentifier optional.String - ReferredEntityFQN optional.String - ReferredEntityType optional.String -} - -func (a *DefaultApiService) IsEntityReferenced(ctx context.Context, localVarOptionals *DefaultApiIsEntityReferencedOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/entitySetupUsage/internal/isEntityReferenced" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ReferredEntityFQN.IsSet() { - localVarQueryParams.Add("referredEntityFQN", parameterToString(localVarOptionals.ReferredEntityFQN.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ReferredEntityType.IsSet() { - localVarQueryParams.Add("referredEntityType", parameterToString(localVarOptionals.ReferredEntityType.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiIsGitSyncEnabledOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - -@return GitEnabledDto -*/ - -type DefaultApiIsGitSyncEnabledOpts struct { - AccountIdentifier optional.String - ProjectIdentifier optional.String - OrgIdentifier optional.String -} - -func (a *DefaultApiService) IsGitSyncEnabled(ctx context.Context, localVarOptionals *DefaultApiIsGitSyncEnabledOpts) (GitEnabledDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue GitEnabledDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync/git-sync-enabled" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v GitEnabledDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiIsSaasGitOpts - Optional Parameters: - * @param "RepoURL" (optional.String) - -@return ResponseDtoSaasGitDto -*/ - -type DefaultApiIsSaasGitOpts struct { - RepoURL optional.String -} - -func (a *DefaultApiService) IsSaasGit(ctx context.Context, localVarOptionals *DefaultApiIsSaasGitOpts) (ResponseDtoSaasGitDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSaasGitDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/scm/isSaasGit" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.RepoURL.IsSet() { - localVarQueryParams.Add("repoURL", parameterToString(localVarOptionals.RepoURL.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSaasGitDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param accountIdentifier - * @param userGroupId - * @param samlId - * @param optional nil or *DefaultApiLinkToSamlGroupOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return RestResponseUserGroup -*/ - -type DefaultApiLinkToSamlGroupOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) LinkToSamlGroup(ctx context.Context, body SamlLinkGroupRequest, accountIdentifier string, userGroupId string, samlId string, localVarOptionals *DefaultApiLinkToSamlGroupOpts) (RestResponseUserGroup, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RestResponseUserGroup - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups/{userGroupId}/link/saml/{samlId}" - localVarPath = strings.Replace(localVarPath, "{"+"userGroupId"+"}", fmt.Sprintf("%v", userGroupId), -1) - localVarPath = strings.Replace(localVarPath, "{"+"samlId"+"}", fmt.Sprintf("%v", samlId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v RestResponseUserGroup - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param type_ - * @param optional nil or *DefaultApiListOpts - Optional Parameters: - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoPageResponseFilterDto -*/ - -type DefaultApiListOpts struct { - PageIndex optional.Int32 - PageSize optional.Int32 - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) List(ctx context.Context, accountIdentifier string, type_ string, localVarOptionals *DefaultApiListOpts) (ResponseDtoPageResponseFilterDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseFilterDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/filters" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - localVarQueryParams.Add("type", parameterToString(type_, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseFilterDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiList1Opts - Optional Parameters: - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "Sort" (optional.Interface of []string) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "Type_" (optional.String) - -@return ResponseDtoPageResponseGitOpsProviderResponseDto -*/ - -type DefaultApiList1Opts struct { - PageIndex optional.Int32 - PageSize optional.Int32 - Sort optional.Interface - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - SearchTerm optional.String - Type_ optional.String -} - -func (a *DefaultApiService) List1(ctx context.Context, localVarOptionals *DefaultApiList1Opts) (ResponseDtoPageResponseGitOpsProviderResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseGitOpsProviderResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/gitopsproviders/list" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { - localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Type_.IsSet() { - localVarQueryParams.Add("type", parameterToString(localVarOptionals.Type_.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseGitOpsProviderResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiList10Opts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifiers" (optional.Interface of []string) - - * @param "Type_" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "Types" (optional.Interface of []string) - - * @param "SourceCategory" (optional.String) - - * @param "IncludeSecretsFromEverySubScope" (optional.Bool) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - -@return ResponseDtoPageResponseSecretResponseWrapper -*/ - -type DefaultApiList10Opts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifiers optional.Interface - Type_ optional.String - SearchTerm optional.String - Types optional.Interface - SourceCategory optional.String - IncludeSecretsFromEverySubScope optional.Bool - PageIndex optional.Int32 - PageSize optional.Int32 -} - -func (a *DefaultApiService) List10(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiList10Opts) (ResponseDtoPageResponseSecretResponseWrapper, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseSecretResponseWrapper - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Identifiers.IsSet() { - localVarQueryParams.Add("identifiers", parameterToString(localVarOptionals.Identifiers.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.Type_.IsSet() { - localVarQueryParams.Add("type", parameterToString(localVarOptionals.Type_.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Types.IsSet() { - localVarQueryParams.Add("types", parameterToString(localVarOptionals.Types.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.SourceCategory.IsSet() { - localVarQueryParams.Add("source_category", parameterToString(localVarOptionals.SourceCategory.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.IncludeSecretsFromEverySubScope.IsSet() { - localVarQueryParams.Add("includeSecretsFromEverySubScope", parameterToString(localVarOptionals.IncludeSecretsFromEverySubScope.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseSecretResponseWrapper - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body -@return ResponseDtoListUserGroupDto -*/ -func (a *DefaultApiService) List11(ctx context.Context, body UserGroupFilterDto) (ResponseDtoListUserGroupDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListUserGroupDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups/batch" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListUserGroupDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiList12Opts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - -@return ResponseDtoPageResponseUserGroupDto -*/ - -type DefaultApiList12Opts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - SearchTerm optional.String - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface -} - -func (a *DefaultApiService) List12(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiList12Opts) (ResponseDtoPageResponseUserGroupDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseUserGroupDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseUserGroupDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiList2Opts - Optional Parameters: - * @param "ProjectIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "AccountIdentifier" (optional.String) - -@return []GitSyncConfigDto -*/ - -type DefaultApiList2Opts struct { - ProjectIdentifier optional.String - OrgIdentifier optional.String - AccountIdentifier optional.String -} - -func (a *DefaultApiService) List2(ctx context.Context, localVarOptionals *DefaultApiList2Opts) ([]GitSyncConfigDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue []GitSyncConfigDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v []GitSyncConfigDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param startTime - * @param endTime - * @param referredEntityType - * @param optional nil or *DefaultApiList3Opts - Optional Parameters: - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifier" (optional.String) - - * @param "Status" (optional.String) - - * @param "ReferredByEntityType" (optional.String) - -@return ResponseDtoPageNgActivityDto -*/ - -type DefaultApiList3Opts struct { - PageIndex optional.Int32 - PageSize optional.Int32 - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifier optional.String - Status optional.String - ReferredByEntityType optional.String -} - -func (a *DefaultApiService) List3(ctx context.Context, startTime int64, endTime int64, referredEntityType string, localVarOptionals *DefaultApiList3Opts) (ResponseDtoPageNgActivityDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageNgActivityDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/activityHistory" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Identifier.IsSet() { - localVarQueryParams.Add("identifier", parameterToString(localVarOptionals.Identifier.Value(), "")) - } - localVarQueryParams.Add("startTime", parameterToString(startTime, "")) - localVarQueryParams.Add("endTime", parameterToString(endTime, "")) - if localVarOptionals != nil && localVarOptionals.Status.IsSet() { - localVarQueryParams.Add("status", parameterToString(localVarOptionals.Status.Value(), "")) - } - localVarQueryParams.Add("referredEntityType", parameterToString(referredEntityType, "")) - if localVarOptionals != nil && localVarOptionals.ReferredByEntityType.IsSet() { - localVarQueryParams.Add("referredByEntityType", parameterToString(localVarOptionals.ReferredByEntityType.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageNgActivityDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiList4Opts - Optional Parameters: - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifier" (optional.String) - - * @param "ReferredEntityType" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoPageEntitySetupUsageDto -*/ - -type DefaultApiList4Opts struct { - PageIndex optional.Int32 - PageSize optional.Int32 - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifier optional.String - ReferredEntityType optional.String - SearchTerm optional.String - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) List4(ctx context.Context, localVarOptionals *DefaultApiList4Opts) (ResponseDtoPageEntitySetupUsageDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageEntitySetupUsageDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/entitySetupUsage" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Identifier.IsSet() { - localVarQueryParams.Add("identifier", parameterToString(localVarOptionals.Identifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ReferredEntityType.IsSet() { - localVarQueryParams.Add("referredEntityType", parameterToString(localVarOptionals.ReferredEntityType.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageEntitySetupUsageDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiList5Opts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - - * @param "SearchTerm" (optional.String) - - * @param "UserSize" (optional.Int32) - -@return ResponseDtoPageResponseUserGroupAggregateDto -*/ - -type DefaultApiList5Opts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface - SearchTerm optional.String - UserSize optional.Int32 -} - -func (a *DefaultApiService) List5(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiList5Opts) (ResponseDtoPageResponseUserGroupAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseUserGroupAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/aggregate/acl/usergroups" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.UserSize.IsSet() { - localVarQueryParams.Add("userSize", parameterToString(localVarOptionals.UserSize.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseUserGroupAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiList6Opts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "HasModule" (optional.Bool) - - * @param "ModuleType" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - -@return ResponseDtoPageResponseProjectAggregateDto -*/ - -type DefaultApiList6Opts struct { - OrgIdentifier optional.String - HasModule optional.Bool - ModuleType optional.String - SearchTerm optional.String - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface -} - -func (a *DefaultApiService) List6(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiList6Opts) (ResponseDtoPageResponseProjectAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseProjectAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/aggregate/projects" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.HasModule.IsSet() { - localVarQueryParams.Add("hasModule", parameterToString(localVarOptionals.HasModule.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ModuleType.IsSet() { - localVarQueryParams.Add("moduleType", parameterToString(localVarOptionals.ModuleType.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseProjectAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiList7Opts - Optional Parameters: - * @param "Body" (optional.Interface of AggregateAclRequest) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoListUserGroupAggregateDto -*/ - -type DefaultApiList7Opts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) List7(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiList7Opts) (ResponseDtoListUserGroupAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListUserGroupAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/aggregate/acl/usergroups/filter" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListUserGroupAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiList8Opts - Optional Parameters: - * @param "SearchTerm" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - -@return ResponseDtoPageResponseOrganizationAggregateDto -*/ - -type DefaultApiList8Opts struct { - SearchTerm optional.String - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface -} - -func (a *DefaultApiService) List8(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiList8Opts) (ResponseDtoPageResponseOrganizationAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseOrganizationAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/aggregate/organizations" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseOrganizationAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier - * @param optional nil or *DefaultApiList9Opts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoUserGroupAggregateDto -*/ - -type DefaultApiList9Opts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) List9(ctx context.Context, identifier string, accountIdentifier string, localVarOptionals *DefaultApiList9Opts) (ResponseDtoUserGroupAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserGroupAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/aggregate/acl/usergroups/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserGroupAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListAccessEnvironmentOpts - Optional Parameters: - * @param "Page" (optional.Int32) - - * @param "Size" (optional.Int32) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "EnvIdentifiers" (optional.Interface of []string) - - * @param "Sort" (optional.Interface of []string) - -@return ResponseDtoListEnvironmentResponse -*/ - -type DefaultApiListAccessEnvironmentOpts struct { - Page optional.Int32 - Size optional.Int32 - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - SearchTerm optional.String - EnvIdentifiers optional.Interface - Sort optional.Interface -} - -func (a *DefaultApiService) ListAccessEnvironment(ctx context.Context, localVarOptionals *DefaultApiListAccessEnvironmentOpts) (ResponseDtoListEnvironmentResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListEnvironmentResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environmentsV2/list/access" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.Page.IsSet() { - localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.EnvIdentifiers.IsSet() { - localVarQueryParams.Add("envIdentifiers", parameterToString(localVarOptionals.EnvIdentifiers.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { - localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListEnvironmentResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListAccessServicesOpts - Optional Parameters: - * @param "Page" (optional.Int32) - - * @param "Size" (optional.Int32) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "ServiceIdentifiers" (optional.Interface of []string) - - * @param "Sort" (optional.Interface of []string) - -@return ResponseDtoListServiceResponse -*/ - -type DefaultApiListAccessServicesOpts struct { - Page optional.Int32 - Size optional.Int32 - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - SearchTerm optional.String - ServiceIdentifiers optional.Interface - Sort optional.Interface -} - -func (a *DefaultApiService) ListAccessServices(ctx context.Context, localVarOptionals *DefaultApiListAccessServicesOpts) (ResponseDtoListServiceResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/servicesV2/list/access" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.Page.IsSet() { - localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ServiceIdentifiers.IsSet() { - localVarQueryParams.Add("serviceIdentifiers", parameterToString(localVarOptionals.ServiceIdentifiers.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { - localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListServiceResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param apiKeyType - * @param parentIdentifier - * @param optional nil or *DefaultApiListAggregatedApiKeysOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifiers" (optional.Interface of []string) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - - * @param "SearchTerm" (optional.String) - -@return ResponseDtoPageResponseApiKeyAggregateDto -*/ - -type DefaultApiListAggregatedApiKeysOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifiers optional.Interface - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface - SearchTerm optional.String -} - -func (a *DefaultApiService) ListAggregatedApiKeys(ctx context.Context, accountIdentifier string, apiKeyType string, parentIdentifier string, localVarOptionals *DefaultApiListAggregatedApiKeysOpts) (ResponseDtoPageResponseApiKeyAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseApiKeyAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/apikey/aggregate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - localVarQueryParams.Add("apiKeyType", parameterToString(apiKeyType, "")) - localVarQueryParams.Add("parentIdentifier", parameterToString(parentIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.Identifiers.IsSet() { - localVarQueryParams.Add("identifiers", parameterToString(localVarOptionals.Identifiers.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseApiKeyAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiListAggregatedServiceAccountsOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifiers" (optional.Interface of []string) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - - * @param "SearchTerm" (optional.String) - -@return ResponseDtoPageResponseServiceAccountAggregateDto -*/ - -type DefaultApiListAggregatedServiceAccountsOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifiers optional.Interface - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface - SearchTerm optional.String -} - -func (a *DefaultApiService) ListAggregatedServiceAccounts(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiListAggregatedServiceAccountsOpts) (ResponseDtoPageResponseServiceAccountAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseServiceAccountAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/serviceaccount/aggregate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Identifiers.IsSet() { - localVarQueryParams.Add("identifiers", parameterToString(localVarOptionals.Identifiers.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseServiceAccountAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param apiKeyType - * @param parentIdentifier - * @param apiKeyIdentifier - * @param optional nil or *DefaultApiListAggregatedTokensOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifiers" (optional.Interface of []string) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - - * @param "SearchTerm" (optional.String) - -@return ResponseDtoPageResponseTokenAggregateDto -*/ - -type DefaultApiListAggregatedTokensOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifiers optional.Interface - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface - SearchTerm optional.String -} - -func (a *DefaultApiService) ListAggregatedTokens(ctx context.Context, accountIdentifier string, apiKeyType string, parentIdentifier string, apiKeyIdentifier string, localVarOptionals *DefaultApiListAggregatedTokensOpts) (ResponseDtoPageResponseTokenAggregateDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseTokenAggregateDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/token/aggregate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - localVarQueryParams.Add("apiKeyType", parameterToString(apiKeyType, "")) - localVarQueryParams.Add("parentIdentifier", parameterToString(parentIdentifier, "")) - localVarQueryParams.Add("apiKeyIdentifier", parameterToString(apiKeyIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.Identifiers.IsSet() { - localVarQueryParams.Add("identifiers", parameterToString(localVarOptionals.Identifiers.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseTokenAggregateDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListAllEntityUsageOpts - Optional Parameters: - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "AccountIdentifier" (optional.String) - - * @param "ReferredEntityFQN" (optional.String) - - * @param "ReferredEntityType" (optional.String) - - * @param "SearchTerm" (optional.String) - -@return ResponseDtoPageEntitySetupUsageDto -*/ - -type DefaultApiListAllEntityUsageOpts struct { - PageIndex optional.Int32 - PageSize optional.Int32 - AccountIdentifier optional.String - ReferredEntityFQN optional.String - ReferredEntityType optional.String - SearchTerm optional.String -} - -func (a *DefaultApiService) ListAllEntityUsage(ctx context.Context, localVarOptionals *DefaultApiListAllEntityUsageOpts) (ResponseDtoPageEntitySetupUsageDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageEntitySetupUsageDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/entitySetupUsage/internal" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ReferredEntityFQN.IsSet() { - localVarQueryParams.Add("referredEntityFQN", parameterToString(localVarOptionals.ReferredEntityFQN.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ReferredEntityType.IsSet() { - localVarQueryParams.Add("referredEntityType", parameterToString(localVarOptionals.ReferredEntityType.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageEntitySetupUsageDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListAllReferredUsagesOpts - Optional Parameters: - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "AccountIdentifier" (optional.String) - - * @param "ReferredByEntityFQN" (optional.String) - - * @param "ReferredEntityType" (optional.String) - - * @param "SearchTerm" (optional.String) - -@return ResponseDtoListEntitySetupUsageDto -*/ - -type DefaultApiListAllReferredUsagesOpts struct { - PageIndex optional.Int32 - PageSize optional.Int32 - AccountIdentifier optional.String - ReferredByEntityFQN optional.String - ReferredEntityType optional.String - SearchTerm optional.String -} - -func (a *DefaultApiService) ListAllReferredUsages(ctx context.Context, localVarOptionals *DefaultApiListAllReferredUsagesOpts) (ResponseDtoListEntitySetupUsageDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListEntitySetupUsageDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/entitySetupUsage/internal/listAllReferredUsages" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ReferredByEntityFQN.IsSet() { - localVarQueryParams.Add("referredByEntityFQN", parameterToString(localVarOptionals.ReferredByEntityFQN.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ReferredEntityType.IsSet() { - localVarQueryParams.Add("referredEntityType", parameterToString(localVarOptionals.ReferredEntityType.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListEntitySetupUsageDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param referredByEntityType - * @param referredEntityType - * @param optional nil or *DefaultApiListAllReferredUsagesBatchOpts - Optional Parameters: - * @param "Body" (optional.Interface of []string) - -@return ResponseDtoEntityReferencesDto -*/ - -type DefaultApiListAllReferredUsagesBatchOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) ListAllReferredUsagesBatch(ctx context.Context, accountIdentifier string, referredByEntityType string, referredEntityType string, localVarOptionals *DefaultApiListAllReferredUsagesBatchOpts) (ResponseDtoEntityReferencesDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEntityReferencesDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/entitySetupUsage/internal/listAllReferredUsagesBatch" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("referredByEntityType", parameterToString(referredByEntityType, "")) - localVarQueryParams.Add("referredEntityType", parameterToString(referredEntityType, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEntityReferencesDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param apiKeyType - * @param parentIdentifier - * @param optional nil or *DefaultApiListApiKeysOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifiers" (optional.Interface of []string) - -@return ResponseDtoListApiKeyDto -*/ - -type DefaultApiListApiKeysOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifiers optional.Interface -} - -func (a *DefaultApiService) ListApiKeys(ctx context.Context, accountIdentifier string, apiKeyType string, parentIdentifier string, localVarOptionals *DefaultApiListApiKeysOpts) (ResponseDtoListApiKeyDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListApiKeyDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/apikey" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - localVarQueryParams.Add("apiKeyType", parameterToString(apiKeyType, "")) - localVarQueryParams.Add("parentIdentifier", parameterToString(parentIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.Identifiers.IsSet() { - localVarQueryParams.Add("identifiers", parameterToString(localVarOptionals.Identifiers.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListApiKeyDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListBranchesForRepoOpts - Optional Parameters: - * @param "ConnectorIdentifierRef" (optional.String) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "RepoURL" (optional.String) - - * @param "Page" (optional.Int32) - - * @param "Size" (optional.Int32) - - * @param "SearchTerm" (optional.String) - -@return ResponseDtoListString -*/ - -type DefaultApiListBranchesForRepoOpts struct { - ConnectorIdentifierRef optional.String - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - RepoURL optional.String - Page optional.Int32 - Size optional.Int32 - SearchTerm optional.String -} - -func (a *DefaultApiService) ListBranchesForRepo(ctx context.Context, localVarOptionals *DefaultApiListBranchesForRepoOpts) (ResponseDtoListString, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListString - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/scm/listRepoBranches" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ConnectorIdentifierRef.IsSet() { - localVarQueryParams.Add("connectorIdentifierRef", parameterToString(localVarOptionals.ConnectorIdentifierRef.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoURL.IsSet() { - localVarQueryParams.Add("repoURL", parameterToString(localVarOptionals.RepoURL.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Page.IsSet() { - localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListString - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListBranchesForRepo1Opts - Optional Parameters: - * @param "YamlGitConfigIdentifier" (optional.String) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Page" (optional.Int32) - - * @param "Size" (optional.Int32) - - * @param "SearchTerm" (optional.String) - -@return ResponseDtoListString -*/ - -type DefaultApiListBranchesForRepo1Opts struct { - YamlGitConfigIdentifier optional.String - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Page optional.Int32 - Size optional.Int32 - SearchTerm optional.String -} - -func (a *DefaultApiService) ListBranchesForRepo1(ctx context.Context, localVarOptionals *DefaultApiListBranchesForRepo1Opts) (ResponseDtoListString, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListString - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/scm/listBranchesByGitConfig" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.YamlGitConfigIdentifier.IsSet() { - localVarQueryParams.Add("yamlGitConfigIdentifier", parameterToString(localVarOptionals.YamlGitConfigIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Page.IsSet() { - localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListString - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListBranchesWithStatusForRepoOpts - Optional Parameters: - * @param "YamlGitConfigIdentifier" (optional.String) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Page" (optional.Int32) - - * @param "Size" (optional.Int32) - - * @param "SearchTerm" (optional.String) - - * @param "BranchSyncStatus" (optional.String) - -@return ResponseDtoGitBranchListDto -*/ - -type DefaultApiListBranchesWithStatusForRepoOpts struct { - YamlGitConfigIdentifier optional.String - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Page optional.Int32 - Size optional.Int32 - SearchTerm optional.String - BranchSyncStatus optional.String -} - -func (a *DefaultApiService) ListBranchesWithStatusForRepo(ctx context.Context, localVarOptionals *DefaultApiListBranchesWithStatusForRepoOpts) (ResponseDtoGitBranchListDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGitBranchListDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-branch/listBranchesWithStatus" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.YamlGitConfigIdentifier.IsSet() { - localVarQueryParams.Add("yamlGitConfigIdentifier", parameterToString(localVarOptionals.YamlGitConfigIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Page.IsSet() { - localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.BranchSyncStatus.IsSet() { - localVarQueryParams.Add("branchSyncStatus", parameterToString(localVarOptionals.BranchSyncStatus.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGitBranchListDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListBranchesWithStatusForRepo1Opts - Optional Parameters: - * @param "RepoIdentifier" (optional.String) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Branch" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiListBranchesWithStatusForRepo1Opts struct { - RepoIdentifier optional.String - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Branch optional.String -} - -func (a *DefaultApiService) ListBranchesWithStatusForRepo1(ctx context.Context, localVarOptionals *DefaultApiListBranchesWithStatusForRepo1Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-branch/sync" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param entityType - * @param optional nil or *DefaultApiListByTypeOpts - Optional Parameters: - * @param "ProjectIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "AccountIdentifier" (optional.String) - - * @param "GitSyncConfigId" (optional.String) - - * @param "Branch" (optional.String) - - * @param "Page" (optional.Int32) - - * @param "Size" (optional.Int32) - - * @param "ModuleType" (optional.String) - -@return ResponseDtoPageResponseGitSyncEntityListDto -*/ - -type DefaultApiListByTypeOpts struct { - ProjectIdentifier optional.String - OrgIdentifier optional.String - AccountIdentifier optional.String - GitSyncConfigId optional.String - Branch optional.String - Page optional.Int32 - Size optional.Int32 - ModuleType optional.String -} - -func (a *DefaultApiService) ListByType(ctx context.Context, entityType string, localVarOptionals *DefaultApiListByTypeOpts) (ResponseDtoPageResponseGitSyncEntityListDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseGitSyncEntityListDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-entities/{entityType}" - localVarPath = strings.Replace(localVarPath, "{"+"entityType"+"}", fmt.Sprintf("%v", entityType), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GitSyncConfigId.IsSet() { - localVarQueryParams.Add("gitSyncConfigId", parameterToString(localVarOptionals.GitSyncConfigId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Page.IsSet() { - localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ModuleType.IsSet() { - localVarQueryParams.Add("moduleType", parameterToString(localVarOptionals.ModuleType.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseGitSyncEntityListDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListEnvironmentOpts - Optional Parameters: - * @param "Page" (optional.Int32) - - * @param "Size" (optional.Int32) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "EnvIdentifiers" (optional.Interface of []string) - - * @param "Sort" (optional.Interface of []string) - -@return ResponseDtoPageResponseEnvironmentResponse -*/ - -type DefaultApiListEnvironmentOpts struct { - Page optional.Int32 - Size optional.Int32 - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - SearchTerm optional.String - EnvIdentifiers optional.Interface - Sort optional.Interface -} - -func (a *DefaultApiService) ListEnvironment(ctx context.Context, localVarOptionals *DefaultApiListEnvironmentOpts) (ResponseDtoPageResponseEnvironmentResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseEnvironmentResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environmentsV2" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.Page.IsSet() { - localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.EnvIdentifiers.IsSet() { - localVarQueryParams.Add("envIdentifiers", parameterToString(localVarOptionals.EnvIdentifiers.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { - localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseEnvironmentResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListEnvironmentsForProjectOpts - Optional Parameters: - * @param "Page" (optional.Int32) - - * @param "Size" (optional.Int32) - - * @param "AccountId" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "EnvIdentifiers" (optional.Interface of []string) - - * @param "Sort" (optional.Interface of []string) - -@return ResponseDtoPageResponseEnvironmentResponseDto -*/ - -type DefaultApiListEnvironmentsForProjectOpts struct { - Page optional.Int32 - Size optional.Int32 - AccountId optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - EnvIdentifiers optional.Interface - Sort optional.Interface -} - -func (a *DefaultApiService) ListEnvironmentsForProject(ctx context.Context, localVarOptionals *DefaultApiListEnvironmentsForProjectOpts) (ResponseDtoPageResponseEnvironmentResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseEnvironmentResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environments" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.Page.IsSet() { - localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.EnvIdentifiers.IsSet() { - localVarQueryParams.Add("envIdentifiers", parameterToString(localVarOptionals.EnvIdentifiers.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { - localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseEnvironmentResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListGitSyncErrorsOpts - Optional Parameters: - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - - * @param "GitToHarness" (optional.Bool) - -@return ResponseDtoPageResponseGitSyncErrorDto -*/ - -type DefaultApiListGitSyncErrorsOpts struct { - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - SearchTerm optional.String - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool - GitToHarness optional.Bool -} - -func (a *DefaultApiService) ListGitSyncErrors(ctx context.Context, localVarOptionals *DefaultApiListGitSyncErrorsOpts) (ResponseDtoPageResponseGitSyncErrorDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseGitSyncErrorDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-errors" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GitToHarness.IsSet() { - localVarQueryParams.Add("gitToHarness", parameterToString(localVarOptionals.GitToHarness.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseGitSyncErrorDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param commitId - * @param optional nil or *DefaultApiListGitSyncErrorsForACommitOpts - Optional Parameters: - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoPageResponseGitSyncErrorDto -*/ - -type DefaultApiListGitSyncErrorsForACommitOpts struct { - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) ListGitSyncErrorsForACommit(ctx context.Context, commitId string, localVarOptionals *DefaultApiListGitSyncErrorsForACommitOpts) (ResponseDtoPageResponseGitSyncErrorDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseGitSyncErrorDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-errors/commits/{commitId}" - localVarPath = strings.Replace(localVarPath, "{"+"commitId"+"}", fmt.Sprintf("%v", commitId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseGitSyncErrorDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListGitToHarnessErrorsGroupedByCommitsOpts - Optional Parameters: - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - - * @param "SortOrders" (optional.Interface of []SortOrder) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - - * @param "NumberOfErrorsInSummary" (optional.Int32) - -@return ResponseDtoPageResponseGitSyncErrorAggregateByCommitDto -*/ - -type DefaultApiListGitToHarnessErrorsGroupedByCommitsOpts struct { - PageIndex optional.Int32 - PageSize optional.Int32 - SortOrders optional.Interface - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - SearchTerm optional.String - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool - NumberOfErrorsInSummary optional.Int32 -} - -func (a *DefaultApiService) ListGitToHarnessErrorsGroupedByCommits(ctx context.Context, localVarOptionals *DefaultApiListGitToHarnessErrorsGroupedByCommitsOpts) (ResponseDtoPageResponseGitSyncErrorAggregateByCommitDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseGitSyncErrorAggregateByCommitDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-errors/aggregate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { - localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.NumberOfErrorsInSummary.IsSet() { - localVarQueryParams.Add("numberOfErrorsInSummary", parameterToString(localVarOptionals.NumberOfErrorsInSummary.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseGitSyncErrorAggregateByCommitDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiListSecretsOpts - Optional Parameters: - * @param "Body" (optional.Interface of SecretResourceFilterDto) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "PageIndex" (optional.Int32) - - * @param "PageSize" (optional.Int32) - -@return ResponseDtoPageResponseSecretResponseWrapper -*/ - -type DefaultApiListSecretsOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String - PageIndex optional.Int32 - PageSize optional.Int32 -} - -func (a *DefaultApiService) ListSecrets(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiListSecretsOpts) (ResponseDtoPageResponseSecretResponseWrapper, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseSecretResponseWrapper - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/list" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { - localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { - localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseSecretResponseWrapper - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiListServiceAccountsOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifiers" (optional.Interface of []string) - -@return ResponseDtoListServiceAccountDto -*/ - -type DefaultApiListServiceAccountsOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifiers optional.Interface -} - -func (a *DefaultApiService) ListServiceAccounts(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiListServiceAccountsOpts) (ResponseDtoListServiceAccountDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListServiceAccountDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/serviceaccount" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Identifiers.IsSet() { - localVarQueryParams.Add("identifiers", parameterToString(localVarOptionals.Identifiers.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListServiceAccountDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListServicesOpts - Optional Parameters: - * @param "Page" (optional.Int32) - - * @param "Size" (optional.Int32) - - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "SearchTerm" (optional.String) - - * @param "ServiceIdentifiers" (optional.Interface of []string) - - * @param "Sort" (optional.Interface of []string) - -@return ResponseDtoPageResponseServiceResponse -*/ - -type DefaultApiListServicesOpts struct { - Page optional.Int32 - Size optional.Int32 - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - SearchTerm optional.String - ServiceIdentifiers optional.Interface - Sort optional.Interface -} - -func (a *DefaultApiService) ListServices(ctx context.Context, localVarOptionals *DefaultApiListServicesOpts) (ResponseDtoPageResponseServiceResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/servicesV2" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.Page.IsSet() { - localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { - localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ServiceIdentifiers.IsSet() { - localVarQueryParams.Add("serviceIdentifiers", parameterToString(localVarOptionals.ServiceIdentifiers.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { - localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseServiceResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListServicesForProjectOpts - Optional Parameters: - * @param "Page" (optional.Int32) - - * @param "Size" (optional.Int32) - - * @param "AccountId" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "ServiceIdentifiers" (optional.Interface of []string) - - * @param "Sort" (optional.Interface of []string) - -@return ResponseDtoPageResponseServiceResponseDto -*/ - -type DefaultApiListServicesForProjectOpts struct { - Page optional.Int32 - Size optional.Int32 - AccountId optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - ServiceIdentifiers optional.Interface - Sort optional.Interface -} - -func (a *DefaultApiService) ListServicesForProject(ctx context.Context, localVarOptionals *DefaultApiListServicesForProjectOpts) (ResponseDtoPageResponseServiceResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPageResponseServiceResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/services" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.Page.IsSet() { - localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ServiceIdentifiers.IsSet() { - localVarQueryParams.Add("serviceIdentifiers", parameterToString(localVarOptionals.ServiceIdentifiers.Value(), "multi")) - } - if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { - localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPageResponseServiceResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiListSummaryOpts - Optional Parameters: - * @param "Body" (optional.Interface of GitEntitySummaryFilterDto) - - * @param "ProjectIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "AccountIdentifier" (optional.String) - - * @param "Size" (optional.Int32) - -@return ResponseDtoGitSyncRepoFilesListDto -*/ - -type DefaultApiListSummaryOpts struct { - Body optional.Interface - ProjectIdentifier optional.String - OrgIdentifier optional.String - AccountIdentifier optional.String - Size optional.Int32 -} - -func (a *DefaultApiService) ListSummary(ctx context.Context, localVarOptionals *DefaultApiListSummaryOpts) (ResponseDtoGitSyncRepoFilesListDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGitSyncRepoFilesListDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-entities/summary" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGitSyncRepoFilesListDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param branch - * @param optional nil or *DefaultApiListSummaryByRepoAndBranchOpts - Optional Parameters: - * @param "Body" (optional.Interface of GitEntityBranchSummaryFilterDto) - - * @param "ProjectIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "AccountIdentifier" (optional.String) - - * @param "Size" (optional.Int32) - - * @param "GitSyncConfigId" (optional.String) - -@return ResponseDtoListGitSyncEntityListDto -*/ - -type DefaultApiListSummaryByRepoAndBranchOpts struct { - Body optional.Interface - ProjectIdentifier optional.String - OrgIdentifier optional.String - AccountIdentifier optional.String - Size optional.Int32 - GitSyncConfigId optional.String -} - -func (a *DefaultApiService) ListSummaryByRepoAndBranch(ctx context.Context, branch string, localVarOptionals *DefaultApiListSummaryByRepoAndBranchOpts) (ResponseDtoListGitSyncEntityListDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoListGitSyncEntityListDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-entities/branch/{branch}" - localVarPath = strings.Replace(localVarPath, "{"+"branch"+"}", fmt.Sprintf("%v", branch), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Size.IsSet() { - localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GitSyncConfigId.IsSet() { - localVarQueryParams.Add("gitSyncConfigId", parameterToString(localVarOptionals.GitSyncConfigId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoListGitSyncEntityListDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param perpetualTaskId - * @param optional nil or *DefaultApiProcessInstanceSyncPerpetualTaskResponseOpts - Optional Parameters: - * @param "Body" (optional.Interface of DelegateResponseData) - -@return ResponseDtoBoolean -*/ - -type DefaultApiProcessInstanceSyncPerpetualTaskResponseOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) ProcessInstanceSyncPerpetualTaskResponse(ctx context.Context, accountIdentifier string, perpetualTaskId string, localVarOptionals *DefaultApiProcessInstanceSyncPerpetualTaskResponseOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/instancesync/response" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("perpetualTaskId", parameterToString(perpetualTaskId, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param perpetualTaskId - * @param optional nil or *DefaultApiProcessPollingResultNgOpts - Optional Parameters: - * @param "Body" (optional.Interface of []string) - - * @param "AccountId" (optional.String) - - -*/ - -type DefaultApiProcessPollingResultNgOpts struct { - Body optional.Interface - AccountId optional.String -} - -func (a *DefaultApiService) ProcessPollingResultNg(ctx context.Context, perpetualTaskId string, localVarOptionals *DefaultApiProcessPollingResultNgOpts) (*http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/polling/delegate-response/{perpetualTaskId}" - localVarPath = strings.Replace(localVarPath, "{"+"perpetualTaskId"+"}", fmt.Sprintf("%v", perpetualTaskId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"*/*"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - return localVarHttpResponse, newErr - } - - return localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param identifier - * @param userIdentifier - * @param optional nil or *DefaultApiRemoveMemberOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoUserGroupDto -*/ - -type DefaultApiRemoveMemberOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) RemoveMember(ctx context.Context, accountIdentifier string, identifier string, userIdentifier string, localVarOptionals *DefaultApiRemoveMemberOpts) (ResponseDtoUserGroupDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserGroupDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups/{identifier}/member/{userIdentifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - localVarPath = strings.Replace(localVarPath, "{"+"userIdentifier"+"}", fmt.Sprintf("%v", userIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserGroupDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param userId - * @param accountIdentifier - * @param optional nil or *DefaultApiRemoveUserOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiRemoveUserOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) RemoveUser(ctx context.Context, userId string, accountIdentifier string, localVarOptionals *DefaultApiRemoveUserOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/{userId}" - localVarPath = strings.Replace(localVarPath, "{"+"userId"+"}", fmt.Sprintf("%v", userId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param userId - * @param accountIdentifier - * @param optional nil or *DefaultApiRemoveUserInternalOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "RemoveUserFilter" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiRemoveUserInternalOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - RemoveUserFilter optional.String -} - -func (a *DefaultApiService) RemoveUserInternal(ctx context.Context, userId string, accountIdentifier string, localVarOptionals *DefaultApiRemoveUserInternalOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Delete") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/internal/{userId}" - localVarPath = strings.Replace(localVarPath, "{"+"userId"+"}", fmt.Sprintf("%v", userId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RemoveUserFilter.IsSet() { - localVarQueryParams.Add("removeUserFilter", parameterToString(localVarOptionals.RemoveUserFilter.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param email -@return ResponseDtoBoolean -*/ -func (a *DefaultApiService) ResendVerifyEmail(ctx context.Context, email string) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/signup/verify-notification" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("email", parameterToString(email, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier - * @param apiKeyType - * @param parentIdentifier - * @param apiKeyIdentifier - * @param optional nil or *DefaultApiRotateTokenOpts - Optional Parameters: - * @param "RotateTimestamp" (optional.Int64) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoString -*/ - -type DefaultApiRotateTokenOpts struct { - RotateTimestamp optional.Int64 - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) RotateToken(ctx context.Context, identifier string, accountIdentifier string, apiKeyType string, parentIdentifier string, apiKeyIdentifier string, localVarOptionals *DefaultApiRotateTokenOpts) (ResponseDtoString, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoString - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/token/rotate/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.RotateTimestamp.IsSet() { - localVarQueryParams.Add("rotateTimestamp", parameterToString(localVarOptionals.RotateTimestamp.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - localVarQueryParams.Add("apiKeyType", parameterToString(apiKeyType, "")) - localVarQueryParams.Add("parentIdentifier", parameterToString(parentIdentifier, "")) - localVarQueryParams.Add("apiKeyIdentifier", parameterToString(apiKeyIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoString - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiSaveOpts - Optional Parameters: - * @param "Body" (optional.Interface of NgActivityDto) - -@return ResponseDtongActivityDto -*/ - -type DefaultApiSaveOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) Save(ctx context.Context, localVarOptionals *DefaultApiSaveOpts) (ResponseDtongActivityDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtongActivityDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/activityHistory" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtongActivityDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiSave1Opts - Optional Parameters: - * @param "Body" (optional.Interface of EntitySetupUsageDto) - -@return ResponseDtoEntitySetupUsageDto -*/ - -type DefaultApiSave1Opts struct { - Body optional.Interface -} - -func (a *DefaultApiService) Save1(ctx context.Context, localVarOptionals *DefaultApiSave1Opts) (ResponseDtoEntitySetupUsageDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEntitySetupUsageDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/entitySetupUsage/internal" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEntitySetupUsageDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body -@return ResponseDtoSourceCodeManagerDto -*/ -func (a *DefaultApiService) Save2(ctx context.Context, body SourceCodeManagerDto) (ResponseDtoSourceCodeManagerDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSourceCodeManagerDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/source-code-manager" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"*/*"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSourceCodeManagerDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiSignupOpts - Optional Parameters: - * @param "Body" (optional.Interface of SignupDto) - - * @param "CaptchaToken" (optional.String) - -@return RestResponseVoid -*/ - -type DefaultApiSignupOpts struct { - Body optional.Interface - CaptchaToken optional.String -} - -func (a *DefaultApiService) Signup(ctx context.Context, localVarOptionals *DefaultApiSignupOpts) (RestResponseVoid, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RestResponseVoid - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/signup" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.CaptchaToken.IsSet() { - localVarQueryParams.Add("captchaToken", parameterToString(localVarOptionals.CaptchaToken.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v RestResponseVoid - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiSignupOAuthOpts - Optional Parameters: - * @param "Body" (optional.Interface of OAuthSignupDto) - -@return RestResponseUserInfo -*/ - -type DefaultApiSignupOAuthOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) SignupOAuth(ctx context.Context, localVarOptionals *DefaultApiSignupOAuthOpts) (RestResponseUserInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RestResponseUserInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/signup/oauth" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v RestResponseUserInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiSubscribeOpts - Optional Parameters: - * @param "Body" (optional.Interface of []string) - -@return ResponseDtoPollingResponseDto -*/ - -type DefaultApiSubscribeOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) Subscribe(ctx context.Context, localVarOptionals *DefaultApiSubscribeOpts) (ResponseDtoPollingResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoPollingResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/polling/subscribe" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"*/*"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoPollingResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param userGroupId - * @param accountIdentifier - * @param optional nil or *DefaultApiUnlinkSsoGroupOpts - Optional Parameters: - * @param "RetainMembers" (optional.Bool) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return RestResponseUserGroup -*/ - -type DefaultApiUnlinkSsoGroupOpts struct { - RetainMembers optional.Bool - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) UnlinkSsoGroup(ctx context.Context, userGroupId string, accountIdentifier string, localVarOptionals *DefaultApiUnlinkSsoGroupOpts) (RestResponseUserGroup, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RestResponseUserGroup - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups/{userGroupId}/unlink" - localVarPath = strings.Replace(localVarPath, "{"+"userGroupId"+"}", fmt.Sprintf("%v", userGroupId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.RetainMembers.IsSet() { - localVarQueryParams.Add("retainMembers", parameterToString(localVarOptionals.RetainMembers.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v RestResponseUserGroup - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param userId - * @param accountIdentifier - * @param optional nil or *DefaultApiUnlockUserOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoUserInfo -*/ - -type DefaultApiUnlockUserOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) UnlockUser(ctx context.Context, userId string, accountIdentifier string, localVarOptionals *DefaultApiUnlockUserOpts) (ResponseDtoUserInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/unlock-user/{userId}" - localVarPath = strings.Replace(localVarPath, "{"+"userId"+"}", fmt.Sprintf("%v", userId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiUnsubscribeOpts - Optional Parameters: - * @param "Body" (optional.Interface of []string) - -@return bool -*/ - -type DefaultApiUnsubscribeOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) Unsubscribe(ctx context.Context, localVarOptionals *DefaultApiUnsubscribeOpts) (bool, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue bool - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/polling/unsubscribe" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"*/*"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v bool - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiUpdateOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoFilterDto -*/ - -type DefaultApiUpdateOpts struct { - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Update(ctx context.Context, body FilterDto, localVarOptionals *DefaultApiUpdateOpts) (ResponseDtoFilterDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoFilterDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/filters" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoFilterDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiUpdate1Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "RootFolder" (optional.String) - - * @param "FilePath" (optional.String) - - * @param "CommitMsg" (optional.String) - - * @param "BaseBranch" (optional.String) - -@return ResponseDtoGitOpsProviderResponseDto -*/ - -type DefaultApiUpdate1Opts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Branch optional.String - RepoIdentifier optional.String - RootFolder optional.String - FilePath optional.String - CommitMsg optional.String - BaseBranch optional.String -} - -func (a *DefaultApiService) Update1(ctx context.Context, body GitOpsProviderDto, localVarOptionals *DefaultApiUpdate1Opts) (ResponseDtoGitOpsProviderResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGitOpsProviderResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/gitopsproviders" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RootFolder.IsSet() { - localVarQueryParams.Add("rootFolder", parameterToString(localVarOptionals.RootFolder.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.FilePath.IsSet() { - localVarQueryParams.Add("filePath", parameterToString(localVarOptionals.FilePath.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.CommitMsg.IsSet() { - localVarQueryParams.Add("commitMsg", parameterToString(localVarOptionals.CommitMsg.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.BaseBranch.IsSet() { - localVarQueryParams.Add("baseBranch", parameterToString(localVarOptionals.BaseBranch.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGitOpsProviderResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param identifier -@return ResponseDtoSourceCodeManagerDto -*/ -func (a *DefaultApiService) Update10(ctx context.Context, body SourceCodeManagerDto, identifier string) (ResponseDtoSourceCodeManagerDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSourceCodeManagerDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/source-code-manager/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"*/*"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSourceCodeManagerDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body -@return ResponseDtoGitSyncSettingsDto -*/ -func (a *DefaultApiService) Update2(ctx context.Context, body GitSyncSettingsDto) (ResponseDtoGitSyncSettingsDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoGitSyncSettingsDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-settings" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoGitSyncSettingsDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiUpdate3Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - -@return GitSyncConfigDto -*/ - -type DefaultApiUpdate3Opts struct { - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Update3(ctx context.Context, body GitSyncConfigDto, localVarOptionals *DefaultApiUpdate3Opts) (GitSyncConfigDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue GitSyncConfigDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v GitSyncConfigDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param identifier - * @param optional nil or *DefaultApiUpdate4Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoModuleLicense -*/ - -type DefaultApiUpdate4Opts struct { - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Update4(ctx context.Context, body ModuleLicense, identifier string, localVarOptionals *DefaultApiUpdate4Opts) (ResponseDtoModuleLicense, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoModuleLicense - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/admin/licenses/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoModuleLicense - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiUpdate5Opts - Optional Parameters: - * @param "IfMatch" (optional.String) - - * @param "AccountId" (optional.String) - -@return ResponseDtoEnvironmentResponseDto -*/ - -type DefaultApiUpdate5Opts struct { - IfMatch optional.String - AccountId optional.String -} - -func (a *DefaultApiService) Update5(ctx context.Context, body EnvironmentRequestDto, localVarOptionals *DefaultApiUpdate5Opts) (ResponseDtoEnvironmentResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEnvironmentResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environments" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEnvironmentResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiUpdate6Opts - Optional Parameters: - * @param "Body" (optional.Interface of EnvironmentRequestDto) - - * @param "IfMatch" (optional.String) - - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoEnvironmentResponse -*/ - -type DefaultApiUpdate6Opts struct { - Body optional.Interface - IfMatch optional.String - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Update6(ctx context.Context, localVarOptionals *DefaultApiUpdate6Opts) (ResponseDtoEnvironmentResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEnvironmentResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environmentsV2" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEnvironmentResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiUpdate7Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoUserGroupDto -*/ - -type DefaultApiUpdate7Opts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) Update7(ctx context.Context, body UserGroupDto, localVarOptionals *DefaultApiUpdate7Opts) (ResponseDtoUserGroupDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserGroupDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user-groups" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserGroupDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiUpdate8Opts - Optional Parameters: - * @param "IfMatch" (optional.String) - - * @param "AccountId" (optional.String) - -@return ResponseDtoServiceResponseDto -*/ - -type DefaultApiUpdate8Opts struct { - IfMatch optional.String - AccountId optional.String -} - -func (a *DefaultApiService) Update8(ctx context.Context, body ServiceRequestDto, localVarOptionals *DefaultApiUpdate8Opts) (ResponseDtoServiceResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/services" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiUpdate9Opts - Optional Parameters: - * @param "Body" (optional.Interface of ServiceRequestDto) - - * @param "IfMatch" (optional.String) - - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoServiceResponse -*/ - -type DefaultApiUpdate9Opts struct { - Body optional.Interface - IfMatch optional.String - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Update9(ctx context.Context, localVarOptionals *DefaultApiUpdate9Opts) (ResponseDtoServiceResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/servicesV2" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param optional nil or *DefaultApiUpdateApiKeyOpts - Optional Parameters: - * @param "Body" (optional.Interface of ApiKeyDto) - -@return ResponseDtoApiKeyDto -*/ - -type DefaultApiUpdateApiKeyOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) UpdateApiKey(ctx context.Context, identifier string, localVarOptionals *DefaultApiUpdateApiKeyOpts) (ResponseDtoApiKeyDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoApiKeyDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/apikey/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoApiKeyDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param folderIdentifier - * @param optional nil or *DefaultApiUpdateDefaultOpts - Optional Parameters: - * @param "ProjectId" (optional.String) - - * @param "OrganizationId" (optional.String) - - * @param "AccountId" (optional.String) - -@return GitSyncConfigDto -*/ - -type DefaultApiUpdateDefaultOpts struct { - ProjectId optional.String - OrganizationId optional.String - AccountId optional.String -} - -func (a *DefaultApiService) UpdateDefault(ctx context.Context, identifier string, folderIdentifier string, localVarOptionals *DefaultApiUpdateDefaultOpts) (GitSyncConfigDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue GitSyncConfigDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync/{identifier}/folder/{folderIdentifier}/default" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - localVarPath = strings.Replace(localVarPath, "{"+"folderIdentifier"+"}", fmt.Sprintf("%v", folderIdentifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ProjectId.IsSet() { - localVarQueryParams.Add("projectId", parameterToString(localVarOptionals.ProjectId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrganizationId.IsSet() { - localVarQueryParams.Add("organizationId", parameterToString(localVarOptionals.OrganizationId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v GitSyncConfigDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param inviteId - * @param optional nil or *DefaultApiUpdateInviteOpts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoOptionalInviteDto -*/ - -type DefaultApiUpdateInviteOpts struct { - AccountIdentifier optional.String -} - -func (a *DefaultApiService) UpdateInvite(ctx context.Context, body InviteDto, inviteId string, localVarOptionals *DefaultApiUpdateInviteOpts) (ResponseDtoOptionalInviteDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoOptionalInviteDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/invites/{inviteId}" - localVarPath = strings.Replace(localVarPath, "{"+"inviteId"+"}", fmt.Sprintf("%v", inviteId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "text/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoOptionalInviteDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param identifier - * @param optional nil or *DefaultApiUpdateSecretOpts - Optional Parameters: - * @param "Body" (optional.Interface of SecretRequestWrapper) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoSecretResponseWrapper -*/ - -type DefaultApiUpdateSecretOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) UpdateSecret(ctx context.Context, accountIdentifier string, identifier string, localVarOptionals *DefaultApiUpdateSecretOpts) (ResponseDtoSecretResponseWrapper, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSecretResponseWrapper - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSecretResponseWrapper - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param identifier - * @param optional nil or *DefaultApiUpdateSecretFileOpts - Optional Parameters: - * @param "File" (optional.Interface of interface{}) - - * @param "Spec" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoSecretResponseWrapper -*/ - -type DefaultApiUpdateSecretFileOpts struct { - File optional.Interface - Spec optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) UpdateSecretFile(ctx context.Context, accountIdentifier string, identifier string, localVarOptionals *DefaultApiUpdateSecretFileOpts) (ResponseDtoSecretResponseWrapper, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSecretResponseWrapper - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/files/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"multipart/form-data"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.File.IsSet() { - localVarFormParams.Add("file", parameterToString(localVarOptionals.File.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Spec.IsSet() { - localVarFormParams.Add("spec", parameterToString(localVarOptionals.Spec.Value(), "")) - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSecretResponseWrapper - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param identifier - * @param optional nil or *DefaultApiUpdateSecretViaYamlOpts - Optional Parameters: - * @param "Body" (optional.Interface of SecretRequestWrapper) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoSecretResponseWrapper -*/ - -type DefaultApiUpdateSecretViaYamlOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) UpdateSecretViaYaml(ctx context.Context, accountIdentifier string, identifier string, localVarOptionals *DefaultApiUpdateSecretViaYamlOpts) (ResponseDtoSecretResponseWrapper, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSecretResponseWrapper - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/{identifier}/yaml" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSecretResponseWrapper - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param identifier - * @param optional nil or *DefaultApiUpdateServiceAccountOpts - Optional Parameters: - * @param "Body" (optional.Interface of ServiceAccountDto) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoServiceAccountDto -*/ - -type DefaultApiUpdateServiceAccountOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) UpdateServiceAccount(ctx context.Context, accountIdentifier string, identifier string, localVarOptionals *DefaultApiUpdateServiceAccountOpts) (ResponseDtoServiceAccountDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceAccountDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/serviceaccount/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceAccountDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param optional nil or *DefaultApiUpdateTokenOpts - Optional Parameters: - * @param "Body" (optional.Interface of TokenDto) - -@return ResponseDtoTokenDto -*/ - -type DefaultApiUpdateTokenOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) UpdateToken(ctx context.Context, identifier string, localVarOptionals *DefaultApiUpdateTokenOpts) (ResponseDtoTokenDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoTokenDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/token/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoTokenDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiUpdateTwoFactorAuthInfoOpts - Optional Parameters: - * @param "Body" (optional.Interface of TwoFactorAuthSettingsInfo) - - * @param "RoutingId" (optional.String) - -@return ResponseDtoUserInfo -*/ - -type DefaultApiUpdateTwoFactorAuthInfoOpts struct { - Body optional.Interface - RoutingId optional.String -} - -func (a *DefaultApiService) UpdateTwoFactorAuthInfo(ctx context.Context, localVarOptionals *DefaultApiUpdateTwoFactorAuthInfoOpts) (ResponseDtoUserInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user/enable-two-factor-auth" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.RoutingId.IsSet() { - localVarQueryParams.Add("routingId", parameterToString(localVarOptionals.RoutingId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiUpdateUserInfoOpts - Optional Parameters: - * @param "Body" (optional.Interface of UserInfo) - -@return ResponseDtoUserInfo -*/ - -type DefaultApiUpdateUserInfoOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) UpdateUserInfo(ctx context.Context, localVarOptionals *DefaultApiUpdateUserInfoOpts) (ResponseDtoUserInfo, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUserInfo - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/user" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUserInfo - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiUpsertOpts - Optional Parameters: - * @param "IfMatch" (optional.String) - - * @param "AccountId" (optional.String) - -@return ResponseDtoEnvironmentResponseDto -*/ - -type DefaultApiUpsertOpts struct { - IfMatch optional.String - AccountId optional.String -} - -func (a *DefaultApiService) Upsert(ctx context.Context, body EnvironmentRequestDto, localVarOptionals *DefaultApiUpsertOpts) (ResponseDtoEnvironmentResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEnvironmentResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environments/upsert" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEnvironmentResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiUpsert1Opts - Optional Parameters: - * @param "Body" (optional.Interface of EnvironmentRequestDto) - - * @param "IfMatch" (optional.String) - - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoEnvironmentResponse -*/ - -type DefaultApiUpsert1Opts struct { - Body optional.Interface - IfMatch optional.String - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Upsert1(ctx context.Context, localVarOptionals *DefaultApiUpsert1Opts) (ResponseDtoEnvironmentResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoEnvironmentResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/environmentsV2/upsert" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoEnvironmentResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param optional nil or *DefaultApiUpsert2Opts - Optional Parameters: - * @param "IfMatch" (optional.String) - - * @param "AccountId" (optional.String) - -@return ResponseDtoServiceResponseDto -*/ - -type DefaultApiUpsert2Opts struct { - IfMatch optional.String - AccountId optional.String -} - -func (a *DefaultApiService) Upsert2(ctx context.Context, body ServiceRequestDto, localVarOptionals *DefaultApiUpsert2Opts) (ResponseDtoServiceResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/services/upsert" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiUpsert3Opts - Optional Parameters: - * @param "Body" (optional.Interface of ServiceRequestDto) - - * @param "IfMatch" (optional.String) - - * @param "AccountIdentifier" (optional.String) - -@return ResponseDtoServiceResponse -*/ - -type DefaultApiUpsert3Opts struct { - Body optional.Interface - IfMatch optional.String - AccountIdentifier optional.String -} - -func (a *DefaultApiService) Upsert3(ctx context.Context, localVarOptionals *DefaultApiUpsert3Opts) (ResponseDtoServiceResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Put") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoServiceResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/servicesV2/upsert" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { - localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoServiceResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiUpsertWebhookOpts - Optional Parameters: - * @param "Body" (optional.Interface of UpsertWebhookRequestDto) - -@return ResponseDtoUpsertWebhookResponseDto -*/ - -type DefaultApiUpsertWebhookOpts struct { - Body optional.Interface -} - -func (a *DefaultApiService) UpsertWebhook(ctx context.Context, localVarOptionals *DefaultApiUpsertWebhookOpts) (ResponseDtoUpsertWebhookResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoUpsertWebhookResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/webhookevent" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml", "text/plain"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/plain"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoUpsertWebhookResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiValidateArtifactOpts - Optional Parameters: - * @param "Body" (optional.Interface of DockerRequestDto) - - * @param "ImagePath" (optional.String) - - * @param "ConnectorRef" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiValidateArtifactOpts struct { - Body optional.Interface - ImagePath optional.String - ConnectorRef optional.String -} - -func (a *DefaultApiService) ValidateArtifact(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiValidateArtifactOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/docker/validateArtifact" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ImagePath.IsSet() { - localVarQueryParams.Add("imagePath", parameterToString(localVarOptionals.ImagePath.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ConnectorRef.IsSet() { - localVarQueryParams.Add("connectorRef", parameterToString(localVarOptionals.ConnectorRef.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param imagePath - * @param region - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiValidateArtifact1Opts - Optional Parameters: - * @param "Body" (optional.Interface of EcrRequestDto) - -@return ResponseDtoBoolean -*/ - -type DefaultApiValidateArtifact1Opts struct { - Body optional.Interface -} - -func (a *DefaultApiService) ValidateArtifact1(ctx context.Context, imagePath string, region string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiValidateArtifact1Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/ecr/validateArtifact" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("region", parameterToString(region, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param imagePath - * @param registryHostname - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiValidateArtifact2Opts - Optional Parameters: - * @param "Body" (optional.Interface of GcrRequestDto) - -@return ResponseDtoBoolean -*/ - -type DefaultApiValidateArtifact2Opts struct { - Body optional.Interface -} - -func (a *DefaultApiService) ValidateArtifact2(ctx context.Context, imagePath string, registryHostname string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiValidateArtifact2Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/gcr/validateArtifact" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("registryHostname", parameterToString(registryHostname, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiValidateArtifactImageOpts - Optional Parameters: - * @param "ImagePath" (optional.String) - - * @param "ConnectorRef" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiValidateArtifactImageOpts struct { - ImagePath optional.String - ConnectorRef optional.String -} - -func (a *DefaultApiService) ValidateArtifactImage(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiValidateArtifactImageOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/docker/validateArtifactSource" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ImagePath.IsSet() { - localVarQueryParams.Add("imagePath", parameterToString(localVarOptionals.ImagePath.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ConnectorRef.IsSet() { - localVarQueryParams.Add("connectorRef", parameterToString(localVarOptionals.ConnectorRef.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param imagePath - * @param region - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier -@return ResponseDtoBoolean -*/ -func (a *DefaultApiService) ValidateArtifactImage1(ctx context.Context, imagePath string, region string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/ecr/validateArtifactSource" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("region", parameterToString(region, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param imagePath - * @param registryHostname - * @param connectorRef - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier -@return ResponseDtoBoolean -*/ -func (a *DefaultApiService) ValidateArtifactImage2(ctx context.Context, imagePath string, registryHostname string, connectorRef string, accountIdentifier string, orgIdentifier string, projectIdentifier string) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/gcr/validateArtifactSource" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("registryHostname", parameterToString(registryHostname, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier - * @param optional nil or *DefaultApiValidateArtifactServerOpts - Optional Parameters: - * @param "ConnectorRef" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiValidateArtifactServerOpts struct { - ConnectorRef optional.String -} - -func (a *DefaultApiService) ValidateArtifactServer(ctx context.Context, accountIdentifier string, orgIdentifier string, projectIdentifier string, localVarOptionals *DefaultApiValidateArtifactServerOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/docker/validateArtifactServer" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.ConnectorRef.IsSet() { - localVarQueryParams.Add("connectorRef", parameterToString(localVarOptionals.ConnectorRef.Value(), "")) - } - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param imagePath - * @param connectorRef - * @param region - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier -@return ResponseDtoBoolean -*/ -func (a *DefaultApiService) ValidateArtifactServer1(ctx context.Context, imagePath string, connectorRef string, region string, accountIdentifier string, orgIdentifier string, projectIdentifier string) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/ecr/validateArtifactServer" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("region", parameterToString(region, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param imagePath - * @param connectorRef - * @param registryHostname - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier -@return ResponseDtoBoolean -*/ -func (a *DefaultApiService) ValidateArtifactServer2(ctx context.Context, imagePath string, connectorRef string, registryHostname string, accountIdentifier string, orgIdentifier string, projectIdentifier string) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/artifacts/gcr/validateArtifactServer" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("imagePath", parameterToString(imagePath, "")) - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("registryHostname", parameterToString(registryHostname, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("orgIdentifier", parameterToString(orgIdentifier, "")) - localVarQueryParams.Add("projectIdentifier", parameterToString(projectIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param connectorRef - * @param accountIdentifier - * @param optional nil or *DefaultApiValidateCredentialsOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Branch" (optional.String) - - * @param "RepoIdentifier" (optional.String) - - * @param "GetDefaultFromOtherRepo" (optional.Bool) - -@return ResponseDtoBoolean -*/ - -type DefaultApiValidateCredentialsOpts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String - Branch optional.String - RepoIdentifier optional.String - GetDefaultFromOtherRepo optional.Bool -} - -func (a *DefaultApiService) ValidateCredentials(ctx context.Context, connectorRef string, accountIdentifier string, localVarOptionals *DefaultApiValidateCredentialsOpts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/jira/validate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("connectorRef", parameterToString(connectorRef, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { - localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { - localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { - localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param optional nil or *DefaultApiValidateSecretOpts - Optional Parameters: - * @param "Body" (optional.Interface of SecretValidationMetaData) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifier" (optional.String) - -@return ResponseDtoSecretValidationResultDto -*/ - -type DefaultApiValidateSecretOpts struct { - Body optional.Interface - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifier optional.String -} - -func (a *DefaultApiService) ValidateSecret(ctx context.Context, accountIdentifier string, localVarOptionals *DefaultApiValidateSecretOpts) (ResponseDtoSecretValidationResultDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoSecretValidationResultDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/validate" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Identifier.IsSet() { - localVarQueryParams.Add("identifier", parameterToString(localVarOptionals.Identifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json", "application/yaml"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoSecretValidationResultDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param optional nil or *DefaultApiValidateTheIdentifierIsUnique1Opts - Optional Parameters: - * @param "AccountIdentifier" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - - * @param "Identifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiValidateTheIdentifierIsUnique1Opts struct { - AccountIdentifier optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String - Identifier optional.String -} - -func (a *DefaultApiService) ValidateTheIdentifierIsUnique1(ctx context.Context, localVarOptionals *DefaultApiValidateTheIdentifierIsUnique1Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/gitopsproviders/validateUniqueIdentifier" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { - localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.Identifier.IsSet() { - localVarQueryParams.Add("identifier", parameterToString(localVarOptionals.Identifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier - * @param optional nil or *DefaultApiValidateTheIdentifierIsUnique2Opts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return ResponseDtoBoolean -*/ - -type DefaultApiValidateTheIdentifierIsUnique2Opts struct { - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) ValidateTheIdentifierIsUnique2(ctx context.Context, identifier string, accountIdentifier string, localVarOptionals *DefaultApiValidateTheIdentifierIsUnique2Opts) (ResponseDtoBoolean, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue ResponseDtoBoolean - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/v2/secrets/validateUniqueIdentifier/{identifier}" - localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoBoolean - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param token - * @param accountIdentifier - * @param email - -*/ -func (a *DefaultApiService) VerifyInviteViaNGAuthUi(ctx context.Context, token string, accountIdentifier string, email string) (*http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/invites/verify" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("token", parameterToString(token, "")) - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - localVarQueryParams.Add("email", parameterToString(email, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - return localVarHttpResponse, newErr - } - - return localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param token -@return RestResponseVerifyTokenResponseDto -*/ -func (a *DefaultApiService) VerifyToken(ctx context.Context, token string) (RestResponseVerifyTokenResponseDto, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RestResponseVerifyTokenResponseDto - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/signup/verify/{token}" - localVarPath = strings.Replace(localVarPath, "{"+"token"+"}", fmt.Sprintf("%v", token), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v RestResponseVerifyTokenResponseDto - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} - -/* -DefaultApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param entityToken - * @param optional nil or *DefaultApiWebhookCatcherOpts - Optional Parameters: - * @param "Body" (optional.Interface of string) - - * @param "AccountId" (optional.String) - - * @param "OrgIdentifier" (optional.String) - - * @param "ProjectIdentifier" (optional.String) - -@return RestResponse -*/ - -type DefaultApiWebhookCatcherOpts struct { - Body optional.Interface - AccountId optional.String - OrgIdentifier optional.String - ProjectIdentifier optional.String -} - -func (a *DefaultApiService) WebhookCatcher(ctx context.Context, entityToken string, localVarOptionals *DefaultApiWebhookCatcherOpts) (RestResponse, *http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - localVarReturnValue RestResponse - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/git-sync-trigger/webhook/{entityToken}" - localVarPath = strings.Replace(localVarPath, "{"+"entityToken"+"}", fmt.Sprintf("%v", entityToken), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { - localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { - localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) - } - if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { - localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) - } - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "text/yaml", "text/html"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - if localVarOptionals != nil && localVarOptionals.Body.IsSet() { - - localVarOptionalBody := localVarOptionals.Body.Value() - localVarPostBody = &localVarOptionalBody - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return localVarReturnValue, nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarReturnValue, localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarReturnValue, localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode < 300 { - // If we succeed, return the data, otherwise pass on to decode error. - err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err == nil { - return localVarReturnValue, localVarHttpResponse, err - } - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 0 { - var v RestResponse - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarReturnValue, localVarHttpResponse, newErr - } - newErr.model = v - return localVarReturnValue, localVarHttpResponse, newErr - } - return localVarReturnValue, localVarHttpResponse, newErr - } - - return localVarReturnValue, localVarHttpResponse, nil -} diff --git a/harness/nextgen/api_enforcement.go b/harness/nextgen/api_enforcement.go index 2c9ea309..efecc233 100644 --- a/harness/nextgen/api_enforcement.go +++ b/harness/nextgen/api_enforcement.go @@ -11,7 +11,6 @@ package nextgen import ( "context" - "fmt" "io/ioutil" "net/http" "net/url" @@ -26,7 +25,7 @@ var ( type EnforcementApiService service /* -EnforcementApiService Gets All Feature Restriction Metadata +EnforcementApiService Fetch All Feature Restriction Metadata * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @return ResponseDtoListFeatureRestrictionMetadata */ @@ -129,7 +128,7 @@ func (a *EnforcementApiService) GetAllFeatureRestrictionMetadata(ctx context.Con } /* -EnforcementApiService Gets List of Enabled Feature Restriction Detail for The Account +EnforcementApiService Fetch List of Enabled Feature Restriction Detail for The Account * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param accountIdentifier Account id to get the enable features for the account @return ResponseDtoListFeatureRestrictionDetails @@ -234,7 +233,7 @@ func (a *EnforcementApiService) GetEnabledFeatureRestrictionDetailByAccountId(ct } /* -EnforcementApiService Gets Feature Restriction Detail +EnforcementApiService Fetch Feature Restriction Detail * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param body * @param accountIdentifier Account id to get the feature restriction detail. @@ -342,23 +341,23 @@ func (a *EnforcementApiService) GetFeatureRestrictionDetail(ctx context.Context, } /* -EnforcementApiService +EnforcementApiService Fetch List of Feature Restriction Detail * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param featureRestrictionName The feature restriction to retrieve metadata from. - * @param accountIdentifier Account id to get the feature metadata. - + * @param body + * @param accountIdentifier Account id to get the feature restriction detail. +@return ResponseDtoListFeatureRestrictionDetails */ -func (a *EnforcementApiService) GetFeatureRestrictionMetadata(ctx context.Context, featureRestrictionName string, accountIdentifier string) (*http.Response, error) { +func (a *EnforcementApiService) GetFeatureRestrictionDetails(ctx context.Context, body FeatureRestrictionDetailListRequest, accountIdentifier string) (ResponseDtoListFeatureRestrictionDetails, *http.Response, error) { var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoListFeatureRestrictionDetails ) // create path and map variables - localVarPath := a.client.cfg.BasePath + "/enforcement/{featureRestrictionName}/metadata" - localVarPath = strings.Replace(localVarPath, "{"+"featureRestrictionName"+"}", fmt.Sprintf("%v", featureRestrictionName), -1) + localVarPath := a.client.cfg.BasePath + "/enforcement/details" localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} @@ -366,7 +365,7 @@ func (a *EnforcementApiService) GetFeatureRestrictionMetadata(ctx context.Contex localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) // to determine the Content-Type header - localVarHttpContentTypes := []string{} + localVarHttpContentTypes := []string{"application/json"} // set Content-Type header localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) @@ -382,20 +381,30 @@ func (a *EnforcementApiService) GetFeatureRestrictionMetadata(ctx context.Contex if localVarHttpHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHttpHeaderAccept } + // body params + localVarPostBody = &body r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) if err != nil { - return nil, err + return localVarReturnValue, nil, err } localVarHttpResponse, err := a.client.callAPI(r) if err != nil || localVarHttpResponse == nil { - return localVarHttpResponse, err + return localVarReturnValue, localVarHttpResponse, err } localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) localVarHttpResponse.Body.Close() if err != nil { - return localVarHttpResponse, err + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } } if localVarHttpResponse.StatusCode >= 300 { @@ -408,112 +417,33 @@ func (a *EnforcementApiService) GetFeatureRestrictionMetadata(ctx context.Contex err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr } newErr.model = v - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr } if localVarHttpResponse.StatusCode == 500 { var v ModelError err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() - return localVarHttpResponse, newErr - } - newErr.model = v - return localVarHttpResponse, newErr - } - return localVarHttpResponse, newErr - } - - return localVarHttpResponse, nil -} - -/* -EnforcementApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body - * @param accountIdentifier Account id to get all metadata from. - -*/ -func (a *EnforcementApiService) GetFeatureRestrictionMetadataMap(ctx context.Context, body RestrictionMetadataMapRequestDto, accountIdentifier string) (*http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Post") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/enforcement/metadata" - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - // to determine the Content-Type header - localVarHttpContentTypes := []string{"application/json"} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - // body params - localVarPostBody = &body - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 400 { - var v ModelError - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr } newErr.model = v - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr } - if localVarHttpResponse.StatusCode == 500 { - var v ModelError + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoListFeatureRestrictionDetails err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr } newErr.model = v - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr } - return localVarHttpResponse, newErr + return localVarReturnValue, localVarHttpResponse, newErr } - return localVarHttpResponse, nil + return localVarReturnValue, localVarHttpResponse, nil } diff --git a/harness/nextgen/api_environments.go b/harness/nextgen/api_environments.go new file mode 100644 index 00000000..5fb17653 --- /dev/null +++ b/harness/nextgen/api_environments.go @@ -0,0 +1,936 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "fmt" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type EnvironmentsApiService service + +/* +EnvironmentsApiService Create an Environment + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *EnvironmentsApiCreateEnvironmentV2Opts - Optional Parameters: + * @param "Body" (optional.Interface of EnvironmentRequest) - Details of the Environment to be created +@return ResponseDtoEnvironmentResponse +*/ + +type EnvironmentsApiCreateEnvironmentV2Opts struct { + Body optional.Interface +} + +func (a *EnvironmentsApiService) CreateEnvironmentV2(ctx context.Context, accountIdentifier string, localVarOptionals *EnvironmentsApiCreateEnvironmentV2Opts) (ResponseDtoEnvironmentResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoEnvironmentResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/environmentsV2" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "application/yaml"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoEnvironmentResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +EnvironmentsApiService Delete an Environment by identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param environmentIdentifier Environment Identifier for the entity + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *EnvironmentsApiDeleteEnvironmentV2Opts - Optional Parameters: + * @param "IfMatch" (optional.String) - + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity +@return ResponseDtoBoolean +*/ + +type EnvironmentsApiDeleteEnvironmentV2Opts struct { + IfMatch optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String +} + +func (a *EnvironmentsApiService) DeleteEnvironmentV2(ctx context.Context, environmentIdentifier string, accountIdentifier string, localVarOptionals *EnvironmentsApiDeleteEnvironmentV2Opts) (ResponseDtoBoolean, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Delete") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoBoolean + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/environmentsV2/{environmentIdentifier}" + localVarPath = strings.Replace(localVarPath, "{"+"environmentIdentifier"+"}", fmt.Sprintf("%v", environmentIdentifier), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { + localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoBoolean + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +EnvironmentsApiService Gets Environment Access list + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *EnvironmentsApiGetEnvironmentAccessListOpts - Optional Parameters: + * @param "Page" (optional.Int32) - page + * @param "Size" (optional.Int32) - size + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "SearchTerm" (optional.String) - The word to be searched and included in the list response + * @param "EnvIdentifiers" (optional.Interface of []string) - List of EnvironmentIds + * @param "Sort" (optional.Interface of []string) - Specifies sorting criteria of the list. Like sorting based on the last updated entity, alphabetical sorting in an ascending or descending order +@return ResponseDtoListEnvironmentResponse +*/ + +type EnvironmentsApiGetEnvironmentAccessListOpts struct { + Page optional.Int32 + Size optional.Int32 + OrgIdentifier optional.String + ProjectIdentifier optional.String + SearchTerm optional.String + EnvIdentifiers optional.Interface + Sort optional.Interface +} + +func (a *EnvironmentsApiService) GetEnvironmentAccessList(ctx context.Context, accountIdentifier string, localVarOptionals *EnvironmentsApiGetEnvironmentAccessListOpts) (ResponseDtoListEnvironmentResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoListEnvironmentResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/environmentsV2/list/access" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.Page.IsSet() { + localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Size.IsSet() { + localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) + } + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { + localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.EnvIdentifiers.IsSet() { + localVarQueryParams.Add("envIdentifiers", parameterToString(localVarOptionals.EnvIdentifiers.Value(), "multi")) + } + if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { + localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoListEnvironmentResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +EnvironmentsApiService Gets Environment list for a project + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *EnvironmentsApiGetEnvironmentListOpts - Optional Parameters: + * @param "Page" (optional.Int32) - The number of the page to fetch + * @param "Size" (optional.Int32) - The number of the elements to fetch + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "SearchTerm" (optional.String) - The word to be searched and included in the list response + * @param "EnvIdentifiers" (optional.Interface of []string) - List of EnvironmentIds + * @param "Sort" (optional.Interface of []string) - Specifies sorting criteria of the list. Like sorting based on the last updated entity, alphabetical sorting in an ascending or descending order +@return ResponseDtoPageResponseEnvironmentResponse +*/ + +type EnvironmentsApiGetEnvironmentListOpts struct { + Page optional.Int32 + Size optional.Int32 + OrgIdentifier optional.String + ProjectIdentifier optional.String + SearchTerm optional.String + EnvIdentifiers optional.Interface + Sort optional.Interface +} + +func (a *EnvironmentsApiService) GetEnvironmentList(ctx context.Context, accountIdentifier string, localVarOptionals *EnvironmentsApiGetEnvironmentListOpts) (ResponseDtoPageResponseEnvironmentResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoPageResponseEnvironmentResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/environmentsV2" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.Page.IsSet() { + localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Size.IsSet() { + localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) + } + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { + localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.EnvIdentifiers.IsSet() { + localVarQueryParams.Add("envIdentifiers", parameterToString(localVarOptionals.EnvIdentifiers.Value(), "multi")) + } + if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { + localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoPageResponseEnvironmentResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +EnvironmentsApiService Gets an Environment by identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param environmentIdentifier Environment Identifier for the entity + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *EnvironmentsApiGetEnvironmentV2Opts - Optional Parameters: + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Deleted" (optional.Bool) - Specify whether Environment is deleted or not +@return ResponseDtoEnvironmentResponse +*/ + +type EnvironmentsApiGetEnvironmentV2Opts struct { + OrgIdentifier optional.String + ProjectIdentifier optional.String + Deleted optional.Bool +} + +func (a *EnvironmentsApiService) GetEnvironmentV2(ctx context.Context, environmentIdentifier string, accountIdentifier string, localVarOptionals *EnvironmentsApiGetEnvironmentV2Opts) (ResponseDtoEnvironmentResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoEnvironmentResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/environmentsV2/{environmentIdentifier}" + localVarPath = strings.Replace(localVarPath, "{"+"environmentIdentifier"+"}", fmt.Sprintf("%v", environmentIdentifier), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Deleted.IsSet() { + localVarQueryParams.Add("deleted", parameterToString(localVarOptionals.Deleted.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoEnvironmentResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +EnvironmentsApiService Update an Environment by identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *EnvironmentsApiUpdateEnvironmentV2Opts - Optional Parameters: + * @param "Body" (optional.Interface of EnvironmentRequest) - Details of the Environment to be updated + * @param "IfMatch" (optional.String) - +@return ResponseDtoEnvironmentResponse +*/ + +type EnvironmentsApiUpdateEnvironmentV2Opts struct { + Body optional.Interface + IfMatch optional.String +} + +func (a *EnvironmentsApiService) UpdateEnvironmentV2(ctx context.Context, accountIdentifier string, localVarOptionals *EnvironmentsApiUpdateEnvironmentV2Opts) (ResponseDtoEnvironmentResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Put") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoEnvironmentResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/environmentsV2" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "application/yaml"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { + localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoEnvironmentResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +EnvironmentsApiService Upsert an Environment by identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *EnvironmentsApiUpsertEnvironmentV2Opts - Optional Parameters: + * @param "Body" (optional.Interface of EnvironmentRequest) - Details of the Environment to be updated + * @param "IfMatch" (optional.String) - +@return ResponseDtoEnvironmentResponse +*/ + +type EnvironmentsApiUpsertEnvironmentV2Opts struct { + Body optional.Interface + IfMatch optional.String +} + +func (a *EnvironmentsApiService) UpsertEnvironmentV2(ctx context.Context, accountIdentifier string, localVarOptionals *EnvironmentsApiUpsertEnvironmentV2Opts) (ResponseDtoEnvironmentResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Put") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoEnvironmentResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/environmentsV2/upsert" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "application/yaml"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { + localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoEnvironmentResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_filter.go b/harness/nextgen/api_filter.go new file mode 100644 index 00000000..038a496e --- /dev/null +++ b/harness/nextgen/api_filter.go @@ -0,0 +1,638 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "fmt" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type FilterApiService service + +/* +FilterApiService Delete a Filter by identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param identifier Filter Identifier + * @param type_ Type of Filter + * @param optional nil or *FilterApiDeleteFilterOpts - Optional Parameters: + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity +@return ResponseDtoBoolean +*/ + +type FilterApiDeleteFilterOpts struct { + AccountIdentifier optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String +} + +func (a *FilterApiService) DeleteFilter(ctx context.Context, identifier string, type_ string, localVarOptionals *FilterApiDeleteFilterOpts) (ResponseDtoBoolean, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Delete") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoBoolean + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/filters/{identifier}" + localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + localVarQueryParams.Add("type", parameterToString(type_, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoBoolean + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +FilterApiService Get the list of Filters satisfying the criteria (if any) in the request + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param type_ Type of Filter + * @param optional nil or *FilterApiGetConnectorListV21Opts - Optional Parameters: + * @param "PageIndex" (optional.Int32) - Page number of navigation. If left empty, default value of 0 is assumed + * @param "PageSize" (optional.Int32) - Number of entries per page. If left empty, default value of 100 is assumed + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity +@return ResponseDtoPageResponseFilter +*/ + +type FilterApiGetConnectorListV21Opts struct { + PageIndex optional.Int32 + PageSize optional.Int32 + OrgIdentifier optional.String + ProjectIdentifier optional.String +} + +func (a *FilterApiService) GetConnectorListV21(ctx context.Context, accountIdentifier string, type_ string, localVarOptionals *FilterApiGetConnectorListV21Opts) (ResponseDtoPageResponseFilter, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoPageResponseFilter + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/filters" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { + localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { + localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) + } + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + localVarQueryParams.Add("type", parameterToString(type_, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoPageResponseFilter + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +FilterApiService Gets a Filter by identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param identifier Filter Identifier + * @param type_ Type of Filter + * @param optional nil or *FilterApiGetFilterOpts - Optional Parameters: + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity +@return ResponseDtoFilter +*/ + +type FilterApiGetFilterOpts struct { + AccountIdentifier optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String +} + +func (a *FilterApiService) GetFilter(ctx context.Context, identifier string, type_ string, localVarOptionals *FilterApiGetFilterOpts) (ResponseDtoFilter, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoFilter + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/filters/{identifier}" + localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + localVarQueryParams.Add("type", parameterToString(type_, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoFilter + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +FilterApiService Creates a Filter + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param body Details of the Connector to create + * @param accountIdentifier Account Identifier for the entity +@return ResponseDtoFilter +*/ +func (a *FilterApiService) PostFilter(ctx context.Context, body Filter, accountIdentifier string) (ResponseDtoFilter, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoFilter + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/filters" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html", "text/plain"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + localVarPostBody = &body + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoFilter + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +FilterApiService Updates the Filter + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param body This is the updated Filter. This should have all the fields not just the updated ones + * @param optional nil or *FilterApiUpdateFilterOpts - Optional Parameters: + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity +@return ResponseDtoFilter +*/ + +type FilterApiUpdateFilterOpts struct { + AccountIdentifier optional.String +} + +func (a *FilterApiService) UpdateFilter(ctx context.Context, body Filter, localVarOptionals *FilterApiUpdateFilterOpts) (ResponseDtoFilter, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Put") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoFilter + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/filters" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html", "text/plain"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + localVarPostBody = &body + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoFilter + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_full_sync.go b/harness/nextgen/api_full_sync.go new file mode 100644 index 00000000..d1d3e4a9 --- /dev/null +++ b/harness/nextgen/api_full_sync.go @@ -0,0 +1,158 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type FullSyncApiService service + +/* +FullSyncApiService Triggers Full Sync + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *FullSyncApiTriggerFullSyncOpts - Optional Parameters: + * @param "Body" (optional.Interface of FullSyncRequest) - The Full Sync Request + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity +@return ResponseDtoTriggerFullSyncResponse +*/ + +type FullSyncApiTriggerFullSyncOpts struct { + Body optional.Interface + AccountIdentifier optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String +} + +func (a *FullSyncApiService) TriggerFullSync(ctx context.Context, localVarOptionals *FullSyncApiTriggerFullSyncOpts) (ResponseDtoTriggerFullSyncResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoTriggerFullSyncResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/full-sync" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoTriggerFullSyncResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_gcp_clusters.go b/harness/nextgen/api_gcp_clusters.go index 11990bb3..ea218bcb 100644 --- a/harness/nextgen/api_gcp_clusters.go +++ b/harness/nextgen/api_gcp_clusters.go @@ -29,9 +29,9 @@ type GcpClustersApiService service /* GcpClustersApiService Gets gcp cluster names * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier - * @param orgIdentifier - * @param projectIdentifier + * @param accountIdentifier Account Identifier for the entity + * @param orgIdentifier Organization Identifier for the entity + * @param projectIdentifier Project Identifier for the entity * @param optional nil or *GcpClustersApiGetClusterNamesForGcpOpts - Optional Parameters: * @param "ConnectorRef" (optional.String) - @return ResponseDtoGcpResponse diff --git a/harness/nextgen/api_git_branches.go b/harness/nextgen/api_git_branches.go new file mode 100644 index 00000000..73d52658 --- /dev/null +++ b/harness/nextgen/api_git_branches.go @@ -0,0 +1,302 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type GitBranchesApiService service + +/* +GitBranchesApiService Lists branches with their status(Synced, Unsynced) by Git Sync Config Identifier for the given scope + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param yamlGitConfigIdentifier Git Sync Config Id + * @param optional nil or *GitBranchesApiGetListOfBranchesWithStatusOpts - Optional Parameters: + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Page" (optional.Int32) - The number of the page to fetch + * @param "Size" (optional.Int32) - The number of the elements to fetch + * @param "SearchTerm" (optional.String) - Search Term + * @param "BranchSyncStatus" (optional.String) - Used to filter out Synced and Unsynced branches +@return ResponseDtoGitBranchList +*/ + +type GitBranchesApiGetListOfBranchesWithStatusOpts struct { + AccountIdentifier optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String + Page optional.Int32 + Size optional.Int32 + SearchTerm optional.String + BranchSyncStatus optional.String +} + +func (a *GitBranchesApiService) GetListOfBranchesWithStatus(ctx context.Context, yamlGitConfigIdentifier string, localVarOptionals *GitBranchesApiGetListOfBranchesWithStatusOpts) (ResponseDtoGitBranchList, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoGitBranchList + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-branch/listBranchesWithStatus" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("yamlGitConfigIdentifier", parameterToString(yamlGitConfigIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Page.IsSet() { + localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Size.IsSet() { + localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { + localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.BranchSyncStatus.IsSet() { + localVarQueryParams.Add("branchSyncStatus", parameterToString(localVarOptionals.BranchSyncStatus.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoGitBranchList + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitBranchesApiService Sync the content of new Git Branch into harness with Git Sync Config Identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param repoIdentifier Git Sync Config Id + * @param optional nil or *GitBranchesApiSyncGitBranchOpts - Optional Parameters: + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Branch" (optional.String) - Branch Name +@return ResponseDtoBoolean +*/ + +type GitBranchesApiSyncGitBranchOpts struct { + AccountIdentifier optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String + Branch optional.String +} + +func (a *GitBranchesApiService) SyncGitBranch(ctx context.Context, repoIdentifier string, localVarOptionals *GitBranchesApiSyncGitBranchOpts) (ResponseDtoBoolean, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoBoolean + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-branch/sync" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("repoIdentifier", parameterToString(repoIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { + localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoBoolean + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_git_sync.go b/harness/nextgen/api_git_sync.go new file mode 100644 index 00000000..62ca649b --- /dev/null +++ b/harness/nextgen/api_git_sync.go @@ -0,0 +1,633 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "fmt" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type GitSyncApiService service + +/* +GitSyncApiService Creates Git Sync Config in given scope + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param body Details of Git Sync Config + * @param optional nil or *GitSyncApiCreateGitSyncConfigOpts - Optional Parameters: + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity +@return GitSyncConfig +*/ + +type GitSyncApiCreateGitSyncConfigOpts struct { + AccountIdentifier optional.String +} + +func (a *GitSyncApiService) CreateGitSyncConfig(ctx context.Context, body GitSyncConfig, localVarOptionals *GitSyncApiCreateGitSyncConfigOpts) (GitSyncConfig, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue GitSyncConfig + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html", "text/plain"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + localVarPostBody = &body + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v GitSyncConfig + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitSyncApiService Lists Git Sync Config for the given scope + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *GitSyncApiGetGitSyncConfigListOpts - Optional Parameters: + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity +@return []GitSyncConfig +*/ + +type GitSyncApiGetGitSyncConfigListOpts struct { + ProjectIdentifier optional.String + OrgIdentifier optional.String + AccountIdentifier optional.String +} + +func (a *GitSyncApiService) GetGitSyncConfigList(ctx context.Context, localVarOptionals *GitSyncApiGetGitSyncConfigListOpts) ([]GitSyncConfig, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue []GitSyncConfig + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v []GitSyncConfig + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitSyncApiService Check whether Git Sync is enabled for given scope or not + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *GitSyncApiIsGitSyncEnabledOpts - Optional Parameters: + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity +@return GitEnabled +*/ + +type GitSyncApiIsGitSyncEnabledOpts struct { + AccountIdentifier optional.String + ProjectIdentifier optional.String + OrgIdentifier optional.String +} + +func (a *GitSyncApiService) IsGitSyncEnabled(ctx context.Context, localVarOptionals *GitSyncApiIsGitSyncEnabledOpts) (GitEnabled, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue GitEnabled + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync/git-sync-enabled" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v GitEnabled + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitSyncApiService Update existing Git Sync Config default root folder by Identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param identifier Git Sync Config Id + * @param folderIdentifier Folder Id + * @param optional nil or *GitSyncApiUpdateDefaultFolderOpts - Optional Parameters: + * @param "ProjectId" (optional.String) - Project Identifier for the entity + * @param "OrganizationId" (optional.String) - Organization Identifier for the entity + * @param "AccountId" (optional.String) - Account Identifier for the entity +@return GitSyncConfig +*/ + +type GitSyncApiUpdateDefaultFolderOpts struct { + ProjectId optional.String + OrganizationId optional.String + AccountId optional.String +} + +func (a *GitSyncApiService) UpdateDefaultFolder(ctx context.Context, identifier string, folderIdentifier string, localVarOptionals *GitSyncApiUpdateDefaultFolderOpts) (GitSyncConfig, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Put") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue GitSyncConfig + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync/{identifier}/folder/{folderIdentifier}/default" + localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) + localVarPath = strings.Replace(localVarPath, "{"+"folderIdentifier"+"}", fmt.Sprintf("%v", folderIdentifier), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.ProjectId.IsSet() { + localVarQueryParams.Add("projectId", parameterToString(localVarOptionals.ProjectId.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrganizationId.IsSet() { + localVarQueryParams.Add("organizationId", parameterToString(localVarOptionals.OrganizationId.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.AccountId.IsSet() { + localVarQueryParams.Add("accountId", parameterToString(localVarOptionals.AccountId.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v GitSyncConfig + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitSyncApiService Update existing Git Sync Config by Identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param body Details of Git Sync Config + * @param optional nil or *GitSyncApiUpdateGitSyncConfigOpts - Optional Parameters: + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity +@return GitSyncConfig +*/ + +type GitSyncApiUpdateGitSyncConfigOpts struct { + AccountIdentifier optional.String +} + +func (a *GitSyncApiService) UpdateGitSyncConfig(ctx context.Context, body GitSyncConfig, localVarOptionals *GitSyncApiUpdateGitSyncConfigOpts) (GitSyncConfig, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Put") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue GitSyncConfig + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html", "text/plain"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + localVarPostBody = &body + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v GitSyncConfig + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_git_sync_entities.go b/harness/nextgen/api_git_sync_entities.go new file mode 100644 index 00000000..f7df8de8 --- /dev/null +++ b/harness/nextgen/api_git_sync_entities.go @@ -0,0 +1,447 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "fmt" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type GitSyncEntitiesApiService service + +/* +GitSyncEntitiesApiService Lists Git Sync Entity filtered by their Type for the given scope + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param entityType Entity Type + * @param optional nil or *GitSyncEntitiesApiListGitSyncEntitiesByTypeOpts - Optional Parameters: + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "GitSyncConfigId" (optional.String) - Git Sync Config Id + * @param "Branch" (optional.String) - Branch Name + * @param "Page" (optional.Int32) - The number of the page to fetch + * @param "Size" (optional.Int32) - The number of the elements to fetch + * @param "ModuleType" (optional.String) - Module Type +@return ResponseDtoPageResponseGitSyncEntityList +*/ + +type GitSyncEntitiesApiListGitSyncEntitiesByTypeOpts struct { + ProjectIdentifier optional.String + OrgIdentifier optional.String + AccountIdentifier optional.String + GitSyncConfigId optional.String + Branch optional.String + Page optional.Int32 + Size optional.Int32 + ModuleType optional.String +} + +func (a *GitSyncEntitiesApiService) ListGitSyncEntitiesByType(ctx context.Context, entityType string, localVarOptionals *GitSyncEntitiesApiListGitSyncEntitiesByTypeOpts) (ResponseDtoPageResponseGitSyncEntityList, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoPageResponseGitSyncEntityList + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-entities/{entityType}" + localVarPath = strings.Replace(localVarPath, "{"+"entityType"+"}", fmt.Sprintf("%v", entityType), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.GitSyncConfigId.IsSet() { + localVarQueryParams.Add("gitSyncConfigId", parameterToString(localVarOptionals.GitSyncConfigId.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { + localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Page.IsSet() { + localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Size.IsSet() { + localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ModuleType.IsSet() { + localVarQueryParams.Add("moduleType", parameterToString(localVarOptionals.ModuleType.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoPageResponseGitSyncEntityList + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitSyncEntitiesApiService Lists Git Sync Entity by product for the given Repo, Branch and list of Entity Types + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param body Filter Git Sync Entity based on multiple parameters + * @param branch Branch Name + * @param optional nil or *GitSyncEntitiesApiListGitSyncEntitiesSummaryForRepoAndBranchOpts - Optional Parameters: + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "Size" (optional.Int32) - The number of the elements to fetch + * @param "GitSyncConfigId" (optional.String) - Git Sync Config Id +@return ResponseDtoListGitSyncEntityList +*/ + +type GitSyncEntitiesApiListGitSyncEntitiesSummaryForRepoAndBranchOpts struct { + ProjectIdentifier optional.String + OrgIdentifier optional.String + AccountIdentifier optional.String + Size optional.Int32 + GitSyncConfigId optional.String +} + +func (a *GitSyncEntitiesApiService) ListGitSyncEntitiesSummaryForRepoAndBranch(ctx context.Context, body GitEntityBranchSummaryFilter, branch string, localVarOptionals *GitSyncEntitiesApiListGitSyncEntitiesSummaryForRepoAndBranchOpts) (ResponseDtoListGitSyncEntityList, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoListGitSyncEntityList + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-entities/branch/{branch}" + localVarPath = strings.Replace(localVarPath, "{"+"branch"+"}", fmt.Sprintf("%v", branch), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Size.IsSet() { + localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.GitSyncConfigId.IsSet() { + localVarQueryParams.Add("gitSyncConfigId", parameterToString(localVarOptionals.GitSyncConfigId.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + localVarPostBody = &body + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoListGitSyncEntityList + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitSyncEntitiesApiService Lists Git Sync Entity by product for the given list of Repos and Entity Types + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param body Filter Git Sync Entity based on multiple parameters + * @param optional nil or *GitSyncEntitiesApiListGitSyncEntitiesSummaryForRepoAndTypesOpts - Optional Parameters: + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "Size" (optional.Int32) - The number of the elements to fetch +@return ResponseDtoGitSyncRepoFilesList +*/ + +type GitSyncEntitiesApiListGitSyncEntitiesSummaryForRepoAndTypesOpts struct { + ProjectIdentifier optional.String + OrgIdentifier optional.String + AccountIdentifier optional.String + Size optional.Int32 +} + +func (a *GitSyncEntitiesApiService) ListGitSyncEntitiesSummaryForRepoAndTypes(ctx context.Context, body GitEntitySummaryFilter, localVarOptionals *GitSyncEntitiesApiListGitSyncEntitiesSummaryForRepoAndTypesOpts) (ResponseDtoGitSyncRepoFilesList, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoGitSyncRepoFilesList + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-entities/summary" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Size.IsSet() { + localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + localVarPostBody = &body + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoGitSyncRepoFilesList + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_git_sync_errors.go b/harness/nextgen/api_git_sync_errors.go new file mode 100644 index 00000000..a5549e5f --- /dev/null +++ b/harness/nextgen/api_git_sync_errors.go @@ -0,0 +1,652 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "fmt" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type GitSyncErrorsApiService service + +/* +GitSyncErrorsApiService Get Errors Count for the given scope, Repo and Branch + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *GitSyncErrorsApiGetGitSyncErrorsCountOpts - Optional Parameters: + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "SearchTerm" (optional.String) - Search Term + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "GetDefaultFromOtherRepo" (optional.Bool) - if true, return all the default entities +@return ResponseDtoGitSyncErrorCount +*/ + +type GitSyncErrorsApiGetGitSyncErrorsCountOpts struct { + AccountIdentifier optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String + SearchTerm optional.String + Branch optional.String + RepoIdentifier optional.String + GetDefaultFromOtherRepo optional.Bool +} + +func (a *GitSyncErrorsApiService) GetGitSyncErrorsCount(ctx context.Context, localVarOptionals *GitSyncErrorsApiGetGitSyncErrorsCountOpts) (ResponseDtoGitSyncErrorCount, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoGitSyncErrorCount + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-errors/count" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { + localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { + localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { + localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { + localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoGitSyncErrorCount + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitSyncErrorsApiService Lists Git to Harness Errors by file or connectivity errors for the given scope, Repo and Branch + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *GitSyncErrorsApiListGitSyncErrorsOpts - Optional Parameters: + * @param "PageIndex" (optional.Int32) - + * @param "PageSize" (optional.Int32) - + * @param "SortOrders" (optional.Interface of []SortOrder) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "SearchTerm" (optional.String) - Search Term + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "GetDefaultFromOtherRepo" (optional.Bool) - if true, return all the default entities + * @param "GitToHarness" (optional.Bool) - This specifies which errors to show - (Git to Harness or Connectivity), Put true to show Git to Harness Errors +@return ResponseDtoPageResponseGitSyncError +*/ + +type GitSyncErrorsApiListGitSyncErrorsOpts struct { + PageIndex optional.Int32 + PageSize optional.Int32 + SortOrders optional.Interface + AccountIdentifier optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String + SearchTerm optional.String + Branch optional.String + RepoIdentifier optional.String + GetDefaultFromOtherRepo optional.Bool + GitToHarness optional.Bool +} + +func (a *GitSyncErrorsApiService) ListGitSyncErrors(ctx context.Context, localVarOptionals *GitSyncErrorsApiListGitSyncErrorsOpts) (ResponseDtoPageResponseGitSyncError, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoPageResponseGitSyncError + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-errors" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { + localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { + localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { + localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) + } + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { + localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { + localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { + localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { + localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.GitToHarness.IsSet() { + localVarQueryParams.Add("gitToHarness", parameterToString(localVarOptionals.GitToHarness.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoPageResponseGitSyncError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitSyncErrorsApiService Lists Git to Harness Errors for the given Commit Id + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param commitId Commit Id + * @param optional nil or *GitSyncErrorsApiListGitToHarnessErrorForCommitOpts - Optional Parameters: + * @param "PageIndex" (optional.Int32) - + * @param "PageSize" (optional.Int32) - + * @param "SortOrders" (optional.Interface of []SortOrder) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "GetDefaultFromOtherRepo" (optional.Bool) - if true, return all the default entities +@return ResponseDtoPageResponseGitSyncError +*/ + +type GitSyncErrorsApiListGitToHarnessErrorForCommitOpts struct { + PageIndex optional.Int32 + PageSize optional.Int32 + SortOrders optional.Interface + AccountIdentifier optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String + Branch optional.String + RepoIdentifier optional.String + GetDefaultFromOtherRepo optional.Bool +} + +func (a *GitSyncErrorsApiService) ListGitToHarnessErrorForCommit(ctx context.Context, commitId string, localVarOptionals *GitSyncErrorsApiListGitToHarnessErrorForCommitOpts) (ResponseDtoPageResponseGitSyncError, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoPageResponseGitSyncError + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-errors/commits/{commitId}" + localVarPath = strings.Replace(localVarPath, "{"+"commitId"+"}", fmt.Sprintf("%v", commitId), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { + localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { + localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { + localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) + } + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { + localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { + localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { + localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoPageResponseGitSyncError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitSyncErrorsApiService Lists Git to Harness Errors grouped by Commits for the given scope, Repo and Branch + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *GitSyncErrorsApiListGitToHarnessErrorsGroupedByCommitsOpts - Optional Parameters: + * @param "PageIndex" (optional.Int32) - + * @param "PageSize" (optional.Int32) - + * @param "SortOrders" (optional.Interface of []SortOrder) - + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "SearchTerm" (optional.String) - Search Term + * @param "Branch" (optional.String) - Branch Name + * @param "RepoIdentifier" (optional.String) - Git Sync Config Identifier + * @param "GetDefaultFromOtherRepo" (optional.Bool) - if true, return all the default entities + * @param "NumberOfErrorsInSummary" (optional.Int32) - This is the count of errors to be displayed in the summary +@return ResponseDtoPageResponseGitSyncErrorAggregateByCommit +*/ + +type GitSyncErrorsApiListGitToHarnessErrorsGroupedByCommitsOpts struct { + PageIndex optional.Int32 + PageSize optional.Int32 + SortOrders optional.Interface + AccountIdentifier optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String + SearchTerm optional.String + Branch optional.String + RepoIdentifier optional.String + GetDefaultFromOtherRepo optional.Bool + NumberOfErrorsInSummary optional.Int32 +} + +func (a *GitSyncErrorsApiService) ListGitToHarnessErrorsGroupedByCommits(ctx context.Context, localVarOptionals *GitSyncErrorsApiListGitToHarnessErrorsGroupedByCommitsOpts) (ResponseDtoPageResponseGitSyncErrorAggregateByCommit, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoPageResponseGitSyncErrorAggregateByCommit + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-errors/aggregate" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { + localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { + localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { + localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) + } + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { + localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { + localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.RepoIdentifier.IsSet() { + localVarQueryParams.Add("repoIdentifier", parameterToString(localVarOptionals.RepoIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.GetDefaultFromOtherRepo.IsSet() { + localVarQueryParams.Add("getDefaultFromOtherRepo", parameterToString(localVarOptionals.GetDefaultFromOtherRepo.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.NumberOfErrorsInSummary.IsSet() { + localVarQueryParams.Add("numberOfErrorsInSummary", parameterToString(localVarOptionals.NumberOfErrorsInSummary.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoPageResponseGitSyncErrorAggregateByCommit + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_git_sync_settings.go b/harness/nextgen/api_git_sync_settings.go new file mode 100644 index 00000000..b558f679 --- /dev/null +++ b/harness/nextgen/api_git_sync_settings.go @@ -0,0 +1,362 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type GitSyncSettingsApiService service + +/* +GitSyncSettingsApiService Creates Git Sync Setting in a scope + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param body This contains details of Git Sync settings like - (scope, executionOnDelegate) +@return ResponseDtoGitSyncSettings +*/ +func (a *GitSyncSettingsApiService) CreateGitSyncSetting(ctx context.Context, body GitSyncSettings) (ResponseDtoGitSyncSettings, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoGitSyncSettings + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-settings" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + localVarPostBody = &body + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoGitSyncSettings + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitSyncSettingsApiService Get Git Sync Setting for the given scope + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *GitSyncSettingsApiGetGitSyncSettingsOpts - Optional Parameters: + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity +@return ResponseDtoGitSyncSettings +*/ + +type GitSyncSettingsApiGetGitSyncSettingsOpts struct { + ProjectIdentifier optional.String + OrgIdentifier optional.String + AccountIdentifier optional.String +} + +func (a *GitSyncSettingsApiService) GetGitSyncSettings(ctx context.Context, localVarOptionals *GitSyncSettingsApiGetGitSyncSettingsOpts) (ResponseDtoGitSyncSettings, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoGitSyncSettings + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-settings" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoGitSyncSettings + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +GitSyncSettingsApiService Update existing Git Sync Setting by scope. Only changing execution on delegate is allowed + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param body Git Sync Setting details, including: scope, executionOnDelegate +@return ResponseDtoGitSyncSettings +*/ +func (a *GitSyncSettingsApiService) UpdateGitSyncSetting(ctx context.Context, body GitSyncSettings) (ResponseDtoGitSyncSettings, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Put") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoGitSyncSettings + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/git-sync-settings" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + localVarPostBody = &body + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoGitSyncSettings + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_invite.go b/harness/nextgen/api_invite.go new file mode 100644 index 00000000..a1727662 --- /dev/null +++ b/harness/nextgen/api_invite.go @@ -0,0 +1,1064 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "fmt" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type InviteApiService service + +/* +InviteApiService + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param token + +*/ +func (a *InviteApiService) Accept(ctx context.Context, token string) (*http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/invites/accept" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("token", parameterToString(token, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarHttpResponse, newErr + } + newErr.model = v + return localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarHttpResponse, newErr + } + newErr.model = v + return localVarHttpResponse, newErr + } + return localVarHttpResponse, newErr + } + + return localVarHttpResponse, nil +} + +/* +InviteApiService Complete the User Invite + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *InviteApiCompleteInviteOpts - Optional Parameters: + * @param "Token" (optional.String) - JWT Tokenn +@return ResponseDtoBoolean +*/ + +type InviteApiCompleteInviteOpts struct { + Token optional.String +} + +func (a *InviteApiService) CompleteInvite(ctx context.Context, localVarOptionals *InviteApiCompleteInviteOpts) (ResponseDtoBoolean, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoBoolean + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/invites/complete" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.Token.IsSet() { + localVarQueryParams.Add("token", parameterToString(localVarOptionals.Token.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoBoolean + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +InviteApiService Delete an Invite by Identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param inviteId Invite Id +@return ResponseDtoOptionalInvite +*/ +func (a *InviteApiService) DeleteInvite(ctx context.Context, inviteId string) (ResponseDtoOptionalInvite, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Delete") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoOptionalInvite + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/invites/{inviteId}" + localVarPath = strings.Replace(localVarPath, "{"+"inviteId"+"}", fmt.Sprintf("%v", inviteId), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoOptionalInvite + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +InviteApiService Gets an Invite by either Invite Id or JwtToken + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *InviteApiGetInviteOpts - Optional Parameters: + * @param "InviteId" (optional.String) - Invitation Id + * @param "Jwttoken" (optional.String) - JWT Token +@return ResponseDtoInvite +*/ + +type InviteApiGetInviteOpts struct { + InviteId optional.String + Jwttoken optional.String +} + +func (a *InviteApiService) GetInvite(ctx context.Context, localVarOptionals *InviteApiGetInviteOpts) (ResponseDtoInvite, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoInvite + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/invites/invite" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.InviteId.IsSet() { + localVarQueryParams.Add("inviteId", parameterToString(localVarOptionals.InviteId.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Jwttoken.IsSet() { + localVarQueryParams.Add("jwttoken", parameterToString(localVarOptionals.Jwttoken.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoInvite + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +InviteApiService List all the Invites for a Project or Organization + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *InviteApiGetInvitesOpts - Optional Parameters: + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "PageIndex" (optional.Int32) - + * @param "PageSize" (optional.Int32) - + * @param "SortOrders" (optional.Interface of []SortOrder) - +@return ResponseDtoPageResponseInvite +*/ + +type InviteApiGetInvitesOpts struct { + OrgIdentifier optional.String + ProjectIdentifier optional.String + PageIndex optional.Int32 + PageSize optional.Int32 + SortOrders optional.Interface +} + +func (a *InviteApiService) GetInvites(ctx context.Context, accountIdentifier string, localVarOptionals *InviteApiGetInvitesOpts) (ResponseDtoPageResponseInvite, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoPageResponseInvite + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/invites" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { + localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { + localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { + localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoPageResponseInvite + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +InviteApiService List of all the Invites pending users + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *InviteApiGetPendingUsersAggregatedOpts - Optional Parameters: + * @param "Body" (optional.Interface of AclAggregateFilter) - + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "SearchTerm" (optional.String) - Search term + * @param "PageIndex" (optional.Int32) - + * @param "PageSize" (optional.Int32) - + * @param "SortOrders" (optional.Interface of []SortOrder) - +@return ResponseDtoPageResponseInvite +*/ + +type InviteApiGetPendingUsersAggregatedOpts struct { + Body optional.Interface + OrgIdentifier optional.String + ProjectIdentifier optional.String + SearchTerm optional.String + PageIndex optional.Int32 + PageSize optional.Int32 + SortOrders optional.Interface +} + +func (a *InviteApiService) GetPendingUsersAggregated(ctx context.Context, accountIdentifier string, localVarOptionals *InviteApiGetPendingUsersAggregatedOpts) (ResponseDtoPageResponseInvite, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoPageResponseInvite + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/invites/aggregate" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { + localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.PageIndex.IsSet() { + localVarQueryParams.Add("pageIndex", parameterToString(localVarOptionals.PageIndex.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.PageSize.IsSet() { + localVarQueryParams.Add("pageSize", parameterToString(localVarOptionals.PageSize.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SortOrders.IsSet() { + localVarQueryParams.Add("sortOrders", parameterToString(localVarOptionals.SortOrders.Value(), "multi")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoPageResponseInvite + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +InviteApiService Send a user Invite to either Project or Organization + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param body Details of the Invite to create + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *InviteApiSendInviteOpts - Optional Parameters: + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity +@return ResponseDtoListInviteOperationResponse +*/ + +type InviteApiSendInviteOpts struct { + OrgIdentifier optional.String + ProjectIdentifier optional.String +} + +func (a *InviteApiService) SendInvite(ctx context.Context, body CreateInvite, accountIdentifier string, localVarOptionals *InviteApiSendInviteOpts) (ResponseDtoListInviteOperationResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoListInviteOperationResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/invites" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + localVarPostBody = &body + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoListInviteOperationResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +InviteApiService Resend the Invite email + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param body Details of the Updated Invite + * @param inviteId Invite id + * @param optional nil or *InviteApiUpdateInviteOpts - Optional Parameters: + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity +@return ResponseDtoOptionalInvite +*/ + +type InviteApiUpdateInviteOpts struct { + AccountIdentifier optional.String +} + +func (a *InviteApiService) UpdateInvite(ctx context.Context, body Invite, inviteId string, localVarOptionals *InviteApiUpdateInviteOpts) (ResponseDtoOptionalInvite, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Put") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoOptionalInvite + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/invites/{inviteId}" + localVarPath = strings.Replace(localVarPath, "{"+"inviteId"+"}", fmt.Sprintf("%v", inviteId), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + localVarPostBody = &body + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoOptionalInvite + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +InviteApiService + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param token + * @param accountIdentifier + * @param email + +*/ +func (a *InviteApiService) VerifyInviteViaNGAuthUi(ctx context.Context, token string, accountIdentifier string, email string) (*http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/invites/verify" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("token", parameterToString(token, "")) + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + localVarQueryParams.Add("email", parameterToString(email, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarHttpResponse, newErr + } + newErr.model = v + return localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarHttpResponse, newErr + } + newErr.model = v + return localVarHttpResponse, newErr + } + return localVarHttpResponse, newErr + } + + return localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_licenses.go b/harness/nextgen/api_licenses.go index c223d718..02d265c7 100644 --- a/harness/nextgen/api_licenses.go +++ b/harness/nextgen/api_licenses.go @@ -27,92 +27,6 @@ var ( type LicensesApiService service -/* -LicensesApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountId - -*/ -func (a *LicensesApiService) CheckExpiry(ctx context.Context, accountId string) (*http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/licenses/{accountId}/check-expiry" - localVarPath = strings.Replace(localVarPath, "{"+"accountId"+"}", fmt.Sprintf("%v", accountId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 400 { - var v ModelError - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarHttpResponse, newErr - } - newErr.model = v - return localVarHttpResponse, newErr - } - if localVarHttpResponse.StatusCode == 500 { - var v ModelError - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarHttpResponse, newErr - } - newErr.model = v - return localVarHttpResponse, newErr - } - return localVarHttpResponse, newErr - } - - return localVarHttpResponse, nil -} - /* LicensesApiService Extends Trial License For A Module * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). @@ -339,15 +253,15 @@ LicensesApiService Get Allowed Actions Under Each Edition * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). * @param accountIdentifier Account id to get the allowed actions. * @param moduleType A Harness Platform module. -@return ResponseDtoMapEditionSetEditionActionDto +@return ResponseDtoMapEditionSetEditionAction */ -func (a *LicensesApiService) GetEditionActions(ctx context.Context, accountIdentifier string, moduleType string) (ResponseDtoMapEditionSetEditionActionDto, *http.Response, error) { +func (a *LicensesApiService) GetEditionActions(ctx context.Context, accountIdentifier string, moduleType string) (ResponseDtoMapEditionSetEditionAction, *http.Response, error) { var ( localVarHttpMethod = strings.ToUpper("Get") localVarPostBody interface{} localVarFileName string localVarFileBytes []byte - localVarReturnValue ResponseDtoMapEditionSetEditionActionDto + localVarReturnValue ResponseDtoMapEditionSetEditionAction ) // create path and map variables @@ -426,7 +340,7 @@ func (a *LicensesApiService) GetEditionActions(ctx context.Context, accountIdent return localVarReturnValue, localVarHttpResponse, newErr } if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoMapEditionSetEditionActionDto + var v ResponseDtoMapEditionSetEditionAction err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() @@ -442,30 +356,28 @@ func (a *LicensesApiService) GetEditionActions(ctx context.Context, accountIdent } /* -LicensesApiService Gets Module Licenses With Summary By Account And ModuleType +LicensesApiService Get Last Modified Time Under Each ModuleType * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier Account id to get a module license with summary. - * @param moduleType A Harness Platform module. -@return ResponseDtoLicensesWithSummary + * @param accountIdentifier Account id to get the last modified map. +@return ResponseDtoMapModuleTypeLong */ -func (a *LicensesApiService) GetLicensesAndSummary(ctx context.Context, accountIdentifier string, moduleType string) (ResponseDtoLicensesWithSummary, *http.Response, error) { +func (a *LicensesApiService) GetLastModifiedTimeForAllModuleTypes(ctx context.Context, accountIdentifier string) (ResponseDtoMapModuleTypeLong, *http.Response, error) { var ( - localVarHttpMethod = strings.ToUpper("Get") + localVarHttpMethod = strings.ToUpper("Post") localVarPostBody interface{} localVarFileName string localVarFileBytes []byte - localVarReturnValue ResponseDtoLicensesWithSummary + localVarReturnValue ResponseDtoMapModuleTypeLong ) // create path and map variables - localVarPath := a.client.cfg.BasePath + "/licenses/{accountIdentifier}/summary" - localVarPath = strings.Replace(localVarPath, "{"+"accountIdentifier"+"}", fmt.Sprintf("%v", accountIdentifier), -1) + localVarPath := a.client.cfg.BasePath + "/licenses/versions" localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} localVarFormParams := url.Values{} - localVarQueryParams.Add("moduleType", parameterToString(moduleType, "")) + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) // to determine the Content-Type header localVarHttpContentTypes := []string{} @@ -533,7 +445,7 @@ func (a *LicensesApiService) GetLicensesAndSummary(ctx context.Context, accountI return localVarReturnValue, localVarHttpResponse, newErr } if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoLicensesWithSummary + var v ResponseDtoMapModuleTypeLong err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() @@ -549,29 +461,29 @@ func (a *LicensesApiService) GetLicensesAndSummary(ctx context.Context, accountI } /* -LicensesApiService Gets Module License By Account And ModuleType +LicensesApiService Gets Module Licenses With Summary By Account And ModuleType * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier Account id to get a module license. + * @param accountIdentifier Account id to get a module license with summary. * @param moduleType A Harness Platform module. -@return ResponseDtoModuleLicense +@return ResponseDtoLicensesWithSummary */ -func (a *LicensesApiService) GetModuleLicenseByAccountAndModuleType(ctx context.Context, accountIdentifier string, moduleType string) (ResponseDtoModuleLicense, *http.Response, error) { +func (a *LicensesApiService) GetLicensesAndSummary(ctx context.Context, accountIdentifier string, moduleType string) (ResponseDtoLicensesWithSummary, *http.Response, error) { var ( localVarHttpMethod = strings.ToUpper("Get") localVarPostBody interface{} localVarFileName string localVarFileBytes []byte - localVarReturnValue ResponseDtoModuleLicense + localVarReturnValue ResponseDtoLicensesWithSummary ) // create path and map variables - localVarPath := a.client.cfg.BasePath + "/licenses" + localVarPath := a.client.cfg.BasePath + "/licenses/{accountIdentifier}/summary" + localVarPath = strings.Replace(localVarPath, "{"+"accountIdentifier"+"}", fmt.Sprintf("%v", accountIdentifier), -1) localVarHeaderParams := make(map[string]string) localVarQueryParams := url.Values{} localVarFormParams := url.Values{} - localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) localVarQueryParams.Add("moduleType", parameterToString(moduleType, "")) // to determine the Content-Type header localVarHttpContentTypes := []string{} @@ -640,7 +552,7 @@ func (a *LicensesApiService) GetModuleLicenseByAccountAndModuleType(ctx context. return localVarReturnValue, localVarHttpResponse, newErr } if localVarHttpResponse.StatusCode == 0 { - var v ResponseDtoModuleLicense + var v ResponseDtoLicensesWithSummary err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) if err != nil { newErr.error = err.Error() @@ -869,92 +781,6 @@ func (a *LicensesApiService) GetModuleLicensesByAccountAndModuleType(ctx context return localVarReturnValue, localVarHttpResponse, nil } -/* -LicensesApiService - * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountId - -*/ -func (a *LicensesApiService) SoftDelete(ctx context.Context, accountId string) (*http.Response, error) { - var ( - localVarHttpMethod = strings.ToUpper("Get") - localVarPostBody interface{} - localVarFileName string - localVarFileBytes []byte - ) - - // create path and map variables - localVarPath := a.client.cfg.BasePath + "/licenses/{accountId}/soft-delete" - localVarPath = strings.Replace(localVarPath, "{"+"accountId"+"}", fmt.Sprintf("%v", accountId), -1) - - localVarHeaderParams := make(map[string]string) - localVarQueryParams := url.Values{} - localVarFormParams := url.Values{} - - // to determine the Content-Type header - localVarHttpContentTypes := []string{} - - // set Content-Type header - localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) - if localVarHttpContentType != "" { - localVarHeaderParams["Content-Type"] = localVarHttpContentType - } - - // to determine the Accept header - localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} - - // set Accept header - localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) - if localVarHttpHeaderAccept != "" { - localVarHeaderParams["Accept"] = localVarHttpHeaderAccept - } - r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) - if err != nil { - return nil, err - } - - localVarHttpResponse, err := a.client.callAPI(r) - if err != nil || localVarHttpResponse == nil { - return localVarHttpResponse, err - } - - localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) - localVarHttpResponse.Body.Close() - if err != nil { - return localVarHttpResponse, err - } - - if localVarHttpResponse.StatusCode >= 300 { - newErr := GenericSwaggerError{ - body: localVarBody, - error: localVarHttpResponse.Status, - } - if localVarHttpResponse.StatusCode == 400 { - var v ModelError - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarHttpResponse, newErr - } - newErr.model = v - return localVarHttpResponse, newErr - } - if localVarHttpResponse.StatusCode == 500 { - var v ModelError - err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) - if err != nil { - newErr.error = err.Error() - return localVarHttpResponse, newErr - } - newErr.model = v - return localVarHttpResponse, newErr - } - return localVarHttpResponse, newErr - } - - return localVarHttpResponse, nil -} - /* LicensesApiService * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). diff --git a/harness/nextgen/api_organization.go b/harness/nextgen/api_organization.go index 9c09a62a..04e8808d 100644 --- a/harness/nextgen/api_organization.go +++ b/harness/nextgen/api_organization.go @@ -30,8 +30,8 @@ type OrganizationApiService service /* OrganizationApiService Creates an Organization * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body Details of the Organization to be created - * @param accountIdentifier + * @param body Details of the Organization to create + * @param accountIdentifier Account Identifier for the entity @return ResponseDtoOrganizationResponse */ func (a *OrganizationApiService) CreateOrganization(ctx context.Context, body OrganizationRequest, accountIdentifier string) (ResponseDtoOrganizationResponse, *http.Response, error) { @@ -138,8 +138,8 @@ func (a *OrganizationApiService) CreateOrganization(ctx context.Context, body Or /* OrganizationApiService Deletes Organization by identifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier + * @param identifier Organization Identifier for the entity + * @param accountIdentifier Account Identifier for the entity * @param optional nil or *OrganizationApiDeleteOrganizationOpts - Optional Parameters: * @param "IfMatch" (optional.String) - @return ResponseDtoBoolean @@ -255,8 +255,8 @@ func (a *OrganizationApiService) DeleteOrganization(ctx context.Context, identif /* OrganizationApiService Get the Organization by accountIdentifier and orgIdentifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier + * @param identifier Organization Identifier for the entity + * @param accountIdentifier Account Identifier for the entity @return ResponseDtoOrganizationResponse */ func (a *OrganizationApiService) GetOrganization(ctx context.Context, identifier string, accountIdentifier string) (ResponseDtoOrganizationResponse, *http.Response, error) { @@ -362,10 +362,10 @@ func (a *OrganizationApiService) GetOrganization(ctx context.Context, identifier /* OrganizationApiService Get the list of organizations satisfying the criteria (if any) in the request * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier + * @param accountIdentifier Account Identifier for the entity * @param optional nil or *OrganizationApiGetOrganizationListOpts - Optional Parameters: - * @param "Identifiers" (optional.Interface of []string) - list of projectIdentifiers to filter results by - * @param "SearchTerm" (optional.String) - + * @param "Identifiers" (optional.Interface of []string) - list of Project Ids for filtering results + * @param "SearchTerm" (optional.String) - Search Term * @param "PageIndex" (optional.Int32) - * @param "PageSize" (optional.Int32) - * @param "SortOrders" (optional.Interface of []SortOrder) - @@ -497,21 +497,20 @@ func (a *OrganizationApiService) GetOrganizationList(ctx context.Context, accoun /* OrganizationApiService * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier + * @param body list of ProjectIdentifiers to filter results by + * @param accountIdentifier Account Identifier for the entity * @param optional nil or *OrganizationApiListAllOrganizationsOpts - Optional Parameters: - * @param "Identifiers" (optional.Interface of []string) - list of projectIdentifiers to filter results by - * @param "SearchTerm" (optional.String) - + * @param "SearchTerm" (optional.String) - Search term */ type OrganizationApiListAllOrganizationsOpts struct { - Identifiers optional.Interface - SearchTerm optional.String + SearchTerm optional.String } -func (a *OrganizationApiService) ListAllOrganizations(ctx context.Context, accountIdentifier string, localVarOptionals *OrganizationApiListAllOrganizationsOpts) (*http.Response, error) { +func (a *OrganizationApiService) ListAllOrganizations(ctx context.Context, body []string, accountIdentifier string, localVarOptionals *OrganizationApiListAllOrganizationsOpts) (*http.Response, error) { var ( - localVarHttpMethod = strings.ToUpper("Get") + localVarHttpMethod = strings.ToUpper("Post") localVarPostBody interface{} localVarFileName string localVarFileBytes []byte @@ -525,14 +524,11 @@ func (a *OrganizationApiService) ListAllOrganizations(ctx context.Context, accou localVarFormParams := url.Values{} localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) - if localVarOptionals != nil && localVarOptionals.Identifiers.IsSet() { - localVarQueryParams.Add("identifiers", parameterToString(localVarOptionals.Identifiers.Value(), "multi")) - } if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) } // to determine the Content-Type header - localVarHttpContentTypes := []string{} + localVarHttpContentTypes := []string{"application/json", "application/yaml"} // set Content-Type header localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) @@ -548,6 +544,8 @@ func (a *OrganizationApiService) ListAllOrganizations(ctx context.Context, accou if localVarHttpHeaderAccept != "" { localVarHeaderParams["Accept"] = localVarHttpHeaderAccept } + // body params + localVarPostBody = &body r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) if err != nil { return nil, err @@ -598,9 +596,9 @@ func (a *OrganizationApiService) ListAllOrganizations(ctx context.Context, accou /* OrganizationApiService Updates the Organization * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body This is the updated Organization. This should have all the fields not just the updated ones - * @param accountIdentifier - * @param identifier + * @param body This is the updated Organization. Please provide values for all fields, not just the fields you are updating + * @param accountIdentifier Account Identifier for the entity + * @param identifier Organization Identifier for the entity * @param optional nil or *OrganizationApiPutOrganizationOpts - Optional Parameters: * @param "IfMatch" (optional.String) - @return ResponseDtoOrganizationResponse diff --git a/harness/nextgen/api_project.go b/harness/nextgen/api_project.go index 2e64290e..1fd8be91 100644 --- a/harness/nextgen/api_project.go +++ b/harness/nextgen/api_project.go @@ -28,13 +28,13 @@ var ( type ProjectApiService service /* -ProjectApiService Delete a project by identifier +ProjectApiService Delete a Project by identifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier + * @param identifier Project Identifier for the entity + * @param accountIdentifier Account Identifier for the entity * @param optional nil or *ProjectApiDeleteProjectOpts - Optional Parameters: * @param "IfMatch" (optional.String) - - * @param "OrgIdentifier" (optional.String) - Organization identifier for the project. If left empty, the project will be create under default organization + * @param "OrgIdentifier" (optional.String) - Organization identifier for the Project. If left empty, Default Organization is assumed @return ResponseDtoBoolean */ @@ -152,10 +152,10 @@ func (a *ProjectApiService) DeleteProject(ctx context.Context, identifier string /* ProjectApiService Gets a Project by identifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param identifier - * @param accountIdentifier + * @param identifier Project Identifier for the entity + * @param accountIdentifier Account Identifier for the entity * @param optional nil or *ProjectApiGetProjectOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - Organization identifier for the project. If left empty, the project will be create under default organization + * @param "OrgIdentifier" (optional.String) - Organization identifier for the project. If left empty, Default Organization is assumed @return ResponseDtoProjectResponse */ @@ -269,13 +269,13 @@ func (a *ProjectApiService) GetProject(ctx context.Context, identifier string, a /* ProjectApiService List user's project * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param accountIdentifier + * @param accountIdentifier Account Identifier for the entity * @param optional nil or *ProjectApiGetProjectListOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - - * @param "HasModule" (optional.Bool) - - * @param "Identifiers" (optional.Interface of []string) - list of projectIdentifiers to filter results by - * @param "ModuleType" (optional.String) - - * @param "SearchTerm" (optional.String) - + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "HasModule" (optional.Bool) - This boolean specifies whether to Filter Projects which has the Module of type passed in the module type parameter or to Filter Projects which does not has the Module of type passed in the module type parameter + * @param "Identifiers" (optional.Interface of []string) - list of Project Ids for filtering results + * @param "ModuleType" (optional.String) - Filter Projects by module type + * @param "SearchTerm" (optional.String) - Filter Projects by searching for this word in Name, Id, and Tag * @param "PageIndex" (optional.Int32) - * @param "PageSize" (optional.Int32) - * @param "SortOrders" (optional.Interface of []SortOrder) - @@ -419,10 +419,10 @@ func (a *ProjectApiService) GetProjectList(ctx context.Context, accountIdentifie /* ProjectApiService Creates a Project * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body Details of the project to be created - * @param accountIdentifier + * @param body Details of the Project to create + * @param accountIdentifier Account Identifier for the entity * @param optional nil or *ProjectApiPostProjectOpts - Optional Parameters: - * @param "OrgIdentifier" (optional.String) - Organization identifier for the project. If left empty, the project will be create under default organization + * @param "OrgIdentifier" (optional.String) - Organization identifier for the Project. If left empty, the Project is created under Default Organization @return ResponseDtoProjectResponse */ @@ -535,14 +535,14 @@ func (a *ProjectApiService) PostProject(ctx context.Context, body ProjectRequest } /* -ProjectApiService Update project by identifier +ProjectApiService Update Project by identifier * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). - * @param body This is the updated project. This should have all the fields not just the updated ones - * @param accountIdentifier - * @param identifier + * @param body This is the updated project. Please provide values for all fields, not just the fields you are updating + * @param accountIdentifier Account Identifier for the entity + * @param identifier Project Identifier for the entity * @param optional nil or *ProjectApiPutProjectOpts - Optional Parameters: * @param "IfMatch" (optional.String) - - * @param "OrgIdentifier" (optional.String) - Organization identifier for the project. If left empty, the project will be create under default organization + * @param "OrgIdentifier" (optional.String) - Organization identifier for the Project. If left empty, Default Organization is assumed @return ResponseDtoProjectResponse */ diff --git a/harness/nextgen/api_scm.go b/harness/nextgen/api_scm.go new file mode 100644 index 00000000..cc36eb08 --- /dev/null +++ b/harness/nextgen/api_scm.go @@ -0,0 +1,671 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type ScmApiService service + +/* +ScmApiService creates a Pull Request + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param body Details to create a PR +@return ResponseDtoCreatePr +*/ +func (a *ScmApiService) CreatePR(ctx context.Context, body GitPrCreateRequest) (ResponseDtoCreatePr, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoCreatePr + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/scm/createPR" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "text/yaml", "text/html"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + localVarPostBody = &body + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoCreatePr + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +ScmApiService Gets Git File Content + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param yamlGitConfigIdentifier Git Sync Config Id + * @param accountIdentifier Account Identifier for the entity + * @param filePath File Path + * @param optional nil or *ScmApiGetFileContentOpts - Optional Parameters: + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Branch" (optional.String) - Branch Name + * @param "CommitId" (optional.String) - Commit Id +@return ResponseDtoGitFileContent +*/ + +type ScmApiGetFileContentOpts struct { + OrgIdentifier optional.String + ProjectIdentifier optional.String + Branch optional.String + CommitId optional.String +} + +func (a *ScmApiService) GetFileContent(ctx context.Context, yamlGitConfigIdentifier string, accountIdentifier string, filePath string, localVarOptionals *ScmApiGetFileContentOpts) (ResponseDtoGitFileContent, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoGitFileContent + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/scm/fileContent" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("yamlGitConfigIdentifier", parameterToString(yamlGitConfigIdentifier, "")) + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + localVarQueryParams.Add("filePath", parameterToString(filePath, "")) + if localVarOptionals != nil && localVarOptionals.Branch.IsSet() { + localVarQueryParams.Add("branch", parameterToString(localVarOptionals.Branch.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.CommitId.IsSet() { + localVarQueryParams.Add("commitId", parameterToString(localVarOptionals.CommitId.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoGitFileContent + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +ScmApiService Lists Branches of given Repo by referenced Connector Identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *ScmApiGetListOfBranchesByConnectorOpts - Optional Parameters: + * @param "ConnectorIdentifierRef" (optional.String) - Connector Identifier Reference + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "RepoURL" (optional.String) - Repo Url + * @param "Page" (optional.Int32) - The number of the page to fetch + * @param "Size" (optional.Int32) - The number of the elements to fetch + * @param "SearchTerm" (optional.String) - Search Term +@return ResponseDtoListString +*/ + +type ScmApiGetListOfBranchesByConnectorOpts struct { + ConnectorIdentifierRef optional.String + AccountIdentifier optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String + RepoURL optional.String + Page optional.Int32 + Size optional.Int32 + SearchTerm optional.String +} + +func (a *ScmApiService) GetListOfBranchesByConnector(ctx context.Context, localVarOptionals *ScmApiGetListOfBranchesByConnectorOpts) (ResponseDtoListString, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoListString + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/scm/listRepoBranches" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.ConnectorIdentifierRef.IsSet() { + localVarQueryParams.Add("connectorIdentifierRef", parameterToString(localVarOptionals.ConnectorIdentifierRef.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.RepoURL.IsSet() { + localVarQueryParams.Add("repoURL", parameterToString(localVarOptionals.RepoURL.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Page.IsSet() { + localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Size.IsSet() { + localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { + localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoListString + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +ScmApiService Lists Branches by given Git Sync Config Identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *ScmApiGetListOfBranchesByGitConfigOpts - Optional Parameters: + * @param "YamlGitConfigIdentifier" (optional.String) - Git Sync Config Id + * @param "AccountIdentifier" (optional.String) - Account Identifier for the entity + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Page" (optional.Int32) - The number of the page to fetch + * @param "Size" (optional.Int32) - The number of the elements to fetch + * @param "SearchTerm" (optional.String) - Search Term +@return ResponseDtoListString +*/ + +type ScmApiGetListOfBranchesByGitConfigOpts struct { + YamlGitConfigIdentifier optional.String + AccountIdentifier optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String + Page optional.Int32 + Size optional.Int32 + SearchTerm optional.String +} + +func (a *ScmApiService) GetListOfBranchesByGitConfig(ctx context.Context, localVarOptionals *ScmApiGetListOfBranchesByGitConfigOpts) (ResponseDtoListString, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoListString + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/scm/listBranchesByGitConfig" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.YamlGitConfigIdentifier.IsSet() { + localVarQueryParams.Add("yamlGitConfigIdentifier", parameterToString(localVarOptionals.YamlGitConfigIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.AccountIdentifier.IsSet() { + localVarQueryParams.Add("accountIdentifier", parameterToString(localVarOptionals.AccountIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Page.IsSet() { + localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Size.IsSet() { + localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { + localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoListString + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +ScmApiService Checks if Saas is possible for given Repo Url + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *ScmApiIsSaasGitOpts - Optional Parameters: + * @param "RepoURL" (optional.String) - Repo Url +@return ResponseDtoSaasGitDto +*/ + +type ScmApiIsSaasGitOpts struct { + RepoURL optional.String +} + +func (a *ScmApiService) IsSaasGit(ctx context.Context, localVarOptionals *ScmApiIsSaasGitOpts) (ResponseDtoSaasGitDto, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoSaasGitDto + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/scm/isSaasGit" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.RepoURL.IsSet() { + localVarQueryParams.Add("repoURL", parameterToString(localVarOptionals.RepoURL.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml", "text/yaml", "text/html"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoSaasGitDto + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_services.go b/harness/nextgen/api_services.go new file mode 100644 index 00000000..ce6d411a --- /dev/null +++ b/harness/nextgen/api_services.go @@ -0,0 +1,1054 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "fmt" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type ServicesApiService service + +/* +ServicesApiService Create a Service + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *ServicesApiCreateServiceV2Opts - Optional Parameters: + * @param "Body" (optional.Interface of ServiceRequest) - Details of the Service to be created +@return ResponseDtoServiceResponse +*/ + +type ServicesApiCreateServiceV2Opts struct { + Body optional.Interface +} + +func (a *ServicesApiService) CreateServiceV2(ctx context.Context, accountIdentifier string, localVarOptionals *ServicesApiCreateServiceV2Opts) (ResponseDtoServiceResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoServiceResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/servicesV2" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "application/yaml"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoServiceResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +ServicesApiService Create Services + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *ServicesApiCreateServicesV2Opts - Optional Parameters: + * @param "Body" (optional.Interface of []ServiceRequest) - Details of the Services to be created +@return ResponseDtoPageResponseServiceResponse +*/ + +type ServicesApiCreateServicesV2Opts struct { + Body optional.Interface +} + +func (a *ServicesApiService) CreateServicesV2(ctx context.Context, accountIdentifier string, localVarOptionals *ServicesApiCreateServicesV2Opts) (ResponseDtoPageResponseServiceResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoPageResponseServiceResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/servicesV2/batch" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "application/yaml"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoPageResponseServiceResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +ServicesApiService Delete a Service by identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param serviceIdentifier Service Identifier for the entity + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *ServicesApiDeleteServiceV2Opts - Optional Parameters: + * @param "IfMatch" (optional.String) - + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity +@return ResponseDtoBoolean +*/ + +type ServicesApiDeleteServiceV2Opts struct { + IfMatch optional.String + OrgIdentifier optional.String + ProjectIdentifier optional.String +} + +func (a *ServicesApiService) DeleteServiceV2(ctx context.Context, serviceIdentifier string, accountIdentifier string, localVarOptionals *ServicesApiDeleteServiceV2Opts) (ResponseDtoBoolean, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Delete") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoBoolean + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/servicesV2/{serviceIdentifier}" + localVarPath = strings.Replace(localVarPath, "{"+"serviceIdentifier"+"}", fmt.Sprintf("%v", serviceIdentifier), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { + localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoBoolean + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +ServicesApiService Gets Service Access list + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *ServicesApiGetServiceAccessListOpts - Optional Parameters: + * @param "Page" (optional.Int32) - The number of the page to fetch + * @param "Size" (optional.Int32) - The number of the elements to fetch + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "SearchTerm" (optional.String) - The word to be searched and included in the list response + * @param "ServiceIdentifiers" (optional.Interface of []string) - List of ServicesIds + * @param "Sort" (optional.Interface of []string) - Specifies the sorting criteria of the list. Like sorting based on the last updated entity, alphabetical sorting in an ascending or descending order +@return ResponseDtoListServiceResponse +*/ + +type ServicesApiGetServiceAccessListOpts struct { + Page optional.Int32 + Size optional.Int32 + OrgIdentifier optional.String + ProjectIdentifier optional.String + SearchTerm optional.String + ServiceIdentifiers optional.Interface + Sort optional.Interface +} + +func (a *ServicesApiService) GetServiceAccessList(ctx context.Context, accountIdentifier string, localVarOptionals *ServicesApiGetServiceAccessListOpts) (ResponseDtoListServiceResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoListServiceResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/servicesV2/list/access" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.Page.IsSet() { + localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Size.IsSet() { + localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) + } + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { + localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ServiceIdentifiers.IsSet() { + localVarQueryParams.Add("serviceIdentifiers", parameterToString(localVarOptionals.ServiceIdentifiers.Value(), "multi")) + } + if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { + localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoListServiceResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +ServicesApiService Gets Service list + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *ServicesApiGetServiceListOpts - Optional Parameters: + * @param "Page" (optional.Int32) - The number of the page to fetch + * @param "Size" (optional.Int32) - The number of the elements to fetch + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "SearchTerm" (optional.String) - The word to be searched and included in the list response + * @param "ServiceIdentifiers" (optional.Interface of []string) - List of ServicesIds + * @param "Sort" (optional.Interface of []string) - Specifies the sorting criteria of the list. Like sorting based on the last updated entity, alphabetical sorting in an ascending or descending order +@return ResponseDtoPageResponseServiceResponse +*/ + +type ServicesApiGetServiceListOpts struct { + Page optional.Int32 + Size optional.Int32 + OrgIdentifier optional.String + ProjectIdentifier optional.String + SearchTerm optional.String + ServiceIdentifiers optional.Interface + Sort optional.Interface +} + +func (a *ServicesApiService) GetServiceList(ctx context.Context, accountIdentifier string, localVarOptionals *ServicesApiGetServiceListOpts) (ResponseDtoPageResponseServiceResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoPageResponseServiceResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/servicesV2" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + if localVarOptionals != nil && localVarOptionals.Page.IsSet() { + localVarQueryParams.Add("page", parameterToString(localVarOptionals.Page.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Size.IsSet() { + localVarQueryParams.Add("size", parameterToString(localVarOptionals.Size.Value(), "")) + } + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.SearchTerm.IsSet() { + localVarQueryParams.Add("searchTerm", parameterToString(localVarOptionals.SearchTerm.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ServiceIdentifiers.IsSet() { + localVarQueryParams.Add("serviceIdentifiers", parameterToString(localVarOptionals.ServiceIdentifiers.Value(), "multi")) + } + if localVarOptionals != nil && localVarOptionals.Sort.IsSet() { + localVarQueryParams.Add("sort", parameterToString(localVarOptionals.Sort.Value(), "multi")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoPageResponseServiceResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +ServicesApiService Gets a Service by identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param serviceIdentifier Service Identifier for the entity + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *ServicesApiGetServiceV2Opts - Optional Parameters: + * @param "OrgIdentifier" (optional.String) - Organization Identifier for the entity + * @param "ProjectIdentifier" (optional.String) - Project Identifier for the entity + * @param "Deleted" (optional.Bool) - Specify whether Service is deleted or not +@return ResponseDtoServiceResponse +*/ + +type ServicesApiGetServiceV2Opts struct { + OrgIdentifier optional.String + ProjectIdentifier optional.String + Deleted optional.Bool +} + +func (a *ServicesApiService) GetServiceV2(ctx context.Context, serviceIdentifier string, accountIdentifier string, localVarOptionals *ServicesApiGetServiceV2Opts) (ResponseDtoServiceResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoServiceResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/servicesV2/{serviceIdentifier}" + localVarPath = strings.Replace(localVarPath, "{"+"serviceIdentifier"+"}", fmt.Sprintf("%v", serviceIdentifier), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + if localVarOptionals != nil && localVarOptionals.OrgIdentifier.IsSet() { + localVarQueryParams.Add("orgIdentifier", parameterToString(localVarOptionals.OrgIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.ProjectIdentifier.IsSet() { + localVarQueryParams.Add("projectIdentifier", parameterToString(localVarOptionals.ProjectIdentifier.Value(), "")) + } + if localVarOptionals != nil && localVarOptionals.Deleted.IsSet() { + localVarQueryParams.Add("deleted", parameterToString(localVarOptionals.Deleted.Value(), "")) + } + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoServiceResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +ServicesApiService Update a Service by identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *ServicesApiUpdateServiceV2Opts - Optional Parameters: + * @param "Body" (optional.Interface of ServiceRequest) - Details of the Service to be updated + * @param "IfMatch" (optional.String) - +@return ResponseDtoServiceResponse +*/ + +type ServicesApiUpdateServiceV2Opts struct { + Body optional.Interface + IfMatch optional.String +} + +func (a *ServicesApiService) UpdateServiceV2(ctx context.Context, accountIdentifier string, localVarOptionals *ServicesApiUpdateServiceV2Opts) (ResponseDtoServiceResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Put") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoServiceResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/servicesV2" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "application/yaml"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { + localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoServiceResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +ServicesApiService Upsert a Service by identifier + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity + * @param optional nil or *ServicesApiUpsertServiceV2Opts - Optional Parameters: + * @param "Body" (optional.Interface of ServiceRequest) - Details of the Service to be updated + * @param "IfMatch" (optional.String) - +@return ResponseDtoServiceResponse +*/ + +type ServicesApiUpsertServiceV2Opts struct { + Body optional.Interface + IfMatch optional.String +} + +func (a *ServicesApiService) UpsertServiceV2(ctx context.Context, accountIdentifier string, localVarOptionals *ServicesApiUpsertServiceV2Opts) (ResponseDtoServiceResponse, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Put") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoServiceResponse + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/servicesV2/upsert" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{"application/json", "application/yaml"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + if localVarOptionals != nil && localVarOptionals.IfMatch.IsSet() { + localVarHeaderParams["If-Match"] = parameterToString(localVarOptionals.IfMatch.Value(), "") + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoServiceResponse + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_source_code_manager.go b/harness/nextgen/api_source_code_manager.go new file mode 100644 index 00000000..af30dde9 --- /dev/null +++ b/harness/nextgen/api_source_code_manager.go @@ -0,0 +1,474 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "context" + "fmt" + "io/ioutil" + "net/http" + "net/url" + "strings" + + "github.com/antihax/optional" +) + +// Linger please +var ( + _ context.Context +) + +type SourceCodeManagerApiService service + +/* +SourceCodeManagerApiService Creates Source Code Manager + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param optional nil or *SourceCodeManagerApiCreateSourceCodeManagerOpts - Optional Parameters: + * @param "Body" (optional.Interface of SourceCodeManager) - This contains details of Source Code Manager +@return ResponseDtoSourceCodeManager +*/ + +type SourceCodeManagerApiCreateSourceCodeManagerOpts struct { + Body optional.Interface +} + +func (a *SourceCodeManagerApiService) CreateSourceCodeManager(ctx context.Context, localVarOptionals *SourceCodeManagerApiCreateSourceCodeManagerOpts) (ResponseDtoSourceCodeManager, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Post") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoSourceCodeManager + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/source-code-manager" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + // to determine the Content-Type header + localVarHttpContentTypes := []string{"*/*"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoSourceCodeManager + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +SourceCodeManagerApiService Deletes the Source Code Manager corresponding to the specified Source Code Manager Id + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param identifier Source Code manager Identifier + * @param accountIdentifier Account Identifier for the entity +@return ResponseDtoBoolean +*/ +func (a *SourceCodeManagerApiService) DeleteSourceCodeManager(ctx context.Context, identifier string, accountIdentifier string) (ResponseDtoBoolean, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Delete") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoBoolean + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/source-code-manager/{identifier}" + localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoBoolean + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +SourceCodeManagerApiService Lists Source Code Managers for the given account + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param accountIdentifier Account Identifier for the entity +@return ResponseDtoListSourceCodeManager +*/ +func (a *SourceCodeManagerApiService) GetSourceCodeManagers(ctx context.Context, accountIdentifier string) (ResponseDtoListSourceCodeManager, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoListSourceCodeManager + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/source-code-manager" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoListSourceCodeManager + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} + +/* +SourceCodeManagerApiService Updates Source Code Manager Details with the given Source Code Manager Id + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). + * @param identifier Source Code manager Identifier + * @param optional nil or *SourceCodeManagerApiUpdateSourceCodeManagerOpts - Optional Parameters: + * @param "Body" (optional.Interface of SourceCodeManager) - This contains details of Source Code Manager +@return ResponseDtoSourceCodeManager +*/ + +type SourceCodeManagerApiUpdateSourceCodeManagerOpts struct { + Body optional.Interface +} + +func (a *SourceCodeManagerApiService) UpdateSourceCodeManager(ctx context.Context, identifier string, localVarOptionals *SourceCodeManagerApiUpdateSourceCodeManagerOpts) (ResponseDtoSourceCodeManager, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Put") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoSourceCodeManager + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/source-code-manager/{identifier}" + localVarPath = strings.Replace(localVarPath, "{"+"identifier"+"}", fmt.Sprintf("%v", identifier), -1) + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + // to determine the Content-Type header + localVarHttpContentTypes := []string{"*/*"} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + // body params + if localVarOptionals != nil && localVarOptionals.Body.IsSet() { + + localVarOptionalBody := localVarOptionals.Body.Value() + localVarPostBody = &localVarOptionalBody + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoSourceCodeManager + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/api_users.go b/harness/nextgen/api_users.go new file mode 100644 index 00000000..7399000c --- /dev/null +++ b/harness/nextgen/api_users.go @@ -0,0 +1,124 @@ +package nextgen + +import ( + "context" + "io/ioutil" + "net/http" + "net/url" + "strings" +) + +// Linger please +var ( + _ context.Context +) + +type UsersApiService service + +/* +DefaultApiService + * @param ctx context.Context - for authentication, logging, cancellation, deadlines, tracing, etc. Passed from http.Request or context.Background(). +@return ResponseDtoUserInfo +*/ +func (a *UsersApiService) GetUserInfo(ctx context.Context, accountIdentifier string) (ResponseDtoUserInfo, *http.Response, error) { + var ( + localVarHttpMethod = strings.ToUpper("Get") + localVarPostBody interface{} + localVarFileName string + localVarFileBytes []byte + localVarReturnValue ResponseDtoUserInfo + ) + + // create path and map variables + localVarPath := a.client.cfg.BasePath + "/user/currentUser" + + localVarHeaderParams := make(map[string]string) + localVarQueryParams := url.Values{} + localVarFormParams := url.Values{} + + // to determine the Content-Type header + localVarHttpContentTypes := []string{} + + // set Content-Type header + localVarHttpContentType := selectHeaderContentType(localVarHttpContentTypes) + if localVarHttpContentType != "" { + localVarHeaderParams["Content-Type"] = localVarHttpContentType + } + + if accountIdentifier != "" { + localVarQueryParams.Add("accountIdentifier", parameterToString(accountIdentifier, "")) + } + + // to determine the Accept header + localVarHttpHeaderAccepts := []string{"application/json", "application/yaml"} + + // set Accept header + localVarHttpHeaderAccept := selectHeaderAccept(localVarHttpHeaderAccepts) + if localVarHttpHeaderAccept != "" { + localVarHeaderParams["Accept"] = localVarHttpHeaderAccept + } + r, err := a.client.prepareRequest(ctx, localVarPath, localVarHttpMethod, localVarPostBody, localVarHeaderParams, localVarQueryParams, localVarFormParams, localVarFileName, localVarFileBytes) + if err != nil { + return localVarReturnValue, nil, err + } + + localVarHttpResponse, err := a.client.callAPI(r) + if err != nil || localVarHttpResponse == nil { + return localVarReturnValue, localVarHttpResponse, err + } + + localVarBody, err := ioutil.ReadAll(localVarHttpResponse.Body) + localVarHttpResponse.Body.Close() + if err != nil { + return localVarReturnValue, localVarHttpResponse, err + } + + if localVarHttpResponse.StatusCode < 300 { + // If we succeed, return the data, otherwise pass on to decode error. + err = a.client.decode(&localVarReturnValue, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err == nil { + return localVarReturnValue, localVarHttpResponse, err + } + } + + if localVarHttpResponse.StatusCode >= 300 { + newErr := GenericSwaggerError{ + body: localVarBody, + error: localVarHttpResponse.Status, + } + if localVarHttpResponse.StatusCode == 400 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 500 { + var v ModelError + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + if localVarHttpResponse.StatusCode == 0 { + var v ResponseDtoAccount + err = a.client.decode(&v, localVarBody, localVarHttpResponse.Header.Get("Content-Type")) + if err != nil { + newErr.error = err.Error() + return localVarReturnValue, localVarHttpResponse, newErr + } + newErr.model = v + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, newErr + } + + return localVarReturnValue, localVarHttpResponse, nil +} diff --git a/harness/nextgen/client.go b/harness/nextgen/client.go index 703fb9a7..c25de7df 100644 --- a/harness/nextgen/client.go +++ b/harness/nextgen/client.go @@ -52,24 +52,48 @@ type APIClient struct { ConnectorsApi *ConnectorsApiService - DefaultApi *DefaultApiService - DelegateConfigurationManagementApi *DelegateConfigurationManagementApiService DelegateConfigurationResourceApi *DelegateConfigurationResourceApiService EnforcementApi *EnforcementApiService + EnvironmentsApi *EnvironmentsApiService + FeedbackApi *FeedbackApiService + FilterApi *FilterApiService + + FullSyncApi *FullSyncApiService + GcpClustersApi *GcpClustersApiService + GitBranchesApi *GitBranchesApiService + + GitSyncApi *GitSyncApiService + + GitSyncEntitiesApi *GitSyncEntitiesApiService + + GitSyncErrorsApi *GitSyncErrorsApiService + + GitSyncSettingsApi *GitSyncSettingsApiService + + InviteApi *InviteApiService + LicensesApi *LicensesApiService OrganizationApi *OrganizationApiService ProjectApi *ProjectApiService + ScmApi *ScmApiService + + ServicesApi *ServicesApiService + + SourceCodeManagerApi *SourceCodeManagerApiService + + UsersApi *UsersApiService + WebhookEventHandlerApi *WebhookEventHandlerApiService } @@ -92,15 +116,27 @@ func NewAPIClient(cfg *Configuration) *APIClient { c.AccountsApi = (*AccountsApiService)(&c.common) c.AuthenticationSettingsApi = (*AuthenticationSettingsApiService)(&c.common) c.ConnectorsApi = (*ConnectorsApiService)(&c.common) - c.DefaultApi = (*DefaultApiService)(&c.common) c.DelegateConfigurationManagementApi = (*DelegateConfigurationManagementApiService)(&c.common) c.DelegateConfigurationResourceApi = (*DelegateConfigurationResourceApiService)(&c.common) c.EnforcementApi = (*EnforcementApiService)(&c.common) + c.EnvironmentsApi = (*EnvironmentsApiService)(&c.common) c.FeedbackApi = (*FeedbackApiService)(&c.common) + c.FilterApi = (*FilterApiService)(&c.common) + c.FullSyncApi = (*FullSyncApiService)(&c.common) c.GcpClustersApi = (*GcpClustersApiService)(&c.common) + c.GitBranchesApi = (*GitBranchesApiService)(&c.common) + c.GitSyncApi = (*GitSyncApiService)(&c.common) + c.GitSyncEntitiesApi = (*GitSyncEntitiesApiService)(&c.common) + c.GitSyncErrorsApi = (*GitSyncErrorsApiService)(&c.common) + c.GitSyncSettingsApi = (*GitSyncSettingsApiService)(&c.common) + c.InviteApi = (*InviteApiService)(&c.common) c.LicensesApi = (*LicensesApiService)(&c.common) c.OrganizationApi = (*OrganizationApiService)(&c.common) c.ProjectApi = (*ProjectApiService)(&c.common) + c.ScmApi = (*ScmApiService)(&c.common) + c.ServicesApi = (*ServicesApiService)(&c.common) + c.SourceCodeManagerApi = (*SourceCodeManagerApiService)(&c.common) + c.UsersApi = (*UsersApiService)(&c.common) c.WebhookEventHandlerApi = (*WebhookEventHandlerApiService)(&c.common) return c @@ -506,6 +542,10 @@ func (e GenericSwaggerError) Error() string { return failure.ResponseMessages[0].Message } + if len(failure.Errors) > 0 { + return fmt.Sprintf("%s %s", failure.Errors[0].FieldId, failure.Errors[0].Error_) + } + return failure.Code } diff --git a/harness/nextgen/enum_app_dynamics_auth_types.go b/harness/nextgen/enum_app_dynamics_auth_types.go new file mode 100644 index 00000000..b98ea99b --- /dev/null +++ b/harness/nextgen/enum_app_dynamics_auth_types.go @@ -0,0 +1,20 @@ +package nextgen + +type AppDynamicsAuthType string + +var AppDynamicsAuthTypes = struct { + ApiClientToken AppDynamicsAuthType + UsernamePassword AppDynamicsAuthType +}{ + ApiClientToken: "ApiClientToken", + UsernamePassword: "UsernamePassword", +} + +var AppDynamicsAuthTypeValues = []string{ + AppDynamicsAuthTypes.ApiClientToken.String(), + AppDynamicsAuthTypes.UsernamePassword.String(), +} + +func (e AppDynamicsAuthType) String() string { + return string(e) +} diff --git a/harness/nextgen/enum_aws_kms_credential_type.go b/harness/nextgen/enum_aws_kms_credential_type.go new file mode 100644 index 00000000..b8f39a15 --- /dev/null +++ b/harness/nextgen/enum_aws_kms_credential_type.go @@ -0,0 +1,23 @@ +package nextgen + +type AwsKmsAuthType string + +var AwsKmsAuthTypes = struct { + AssumeIAMRole AwsKmsAuthType + AssumeSTSRole AwsKmsAuthType + ManualConfig AwsKmsAuthType +}{ + AssumeIAMRole: "AssumeIAMRole", + AssumeSTSRole: "AssumeSTSRole", + ManualConfig: "ManualConfig", +} + +var AwsKmsAuthTypeValues = []string{ + AwsKmsAuthTypes.AssumeIAMRole.String(), + AwsKmsAuthTypes.AssumeSTSRole.String(), + AwsKmsAuthTypes.ManualConfig.String(), +} + +func (e AwsKmsAuthType) String() string { + return string(e) +} diff --git a/harness/nextgen/enum_aws_secret_manager_auth_types.go b/harness/nextgen/enum_aws_secret_manager_auth_types.go new file mode 100644 index 00000000..865d6f8d --- /dev/null +++ b/harness/nextgen/enum_aws_secret_manager_auth_types.go @@ -0,0 +1,23 @@ +package nextgen + +type AwsSecretManagerAuthType string + +var AwsSecretManagerAuthTypes = struct { + AssumeIAMRole AwsSecretManagerAuthType + AssumeSTSRole AwsSecretManagerAuthType + ManualConfig AwsSecretManagerAuthType +}{ + AssumeIAMRole: "AssumeIAMRole", + AssumeSTSRole: "AssumeSTSRole", + ManualConfig: "ManualConfig", +} + +var AwsSecretManagerAuthTypeValues = []string{ + AwsSecretManagerAuthTypes.AssumeIAMRole.String(), + AwsSecretManagerAuthTypes.AssumeSTSRole.String(), + AwsSecretManagerAuthTypes.ManualConfig.String(), +} + +func (e AwsSecretManagerAuthType) String() string { + return string(e) +} diff --git a/harness/nextgen/enum_bitbucket_api_access_types.go b/harness/nextgen/enum_bitbucket_api_access_types.go new file mode 100644 index 00000000..6ed40310 --- /dev/null +++ b/harness/nextgen/enum_bitbucket_api_access_types.go @@ -0,0 +1,17 @@ +package nextgen + +type BitBucketApiAccessType string + +var BitBucketApiAccessTypes = struct { + UsernameToken BitBucketApiAccessType +}{ + UsernameToken: "UsernameToken", +} + +var BitBucketApiAccessTypeValues = []string{ + BitBucketApiAccessTypes.UsernameToken.String(), +} + +func (e BitBucketApiAccessType) String() string { + return string(e) +} diff --git a/harness/nextgen/enum_bitbucket_http_credential_types.go b/harness/nextgen/enum_bitbucket_http_credential_types.go new file mode 100644 index 00000000..b9541d19 --- /dev/null +++ b/harness/nextgen/enum_bitbucket_http_credential_types.go @@ -0,0 +1,17 @@ +package nextgen + +type BitBucketHttpCredentialType string + +var BitBucketHttpCredentialTypes = struct { + UsernamePassword BitBucketHttpCredentialType +}{ + UsernamePassword: "UsernamePassword", +} + +var BitBucketHttpCredentialTypeValues = []string{ + BitBucketHttpCredentialTypes.UsernamePassword.String(), +} + +func (e BitBucketHttpCredentialType) String() string { + return string(e) +} diff --git a/harness/nextgen/enum_git_connector_type.go b/harness/nextgen/enum_git_connector_types.go similarity index 100% rename from harness/nextgen/enum_git_connector_type.go rename to harness/nextgen/enum_git_connector_types.go diff --git a/harness/nextgen/enum_github_api_access_types.go b/harness/nextgen/enum_github_api_access_types.go new file mode 100644 index 00000000..4fb01a10 --- /dev/null +++ b/harness/nextgen/enum_github_api_access_types.go @@ -0,0 +1,20 @@ +package nextgen + +type GithubApiAccessType string + +var GithubApiAccessTypes = struct { + Token GithubApiAccessType + GithubApp GithubApiAccessType +}{ + Token: "Token", + GithubApp: "GithubApp", +} + +var GithubApiAccessTypeValues = []string{ + GithubApiAccessTypes.Token.String(), + GithubApiAccessTypes.GithubApp.String(), +} + +func (e GithubApiAccessType) String() string { + return string(e) +} diff --git a/harness/nextgen/enum_github_http_credential_types.go b/harness/nextgen/enum_github_http_credential_types.go new file mode 100644 index 00000000..035f075a --- /dev/null +++ b/harness/nextgen/enum_github_http_credential_types.go @@ -0,0 +1,17 @@ +package nextgen + +type GithubHttpCredentialType string + +var GithubHttpCredentialTypes = struct { + UsernameToken GithubHttpCredentialType +}{ + UsernameToken: "UsernameToken", +} + +var GithubHttpCredentialTypeValues = []string{ + GithubHttpCredentialTypes.UsernameToken.String(), +} + +func (e GithubHttpCredentialType) String() string { + return string(e) +} diff --git a/harness/nextgen/enum_gitlab_api_auth_types.go b/harness/nextgen/enum_gitlab_api_auth_types.go new file mode 100644 index 00000000..7999386d --- /dev/null +++ b/harness/nextgen/enum_gitlab_api_auth_types.go @@ -0,0 +1,17 @@ +package nextgen + +type GitlabApiAuthType string + +var GitlabApiAuthTypes = struct { + Token GitlabApiAuthType +}{ + Token: "Token", +} + +var GitlabApiAuthTypeValues = []string{ + GitlabApiAuthTypes.Token.String(), +} + +func (e GitlabApiAuthType) String() string { + return string(e) +} diff --git a/harness/nextgen/enum_gitlab_http_credential_types.go b/harness/nextgen/enum_gitlab_http_credential_types.go new file mode 100644 index 00000000..136d3edb --- /dev/null +++ b/harness/nextgen/enum_gitlab_http_credential_types.go @@ -0,0 +1,20 @@ +package nextgen + +type GitlabHttpCredentialType string + +var GitlabHttpCredentialTypes = struct { + UsernamePassword GitlabHttpCredentialType + UsernameToken GitlabHttpCredentialType +}{ + UsernamePassword: "UsernamePassword", + UsernameToken: "UsernameToken", +} + +var GitlabHttpCredentialTypeValues = []string{ + GitlabHttpCredentialTypes.UsernamePassword.String(), + GitlabHttpCredentialTypes.UsernameToken.String(), +} + +func (e GitlabHttpCredentialType) String() string { + return string(e) +} diff --git a/harness/nextgen/enum_kubernetes_auth_methods.go b/harness/nextgen/enum_kubernetes_auth_methods.go index 3c28c8fc..b9e77d15 100644 --- a/harness/nextgen/enum_kubernetes_auth_methods.go +++ b/harness/nextgen/enum_kubernetes_auth_methods.go @@ -1,12 +1,12 @@ package nextgen -type KubernetesAuthMethod string +type KubernetesAuthType string -var KubernetesAuthMethods = struct { - UsernamePassword KubernetesAuthMethod - ServiceAccount KubernetesAuthMethod - OpenIdConnect KubernetesAuthMethod - ClientKeyCert KubernetesAuthMethod +var KubernetesAuthTypes = struct { + UsernamePassword KubernetesAuthType + ServiceAccount KubernetesAuthType + OpenIdConnect KubernetesAuthType + ClientKeyCert KubernetesAuthType }{ UsernamePassword: "UsernamePassword", ServiceAccount: "ServiceAccount", @@ -14,6 +14,6 @@ var KubernetesAuthMethods = struct { ClientKeyCert: "ClientKeyCert", } -func (k KubernetesAuthMethod) String() string { +func (k KubernetesAuthType) String() string { return string(k) } diff --git a/harness/nextgen/model_account.go b/harness/nextgen/model_account.go index 7c248463..efa6f064 100644 --- a/harness/nextgen/model_account.go +++ b/harness/nextgen/model_account.go @@ -43,7 +43,7 @@ type Account struct { ServiceAccountConfig *ServiceAccountConfig `json:"serviceAccountConfig,omitempty"` Defaults map[string]string `json:"defaults,omitempty"` AuthenticationMechanism string `json:"authenticationMechanism,omitempty"` - PovAccount bool `json:"povAccount,omitempty"` HarnessSupportAccessAllowed bool `json:"harnessSupportAccessAllowed,omitempty"` + PovAccount bool `json:"povAccount,omitempty"` Events []AccountEvent `json:"events,omitempty"` } diff --git a/harness/nextgen/model_account_license.go b/harness/nextgen/model_account_license.go index b3c0dbc2..5ffc472f 100644 --- a/harness/nextgen/model_account_license.go +++ b/harness/nextgen/model_account_license.go @@ -9,7 +9,7 @@ */ package nextgen -// This is the view of an Account License defined in Harness +// This contains details of the Account License defined in Harness type AccountLicense struct { AccountId string `json:"accountId,omitempty"` ModuleLicenses map[string]ModuleLicense `json:"moduleLicenses,omitempty"` diff --git a/harness/nextgen/model_aggregate_acl_request.go b/harness/nextgen/model_aggregate_acl_request.go deleted file mode 100644 index 886ebfcd..00000000 --- a/harness/nextgen/model_aggregate_acl_request.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type AggregateAclRequest struct { - SearchTerm string `json:"searchTerm,omitempty"` - ResourceGroupFilter []string `json:"resourceGroupFilter,omitempty"` - RoleFilter []string `json:"roleFilter,omitempty"` -} diff --git a/harness/nextgen/model_api_key_aggregate_dto.go b/harness/nextgen/model_api_key_aggregate_dto.go deleted file mode 100644 index 47e640c5..00000000 --- a/harness/nextgen/model_api_key_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ApiKeyAggregateDto struct { - ApiKey *ApiKeyDto `json:"apiKey"` - CreatedAt int64 `json:"createdAt"` - LastModifiedAt int64 `json:"lastModifiedAt"` - TokensCount int32 `json:"tokensCount,omitempty"` -} diff --git a/harness/nextgen/model_api_key_dto.go b/harness/nextgen/model_api_key_dto.go deleted file mode 100644 index cec1adaa..00000000 --- a/harness/nextgen/model_api_key_dto.go +++ /dev/null @@ -1,23 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ApiKeyDto struct { - Identifier string `json:"identifier,omitempty"` - Name string `json:"name,omitempty"` - Description string `json:"description,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - ApiKeyType string `json:"apiKeyType,omitempty"` - ParentIdentifier string `json:"parentIdentifier,omitempty"` - DefaultTimeToExpireToken int64 `json:"defaultTimeToExpireToken,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` -} diff --git a/harness/nextgen/model_app_dynamics_connector_dto.go b/harness/nextgen/model_app_dynamics_connector_dto.go index b2a2c55a..25f40e78 100644 --- a/harness/nextgen/model_app_dynamics_connector_dto.go +++ b/harness/nextgen/model_app_dynamics_connector_dto.go @@ -10,12 +10,12 @@ package nextgen type AppDynamicsConnectorDto struct { - Username string `json:"username,omitempty"` - Accountname string `json:"accountname"` - ControllerUrl string `json:"controllerUrl"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` - PasswordRef string `json:"passwordRef,omitempty"` - ClientSecretRef string `json:"clientSecretRef,omitempty"` - ClientId string `json:"clientId,omitempty"` - AuthType string `json:"authType,omitempty"` + Username string `json:"username,omitempty"` + Accountname string `json:"accountname"` + ControllerUrl string `json:"controllerUrl"` + DelegateSelectors []string `json:"delegateSelectors,omitempty"` + PasswordRef string `json:"passwordRef,omitempty"` + ClientSecretRef string `json:"clientSecretRef,omitempty"` + ClientId string `json:"clientId,omitempty"` + AuthType AppDynamicsAuthType `json:"authType,omitempty"` } diff --git a/harness/nextgen/model_artifact_summary.go b/harness/nextgen/model_artifact_summary.go deleted file mode 100644 index 967b53a9..00000000 --- a/harness/nextgen/model_artifact_summary.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ArtifactSummary struct { - DisplayName string `json:"displayName,omitempty"` - Type_ string `json:"type,omitempty"` -} diff --git a/harness/nextgen/model_add_users_response.go b/harness/nextgen/model_artifactory_auth_credentials.go similarity index 76% rename from harness/nextgen/model_add_users_response.go rename to harness/nextgen/model_artifactory_auth_credentials.go index 27871453..21cbc3ef 100644 --- a/harness/nextgen/model_add_users_response.go +++ b/harness/nextgen/model_artifactory_auth_credentials.go @@ -9,6 +9,6 @@ */ package nextgen -type AddUsersResponse struct { - AddUserResponseMap map[string]string `json:"addUserResponseMap,omitempty"` +// This contains details of credentials for Artifactory Authentication +type ArtifactoryAuthCredentials struct { } diff --git a/harness/nextgen/model_instance_count_details_by_env_type_and_service_id.go b/harness/nextgen/model_artifactory_authentication.go similarity index 54% rename from harness/nextgen/model_instance_count_details_by_env_type_and_service_id.go rename to harness/nextgen/model_artifactory_authentication.go index 3232ff8c..f4235f4a 100644 --- a/harness/nextgen/model_instance_count_details_by_env_type_and_service_id.go +++ b/harness/nextgen/model_artifactory_authentication.go @@ -9,6 +9,11 @@ */ package nextgen -type InstanceCountDetailsByEnvTypeAndServiceId struct { - InstanceCountDetailsByEnvTypeBaseMap map[string]InstanceCountDetailsByEnvTypeBase `json:"instanceCountDetailsByEnvTypeBaseMap,omitempty"` +import "encoding/json" + +// This contains details of Artifactory Authentication +type ArtifactoryAuthentication struct { + Type_ ArtifactoryAuthType `json:"type"` + UsernamePassword *ArtifactoryUsernamePasswordAuth `json:"-"` + Spec json.RawMessage `json:"spec,omitempty"` } diff --git a/harness/nextgen/model_artifactory_authentication_serializer.go b/harness/nextgen/model_artifactory_authentication_serializer.go index 6ffbb087..11fa9301 100644 --- a/harness/nextgen/model_artifactory_authentication_serializer.go +++ b/harness/nextgen/model_artifactory_authentication_serializer.go @@ -5,9 +5,9 @@ import ( "fmt" ) -func (a *ArtifactoryAuthenticationDto) UnmarshalJSON(data []byte) error { +func (a *ArtifactoryAuthentication) UnmarshalJSON(data []byte) error { - type Alias ArtifactoryAuthenticationDto + type Alias ArtifactoryAuthentication aux := &struct { *Alias @@ -21,9 +21,9 @@ func (a *ArtifactoryAuthenticationDto) UnmarshalJSON(data []byte) error { } switch a.Type_ { - case ArtifactoryAuthTypes.UsernamePassword.String(): + case ArtifactoryAuthTypes.UsernamePassword: err = json.Unmarshal(aux.Spec, &a.UsernamePassword) - case ArtifactoryAuthTypes.Anonymous.String(): + case ArtifactoryAuthTypes.Anonymous: // nothing to do default: panic(fmt.Sprintf("unknown artifactory auth method type %s", a.Type_)) @@ -32,16 +32,16 @@ func (a *ArtifactoryAuthenticationDto) UnmarshalJSON(data []byte) error { return err } -func (a *ArtifactoryAuthenticationDto) MarshalJSON() ([]byte, error) { - type Alias ArtifactoryAuthenticationDto +func (a *ArtifactoryAuthentication) MarshalJSON() ([]byte, error) { + type Alias ArtifactoryAuthentication var spec []byte var err error switch a.Type_ { - case ArtifactoryAuthTypes.UsernamePassword.String(): + case ArtifactoryAuthTypes.UsernamePassword: spec, err = json.Marshal(a.UsernamePassword) - case ArtifactoryAuthTypes.Anonymous.String(): + case ArtifactoryAuthTypes.Anonymous: // nothing to do default: panic(fmt.Sprintf("unknown artifactory auth method type %s", a.Type_)) diff --git a/harness/nextgen/model_aws_kms_sts_credential_config.go b/harness/nextgen/model_artifactory_connector.go similarity index 53% rename from harness/nextgen/model_aws_kms_sts_credential_config.go rename to harness/nextgen/model_artifactory_connector.go index e73c4f28..63899a8c 100644 --- a/harness/nextgen/model_aws_kms_sts_credential_config.go +++ b/harness/nextgen/model_artifactory_connector.go @@ -9,9 +9,9 @@ */ package nextgen -type AwsKmsStsCredentialConfig struct { - DelegateSelectors []string `json:"delegateSelectors,omitempty"` - RoleArn string `json:"roleArn,omitempty"` - ExternalName string `json:"externalName,omitempty"` - AssumeStsRoleDuration int32 `json:"assumeStsRoleDuration,omitempty"` +// This contains details of Artifactory Connector +type ArtifactoryConnector struct { + ArtifactoryServerUrl string `json:"artifactoryServerUrl"` + Auth *ArtifactoryAuthentication `json:"auth,omitempty"` + DelegateSelectors []string `json:"delegateSelectors,omitempty"` } diff --git a/harness/nextgen/model_artifactory_connector_dto.go b/harness/nextgen/model_artifactory_connector_dto.go deleted file mode 100644 index 0e1dd362..00000000 --- a/harness/nextgen/model_artifactory_connector_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ArtifactoryConnectorDto struct { - ArtifactoryServerUrl string `json:"artifactoryServerUrl"` - Auth *ArtifactoryAuthenticationDto `json:"auth,omitempty"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` -} diff --git a/harness/nextgen/model_artifactory_username_password_auth.go b/harness/nextgen/model_artifactory_username_password_auth.go new file mode 100644 index 00000000..ae4e2d2a --- /dev/null +++ b/harness/nextgen/model_artifactory_username_password_auth.go @@ -0,0 +1,17 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of Artifactory Username and Password +type ArtifactoryUsernamePasswordAuth struct { + Username string `json:"username,omitempty"` + UsernameRef string `json:"usernameRef,omitempty"` + PasswordRef string `json:"passwordRef"` +} diff --git a/harness/nextgen/model_artifacts_summary.go b/harness/nextgen/model_artifacts_summary.go deleted file mode 100644 index 8dd0f2e7..00000000 --- a/harness/nextgen/model_artifacts_summary.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ArtifactsSummary struct { - Primary *ArtifactSummary `json:"primary,omitempty"` - Sidecars []ArtifactSummary `json:"sidecars,omitempty"` -} diff --git a/harness/nextgen/model_authenticationsettings_samlmetadataupload_body.go b/harness/nextgen/model_authenticationsettings_samlmetadataupload_body.go index f5d74d9b..1cd73ce6 100644 --- a/harness/nextgen/model_authenticationsettings_samlmetadataupload_body.go +++ b/harness/nextgen/model_authenticationsettings_samlmetadataupload_body.go @@ -15,4 +15,5 @@ type AuthenticationsettingsSamlmetadatauploadBody struct { GroupMembershipAttr string `json:"groupMembershipAttr,omitempty"` AuthorizationEnabled bool `json:"authorizationEnabled,omitempty"` LogoutUrl string `json:"logoutUrl,omitempty"` + EntityIdentifier string `json:"entityIdentifier,omitempty"` } diff --git a/harness/nextgen/model_authenticationsettings_samlmetadataupload_body_1.go b/harness/nextgen/model_authenticationsettings_samlmetadataupload_body_1.go index 2e7d8a2d..c967ba18 100644 --- a/harness/nextgen/model_authenticationsettings_samlmetadataupload_body_1.go +++ b/harness/nextgen/model_authenticationsettings_samlmetadataupload_body_1.go @@ -15,4 +15,5 @@ type AuthenticationsettingsSamlmetadatauploadBody1 struct { GroupMembershipAttr string `json:"groupMembershipAttr,omitempty"` AuthorizationEnabled bool `json:"authorizationEnabled,omitempty"` LogoutUrl string `json:"logoutUrl,omitempty"` + EntityIdentifier string `json:"entityIdentifier,omitempty"` } diff --git a/harness/nextgen/model_author_info.go b/harness/nextgen/model_author_info.go deleted file mode 100644 index 9588f562..00000000 --- a/harness/nextgen/model_author_info.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type AuthorInfo struct { - Name string `json:"name,omitempty"` - Url string `json:"url,omitempty"` -} diff --git a/harness/nextgen/model_jira_status_ng.go b/harness/nextgen/model_availability_restriction.go similarity index 64% rename from harness/nextgen/model_jira_status_ng.go rename to harness/nextgen/model_availability_restriction.go index 4700d2a9..1843ba5e 100644 --- a/harness/nextgen/model_jira_status_ng.go +++ b/harness/nextgen/model_availability_restriction.go @@ -9,8 +9,8 @@ */ package nextgen -type JiraStatusNg struct { - Id string `json:"id"` - Name string `json:"name"` - StatusCategory *JiraStatusCategoryNg `json:"statusCategory,omitempty"` +// This contains details of the Availability Restriction in Harness +type AvailabilityRestriction struct { + RestrictionType string `json:"restrictionType"` + Enabled bool `json:"enabled,omitempty"` } diff --git a/harness/nextgen/model_availability_restriction_metadata_dto.go b/harness/nextgen/model_availability_restriction_metadata.go similarity index 80% rename from harness/nextgen/model_availability_restriction_metadata_dto.go rename to harness/nextgen/model_availability_restriction_metadata.go index 10699ef5..7e885a78 100644 --- a/harness/nextgen/model_availability_restriction_metadata_dto.go +++ b/harness/nextgen/model_availability_restriction_metadata.go @@ -9,7 +9,8 @@ */ package nextgen -type AvailabilityRestrictionMetadataDto struct { +// This contains metadata of the Availability Restriction in Harness +type AvailabilityRestrictionMetadata struct { RestrictionType string `json:"restrictionType,omitempty"` Enabled bool `json:"enabled,omitempty"` } diff --git a/harness/nextgen/model_aws_code_commit_authentication.go b/harness/nextgen/model_aws_code_commit_authentication.go new file mode 100644 index 00000000..651d5c9f --- /dev/null +++ b/harness/nextgen/model_aws_code_commit_authentication.go @@ -0,0 +1,16 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the AWS Code Commit credentials +type AwsCodeCommitAuthentication struct { + Type_ string `json:"type"` + Spec *AwsCodeCommitCredentials `json:"spec"` +} diff --git a/harness/nextgen/model_aws_code_commit_authentication_dto.go b/harness/nextgen/model_aws_code_commit_authentication_dto.go deleted file mode 100644 index 2fbe9851..00000000 --- a/harness/nextgen/model_aws_code_commit_authentication_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type AwsCodeCommitAuthenticationDto struct { - Type_ string `json:"type"` - Spec *AwsCodeCommitCredentialsDto `json:"spec"` -} diff --git a/harness/nextgen/model_kubernetes_credential_dto.go b/harness/nextgen/model_aws_code_commit_connector.go similarity index 57% rename from harness/nextgen/model_kubernetes_credential_dto.go rename to harness/nextgen/model_aws_code_commit_connector.go index 61894469..ea3ae44e 100644 --- a/harness/nextgen/model_kubernetes_credential_dto.go +++ b/harness/nextgen/model_aws_code_commit_connector.go @@ -9,12 +9,10 @@ */ package nextgen -import ( - "encoding/json" -) - -type KubernetesCredentialDto struct { - ManualCredentials *KubernetesClusterDetailsDto `json:"-"` +// This contains details of the AWS Code Commit connector +type AwsCodeCommitConnector struct { + Url string `json:"url"` + Authentication *AwsCodeCommitAuthentication `json:"authentication"` + DelegateSelectors []string `json:"delegateSelectors,omitempty"` Type_ string `json:"type"` - Spec json.RawMessage `json:"spec,omitempty"` } diff --git a/harness/nextgen/model_aws_kms_iam_credential_config.go b/harness/nextgen/model_aws_code_commit_credentials.go similarity index 77% rename from harness/nextgen/model_aws_kms_iam_credential_config.go rename to harness/nextgen/model_aws_code_commit_credentials.go index 5a08040e..37659253 100644 --- a/harness/nextgen/model_aws_kms_iam_credential_config.go +++ b/harness/nextgen/model_aws_code_commit_credentials.go @@ -9,6 +9,6 @@ */ package nextgen -type AwsKmsIamCredentialConfig struct { - DelegateSelectors []string `json:"delegateSelectors,omitempty"` +// This interface for details of the AWS Code Commit credentials +type AwsCodeCommitCredentials struct { } diff --git a/harness/nextgen/model_aws_code_commit_https_credentials.go b/harness/nextgen/model_aws_code_commit_https_credentials.go new file mode 100644 index 00000000..9c135e40 --- /dev/null +++ b/harness/nextgen/model_aws_code_commit_https_credentials.go @@ -0,0 +1,16 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the AWS Code Commit credentials used via HTTPS connections +type AwsCodeCommitHttpsCredentials struct { + Type_ string `json:"type"` + Spec *AwsCodeCommitHttpsCredentialsSpec `json:"spec"` +} diff --git a/harness/nextgen/model_aws_code_commit_https_credentials_dto.go b/harness/nextgen/model_aws_code_commit_https_credentials_dto.go deleted file mode 100644 index 89da3b6b..00000000 --- a/harness/nextgen/model_aws_code_commit_https_credentials_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type AwsCodeCommitHttpsCredentialsDto struct { - Type_ string `json:"type"` - Spec *AwsCodeCommitHttpsCredentialsSpecDto `json:"spec"` -} diff --git a/harness/nextgen/model_aws_code_commit_https_credentials_spec.go b/harness/nextgen/model_aws_code_commit_https_credentials_spec.go new file mode 100644 index 00000000..61f468de --- /dev/null +++ b/harness/nextgen/model_aws_code_commit_https_credentials_spec.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the AWS Code Commit credentials specs such as references of username and password used via HTTPS connections +type AwsCodeCommitHttpsCredentialsSpec struct { +} diff --git a/harness/nextgen/model_aws_code_commit_https_credentials_spec_dto.go b/harness/nextgen/model_aws_code_commit_https_credentials_spec_dto.go deleted file mode 100644 index 2f45c205..00000000 --- a/harness/nextgen/model_aws_code_commit_https_credentials_spec_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type AwsCodeCommitHttpsCredentialsSpecDto struct { -} diff --git a/harness/nextgen/model_aws_manual_config_spec_dto.go b/harness/nextgen/model_aws_code_commit_secret_key_access_key.go similarity index 81% rename from harness/nextgen/model_aws_manual_config_spec_dto.go rename to harness/nextgen/model_aws_code_commit_secret_key_access_key.go index c38c8f8b..fb50ddbc 100644 --- a/harness/nextgen/model_aws_manual_config_spec_dto.go +++ b/harness/nextgen/model_aws_code_commit_secret_key_access_key.go @@ -9,7 +9,8 @@ */ package nextgen -type AwsManualConfigSpecDto struct { +// This contains details of the AWS Code Commit secret references +type AwsCodeCommitSecretKeyAccessKey struct { AccessKey string `json:"accessKey,omitempty"` AccessKeyRef string `json:"accessKeyRef,omitempty"` SecretKeyRef string `json:"secretKeyRef"` diff --git a/harness/nextgen/model_yaml_snippets_dto.go b/harness/nextgen/model_aws_connector.go similarity index 65% rename from harness/nextgen/model_yaml_snippets_dto.go rename to harness/nextgen/model_aws_connector.go index 8fdeaa73..1e1e70de 100644 --- a/harness/nextgen/model_yaml_snippets_dto.go +++ b/harness/nextgen/model_aws_connector.go @@ -9,6 +9,8 @@ */ package nextgen -type YamlSnippetsDto struct { - YamlSnippets []YamlSnippetMetaDataDto `json:"yamlSnippets,omitempty"` +// This contains details of the AWS connector +type AwsConnector struct { + Credential *AwsCredential `json:"credential"` + DelegateSelectors []string `json:"delegateSelectors,omitempty"` } diff --git a/harness/nextgen/model_aws_connector_dto.go b/harness/nextgen/model_aws_connector_dto.go deleted file mode 100644 index 70eec919..00000000 --- a/harness/nextgen/model_aws_connector_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type AwsConnectorDto struct { - Credential *AwsCredentialDto `json:"credential"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` -} diff --git a/harness/nextgen/model_aws_credential.go b/harness/nextgen/model_aws_credential.go new file mode 100644 index 00000000..f1b61aed --- /dev/null +++ b/harness/nextgen/model_aws_credential.go @@ -0,0 +1,20 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import "encoding/json" + +// This contains details of the AWS connector credential +type AwsCredential struct { + CrossAccountAccess *CrossAccountAccess `json:"crossAccountAccess,omitempty"` + Type_ AwsAuthType `json:"type"` + ManualConfig *AwsManualConfigSpec `json:"-"` + Spec json.RawMessage `json:"spec,omitempty"` +} diff --git a/harness/nextgen/model_aws_credential_dto.go b/harness/nextgen/model_aws_credential_dto.go deleted file mode 100644 index cb979a62..00000000 --- a/harness/nextgen/model_aws_credential_dto.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -import ( - "encoding/json" -) - -type AwsCredentialDto struct { - CrossAccountAccess *CrossAccountAccessDto `json:"crossAccountAccess,omitempty"` - Type_ string `json:"type"` - ManualConfig *AwsManualConfigSpecDto `json:"-"` - Spec json.RawMessage `json:"spec,omitempty"` -} diff --git a/harness/nextgen/model_aws_credential_serializer.go b/harness/nextgen/model_aws_credential_serializer.go index abc4de0c..4c7ba496 100644 --- a/harness/nextgen/model_aws_credential_serializer.go +++ b/harness/nextgen/model_aws_credential_serializer.go @@ -5,9 +5,9 @@ import ( "fmt" ) -func (a *AwsCredentialDto) UnmarshalJSON(data []byte) error { +func (a *AwsCredential) UnmarshalJSON(data []byte) error { - type Alias AwsCredentialDto + type Alias AwsCredential aux := &struct { *Alias @@ -21,10 +21,10 @@ func (a *AwsCredentialDto) UnmarshalJSON(data []byte) error { } switch a.Type_ { - case AwsAuthTypes.ManualConfig.String(): + case AwsAuthTypes.ManualConfig: err = json.Unmarshal(aux.Spec, &a.ManualConfig) - case AwsAuthTypes.InheritFromDelegate.String(): - case AwsAuthTypes.Irsa.String(): + case AwsAuthTypes.InheritFromDelegate: + case AwsAuthTypes.Irsa: // do nothing default: panic(fmt.Sprintf("unknown aws auth type %s", a.Type_)) @@ -33,17 +33,17 @@ func (a *AwsCredentialDto) UnmarshalJSON(data []byte) error { return err } -func (a *AwsCredentialDto) MarshalJSON() ([]byte, error) { - type Alias AwsCredentialDto +func (a *AwsCredential) MarshalJSON() ([]byte, error) { + type Alias AwsCredential var spec []byte var err error switch a.Type_ { - case AwsAuthTypes.ManualConfig.String(): + case AwsAuthTypes.ManualConfig: spec, err = json.Marshal(a.ManualConfig) - case AwsAuthTypes.InheritFromDelegate.String(): - case AwsAuthTypes.Irsa.String(): + case AwsAuthTypes.InheritFromDelegate: + case AwsAuthTypes.Irsa: // do nothing default: panic(fmt.Sprintf("unknown aws auth type %s", a.Type_)) diff --git a/harness/nextgen/model_activity_detail.go b/harness/nextgen/model_aws_credential_spec.go similarity index 81% rename from harness/nextgen/model_activity_detail.go rename to harness/nextgen/model_aws_credential_spec.go index c37e750e..71c5571a 100644 --- a/harness/nextgen/model_activity_detail.go +++ b/harness/nextgen/model_aws_credential_spec.go @@ -9,5 +9,6 @@ */ package nextgen -type ActivityDetail struct { +// This contains AWS connector credential spec +type AwsCredentialSpec struct { } diff --git a/harness/nextgen/model_aws_credential_spec_dto.go b/harness/nextgen/model_aws_credential_spec_dto.go deleted file mode 100644 index 73394570..00000000 --- a/harness/nextgen/model_aws_credential_spec_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type AwsCredentialSpecDto struct { -} diff --git a/harness/nextgen/model_aws_kms_config_dto.go b/harness/nextgen/model_aws_kms_config_dto.go deleted file mode 100644 index 4575fa87..00000000 --- a/harness/nextgen/model_aws_kms_config_dto.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type AwsKmsConfigDto struct { - Name string `json:"name,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Identifier string `json:"identifier,omitempty"` - Description string `json:"description,omitempty"` - EncryptionType string `json:"encryptionType,omitempty"` - HarnessManaged bool `json:"harnessManaged,omitempty"` - Default_ bool `json:"default,omitempty"` - BaseAwsKmsConfigDTO *BaseAwsKmsConfigDto `json:"baseAwsKmsConfigDTO,omitempty"` -} diff --git a/harness/nextgen/model_aws_kms_connector_credential_dto.go b/harness/nextgen/model_aws_kms_connector_credential_dto.go index 9e510c0c..c279834f 100644 --- a/harness/nextgen/model_aws_kms_connector_credential_dto.go +++ b/harness/nextgen/model_aws_kms_connector_credential_dto.go @@ -9,7 +9,12 @@ */ package nextgen +import "encoding/json" + type AwsKmsConnectorCredentialDto struct { - Type_ string `json:"type"` - Spec *AwsKmsCredentialSpecDto `json:"spec,omitempty"` + Type_ AwsKmsAuthType `json:"type"` + AssumeIamRole *AwsKmsCredentialSpecAssumeIamdto `json:"-"` + AssumeStsRole *AwsKmsCredentialSpecAssumeStsdto `json:"-"` + ManualConfig *AwsKmsCredentialSpecManualConfigDto `json:"-"` + Spec json.RawMessage `json:"spec,omitempty"` } diff --git a/harness/nextgen/model_aws_kms_connector_credential_serializer.go b/harness/nextgen/model_aws_kms_connector_credential_serializer.go new file mode 100644 index 00000000..0359dbdb --- /dev/null +++ b/harness/nextgen/model_aws_kms_connector_credential_serializer.go @@ -0,0 +1,61 @@ +package nextgen + +import ( + "encoding/json" + "fmt" +) + +func (a *AwsKmsConnectorCredentialDto) UnmarshalJSON(data []byte) error { + + type Alias AwsKmsConnectorCredentialDto + + aux := &struct { + *Alias + }{ + Alias: (*Alias)(a), + } + + err := json.Unmarshal(data, &aux) + if err != nil { + return err + } + + switch a.Type_ { + case AwsKmsAuthTypes.AssumeIAMRole: + err = json.Unmarshal(aux.Spec, &a.AssumeIamRole) + case AwsKmsAuthTypes.AssumeSTSRole: + err = json.Unmarshal(aux.Spec, &a.AssumeStsRole) + case AwsKmsAuthTypes.ManualConfig: + err = json.Unmarshal(aux.Spec, &a.ManualConfig) + default: + panic(fmt.Sprintf("unknown aws kms auth type %s", a.Type_)) + } + + return err +} + +func (a *AwsKmsConnectorCredentialDto) MarshalJSON() ([]byte, error) { + type Alias AwsKmsConnectorCredentialDto + + var spec []byte + var err error + + switch a.Type_ { + case AwsKmsAuthTypes.AssumeIAMRole: + spec, err = json.Marshal(a.AssumeIamRole) + case AwsKmsAuthTypes.AssumeSTSRole: + spec, err = json.Marshal(a.AssumeStsRole) + case AwsKmsAuthTypes.ManualConfig: + spec, err = json.Marshal(a.ManualConfig) + default: + panic(fmt.Sprintf("unknown aws kms auth type %s", a.Type_)) + } + + if err != nil { + return nil, err + } + + a.Spec = json.RawMessage(spec) + + return json.Marshal((*Alias)(a)) +} diff --git a/harness/nextgen/model_aws_kms_credential_spec_config.go b/harness/nextgen/model_aws_kms_credential_spec_config.go deleted file mode 100644 index 8fa73e8d..00000000 --- a/harness/nextgen/model_aws_kms_credential_spec_config.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type AwsKmsCredentialSpecConfig struct { -} diff --git a/harness/nextgen/model_aws_kms_manual_credential_config.go b/harness/nextgen/model_aws_kms_manual_credential_config.go deleted file mode 100644 index a46fae75..00000000 --- a/harness/nextgen/model_aws_kms_manual_credential_config.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type AwsKmsManualCredentialConfig struct { - AccessKey string `json:"accessKey,omitempty"` - SecretKey string `json:"secretKey,omitempty"` -} diff --git a/harness/nextgen/model_aws_code_commit_secret_key_access_key_dto.go b/harness/nextgen/model_aws_manual_config_spec.go similarity index 84% rename from harness/nextgen/model_aws_code_commit_secret_key_access_key_dto.go rename to harness/nextgen/model_aws_manual_config_spec.go index 5d5cb716..912c7ae2 100644 --- a/harness/nextgen/model_aws_code_commit_secret_key_access_key_dto.go +++ b/harness/nextgen/model_aws_manual_config_spec.go @@ -9,7 +9,8 @@ */ package nextgen -type AwsCodeCommitSecretKeyAccessKeyDto struct { +// This contains AWS manual credentials connector spec +type AwsManualConfigSpec struct { AccessKey string `json:"accessKey,omitempty"` AccessKeyRef string `json:"accessKeyRef,omitempty"` SecretKeyRef string `json:"secretKeyRef"` diff --git a/harness/nextgen/model_aws_secret_manager_credential_dto.go b/harness/nextgen/model_aws_secret_manager_credential_dto.go index 708ef4c1..0917db16 100644 --- a/harness/nextgen/model_aws_secret_manager_credential_dto.go +++ b/harness/nextgen/model_aws_secret_manager_credential_dto.go @@ -9,7 +9,12 @@ */ package nextgen +import "encoding/json" + type AwsSecretManagerCredentialDto struct { - Type_ string `json:"type"` - Spec *AwsSecretManagerCredentialSpecDto `json:"spec,omitempty"` + Type_ AwsSecretManagerAuthType `json:"type"` + AssumeIamRole *AwsSmCredentialSpecAssumeIamdto `json:"-"` + AssumeStsRole *AwsSmCredentialSpecAssumeStsdto `json:"-"` + ManualConfig *AwsSmCredentialSpecManualConfigDto `json:"-"` + Spec json.RawMessage `json:"spec,omitempty"` } diff --git a/harness/nextgen/model_aws_secret_manager_credential_serializer.go b/harness/nextgen/model_aws_secret_manager_credential_serializer.go new file mode 100644 index 00000000..e20f6d25 --- /dev/null +++ b/harness/nextgen/model_aws_secret_manager_credential_serializer.go @@ -0,0 +1,61 @@ +package nextgen + +import ( + "encoding/json" + "fmt" +) + +func (a *AwsSecretManagerCredentialDto) UnmarshalJSON(data []byte) error { + + type Alias AwsSecretManagerCredentialDto + + aux := &struct { + *Alias + }{ + Alias: (*Alias)(a), + } + + err := json.Unmarshal(data, &aux) + if err != nil { + return err + } + + switch a.Type_ { + case AwsSecretManagerAuthTypes.AssumeIAMRole: + // noop + case AwsSecretManagerAuthTypes.AssumeSTSRole: + err = json.Unmarshal(aux.Spec, &a.AssumeStsRole) + case AwsSecretManagerAuthTypes.ManualConfig: + err = json.Unmarshal(aux.Spec, &a.ManualConfig) + default: + panic(fmt.Sprintf("unknown aws kms auth type %s", a.Type_)) + } + + return err +} + +func (a *AwsSecretManagerCredentialDto) MarshalJSON() ([]byte, error) { + type Alias AwsSecretManagerCredentialDto + + var spec []byte + var err error + + switch a.Type_ { + case AwsSecretManagerAuthTypes.AssumeIAMRole: + // noop + case AwsSecretManagerAuthTypes.AssumeSTSRole: + spec, err = json.Marshal(a.AssumeStsRole) + case AwsSecretManagerAuthTypes.ManualConfig: + spec, err = json.Marshal(a.ManualConfig) + default: + panic(fmt.Sprintf("unknown aws kms auth type %s", a.Type_)) + } + + if err != nil { + return nil, err + } + + a.Spec = json.RawMessage(spec) + + return json.Marshal((*Alias)(a)) +} diff --git a/harness/nextgen/model_azure_key_vault_config_dto.go b/harness/nextgen/model_azure_key_vault_config_dto.go deleted file mode 100644 index 508c6b12..00000000 --- a/harness/nextgen/model_azure_key_vault_config_dto.go +++ /dev/null @@ -1,30 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type AzureKeyVaultConfigDto struct { - Name string `json:"name,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Identifier string `json:"identifier,omitempty"` - Description string `json:"description,omitempty"` - EncryptionType string `json:"encryptionType,omitempty"` - HarnessManaged bool `json:"harnessManaged,omitempty"` - Default_ bool `json:"default,omitempty"` - ClientId string `json:"clientId,omitempty"` - SecretKey string `json:"secretKey,omitempty"` - TenantId string `json:"tenantId,omitempty"` - VaultName string `json:"vaultName,omitempty"` - Subscription string `json:"subscription,omitempty"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` - AzureEnvironmentType string `json:"azureEnvironmentType,omitempty"` -} diff --git a/harness/nextgen/model_barrier_info_config.go b/harness/nextgen/model_barrier_info_config.go deleted file mode 100644 index 876e7f15..00000000 --- a/harness/nextgen/model_barrier_info_config.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BarrierInfoConfig struct { - Identifier string `json:"identifier"` - Name string `json:"name"` -} diff --git a/harness/nextgen/model_base_aws_kms_config_dto.go b/harness/nextgen/model_base_aws_kms_config_dto.go deleted file mode 100644 index 7050965d..00000000 --- a/harness/nextgen/model_base_aws_kms_config_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BaseAwsKmsConfigDto struct { - CredentialType string `json:"credentialType,omitempty"` - Credential *AwsKmsCredentialSpecConfig `json:"credential,omitempty"` - KmsArn string `json:"kmsArn,omitempty"` - Region string `json:"region,omitempty"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` -} diff --git a/harness/nextgen/model_bitbucket_api_access.go b/harness/nextgen/model_bitbucket_api_access.go new file mode 100644 index 00000000..c0c374d5 --- /dev/null +++ b/harness/nextgen/model_bitbucket_api_access.go @@ -0,0 +1,19 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import "encoding/json" + +// This contains details of the information needed for Bitbucket API access +type BitbucketApiAccess struct { + Type_ BitBucketApiAccessType `json:"type"` + UsernameToken *BitbucketUsernameTokenApiAccess `json:"-"` + Spec json.RawMessage `json:"spec"` +} diff --git a/harness/nextgen/model_bitbucket_api_access_dto.go b/harness/nextgen/model_bitbucket_api_access_dto.go deleted file mode 100644 index d6cdf8a0..00000000 --- a/harness/nextgen/model_bitbucket_api_access_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BitbucketApiAccessDto struct { - Type_ string `json:"type"` - Spec *BitbucketApiAccessSpecDto `json:"spec"` -} diff --git a/harness/nextgen/model_bitbucket_api_access_serializer.go b/harness/nextgen/model_bitbucket_api_access_serializer.go new file mode 100644 index 00000000..07c3f191 --- /dev/null +++ b/harness/nextgen/model_bitbucket_api_access_serializer.go @@ -0,0 +1,53 @@ +package nextgen + +import ( + "encoding/json" + "fmt" +) + +func (a *BitbucketApiAccess) UnmarshalJSON(data []byte) error { + + type Alias BitbucketApiAccess + + aux := &struct { + *Alias + }{ + Alias: (*Alias)(a), + } + + err := json.Unmarshal(data, &aux) + if err != nil { + return err + } + + switch a.Type_ { + case BitBucketApiAccessTypes.UsernameToken: + err = json.Unmarshal(aux.Spec, &a.UsernameToken) + default: + panic(fmt.Sprintf("unknown BitBucket api auth method type %s", a.Type_)) + } + + return err +} + +func (a *BitbucketApiAccess) MarshalJSON() ([]byte, error) { + type Alias BitbucketApiAccess + + var spec []byte + var err error + + switch a.Type_ { + case BitBucketApiAccessTypes.UsernameToken: + spec, err = json.Marshal(a.UsernameToken) + default: + panic(fmt.Sprintf("unknown BitBucket api auth method type %s", a.Type_)) + } + + if err != nil { + return nil, err + } + + a.Spec = json.RawMessage(spec) + + return json.Marshal((*Alias)(a)) +} diff --git a/harness/nextgen/model_bitbucket_api_access_spec_dto.go b/harness/nextgen/model_bitbucket_api_access_spec_dto.go deleted file mode 100644 index 098e0eb0..00000000 --- a/harness/nextgen/model_bitbucket_api_access_spec_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BitbucketApiAccessSpecDto struct { -} diff --git a/harness/nextgen/model_bitbucket_authentication.go b/harness/nextgen/model_bitbucket_authentication.go new file mode 100644 index 00000000..7e458369 --- /dev/null +++ b/harness/nextgen/model_bitbucket_authentication.go @@ -0,0 +1,20 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import "encoding/json" + +// This contains details of the information needed for Bitbucket access +type BitbucketAuthentication struct { + Type_ GitAuthType `json:"type"` + Ssh *BitbucketSshCredentials `json:"-"` + Http *BitbucketHttpCredentials `json:"-"` + Spec json.RawMessage `json:"spec"` +} diff --git a/harness/nextgen/model_bitbucket_authentication_dto.go b/harness/nextgen/model_bitbucket_authentication_dto.go deleted file mode 100644 index ed593bd3..00000000 --- a/harness/nextgen/model_bitbucket_authentication_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BitbucketAuthenticationDto struct { - Type_ string `json:"type"` - Spec *BitbucketCredentialsDto `json:"spec"` -} diff --git a/harness/nextgen/model_bitbucket_authentication_serializer.go b/harness/nextgen/model_bitbucket_authentication_serializer.go new file mode 100644 index 00000000..91bb598f --- /dev/null +++ b/harness/nextgen/model_bitbucket_authentication_serializer.go @@ -0,0 +1,57 @@ +package nextgen + +import ( + "encoding/json" + "fmt" +) + +func (a *BitbucketAuthentication) UnmarshalJSON(data []byte) error { + + type Alias BitbucketAuthentication + + aux := &struct { + *Alias + }{ + Alias: (*Alias)(a), + } + + err := json.Unmarshal(data, &aux) + if err != nil { + return err + } + + switch a.Type_ { + case GitAuthTypes.Http: + err = json.Unmarshal(aux.Spec, &a.Http) + case GitAuthTypes.Ssh: + err = json.Unmarshal(aux.Spec, &a.Ssh) + default: + panic(fmt.Sprintf("unknown github auth method type %s", a.Type_)) + } + + return err +} + +func (a *BitbucketAuthentication) MarshalJSON() ([]byte, error) { + type Alias BitbucketAuthentication + + var spec []byte + var err error + + switch a.Type_ { + case GitAuthTypes.Http: + spec, err = json.Marshal(a.Http) + case GitAuthTypes.Ssh: + spec, err = json.Marshal(a.Ssh) + default: + panic(fmt.Sprintf("unknown github auth method type %s", a.Type_)) + } + + if err != nil { + return nil, err + } + + a.Spec = json.RawMessage(spec) + + return json.Marshal((*Alias)(a)) +} diff --git a/harness/nextgen/model_bitbucket_cloud_webhook_events.go b/harness/nextgen/model_bitbucket_cloud_webhook_events.go deleted file mode 100644 index 8bd0bed1..00000000 --- a/harness/nextgen/model_bitbucket_cloud_webhook_events.go +++ /dev/null @@ -1,25 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BitbucketCloudWebhookEvents struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - ParserForType *ParserBitbucketCloudWebhookEvents `json:"parserForType,omitempty"` - DefaultInstanceForType *BitbucketCloudWebhookEvents `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - EventsList []string `json:"eventsList,omitempty"` - EventsCount int32 `json:"eventsCount,omitempty"` - EventsValueList []int32 `json:"eventsValueList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_bitbucket_cloud_webhook_events_or_builder.go b/harness/nextgen/model_bitbucket_cloud_webhook_events_or_builder.go deleted file mode 100644 index 14c0c0cb..00000000 --- a/harness/nextgen/model_bitbucket_cloud_webhook_events_or_builder.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BitbucketCloudWebhookEventsOrBuilder struct { - EventsList []string `json:"eventsList,omitempty"` - EventsCount int32 `json:"eventsCount,omitempty"` - EventsValueList []int32 `json:"eventsValueList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_gitlab_connector_dto.go b/harness/nextgen/model_bitbucket_connector.go similarity index 68% rename from harness/nextgen/model_gitlab_connector_dto.go rename to harness/nextgen/model_bitbucket_connector.go index 87c09b39..3beaaa6b 100644 --- a/harness/nextgen/model_gitlab_connector_dto.go +++ b/harness/nextgen/model_bitbucket_connector.go @@ -9,11 +9,12 @@ */ package nextgen -type GitlabConnectorDto struct { +// This contains details of Bitbucket connectors +type BitbucketConnector struct { Url string `json:"url"` ValidationRepo string `json:"validationRepo,omitempty"` - Authentication *GitlabAuthenticationDto `json:"authentication"` - ApiAccess *GitlabApiAccessDto `json:"apiAccess,omitempty"` + Authentication *BitbucketAuthentication `json:"authentication"` + ApiAccess *BitbucketApiAccess `json:"apiAccess,omitempty"` DelegateSelectors []string `json:"delegateSelectors,omitempty"` - Type_ string `json:"type"` + Type_ GitConnectorType `json:"type"` } diff --git a/harness/nextgen/model_bitbucket_connector_dto.go b/harness/nextgen/model_bitbucket_connector_dto.go deleted file mode 100644 index 8890db8a..00000000 --- a/harness/nextgen/model_bitbucket_connector_dto.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BitbucketConnectorDto struct { - Url string `json:"url"` - ValidationRepo string `json:"validationRepo,omitempty"` - Authentication *BitbucketAuthenticationDto `json:"authentication"` - ApiAccess *BitbucketApiAccessDto `json:"apiAccess,omitempty"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` - Type_ string `json:"type"` -} diff --git a/harness/nextgen/model_bitbucket_credentials.go b/harness/nextgen/model_bitbucket_credentials.go new file mode 100644 index 00000000..f5d37a7f --- /dev/null +++ b/harness/nextgen/model_bitbucket_credentials.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This is a interface for details of the Bitbucket credentials +type BitbucketCredentials struct { +} diff --git a/harness/nextgen/model_bitbucket_credentials_dto.go b/harness/nextgen/model_bitbucket_credentials_dto.go deleted file mode 100644 index d2ca8c2f..00000000 --- a/harness/nextgen/model_bitbucket_credentials_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BitbucketCredentialsDto struct { -} diff --git a/harness/nextgen/model_bitbucket_http_credentials.go b/harness/nextgen/model_bitbucket_http_credentials.go new file mode 100644 index 00000000..9421d6a3 --- /dev/null +++ b/harness/nextgen/model_bitbucket_http_credentials.go @@ -0,0 +1,19 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import "encoding/json" + +// This contains details of the Bitbucket credentials used via HTTP connections +type BitbucketHttpCredentials struct { + Type_ BitBucketHttpCredentialType `json:"type"` + UsernamePassword *BitbucketUsernamePassword `json:"-"` + Spec json.RawMessage `json:"spec"` +} diff --git a/harness/nextgen/model_bitbucket_http_credentials_dto.go b/harness/nextgen/model_bitbucket_http_credentials_dto.go deleted file mode 100644 index 514895c4..00000000 --- a/harness/nextgen/model_bitbucket_http_credentials_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BitbucketHttpCredentialsDto struct { - Type_ string `json:"type"` - Spec *BitbucketHttpCredentialsSpecDto `json:"spec"` -} diff --git a/harness/nextgen/model_bitbucket_http_credentials_serializer.go b/harness/nextgen/model_bitbucket_http_credentials_serializer.go new file mode 100644 index 00000000..bf2dfd76 --- /dev/null +++ b/harness/nextgen/model_bitbucket_http_credentials_serializer.go @@ -0,0 +1,53 @@ +package nextgen + +import ( + "encoding/json" + "fmt" +) + +func (a *BitbucketHttpCredentials) UnmarshalJSON(data []byte) error { + + type Alias BitbucketHttpCredentials + + aux := &struct { + *Alias + }{ + Alias: (*Alias)(a), + } + + err := json.Unmarshal(data, &aux) + if err != nil { + return err + } + + switch a.Type_ { + case BitBucketHttpCredentialTypes.UsernamePassword: + err = json.Unmarshal(aux.Spec, &a.UsernamePassword) + default: + panic(fmt.Sprintf("unknown http credentials method type %s", a.Type_)) + } + + return err +} + +func (a *BitbucketHttpCredentials) MarshalJSON() ([]byte, error) { + type Alias BitbucketHttpCredentials + + var spec []byte + var err error + + switch a.Type_ { + case BitBucketHttpCredentialTypes.UsernamePassword: + spec, err = json.Marshal(a.UsernamePassword) + default: + panic(fmt.Sprintf("unknown git auth method type %s", a.Type_)) + } + + if err != nil { + return nil, err + } + + a.Spec = json.RawMessage(spec) + + return json.Marshal((*Alias)(a)) +} diff --git a/harness/nextgen/model_bitbucket_http_credentials_spec.go b/harness/nextgen/model_bitbucket_http_credentials_spec.go new file mode 100644 index 00000000..e8d79877 --- /dev/null +++ b/harness/nextgen/model_bitbucket_http_credentials_spec.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This is a interface for details of the Bitbucket credentials Specs such as references of username and password +type BitbucketHttpCredentialsSpec struct { +} diff --git a/harness/nextgen/model_bitbucket_http_credentials_spec_dto.go b/harness/nextgen/model_bitbucket_http_credentials_spec_dto.go deleted file mode 100644 index d92900ad..00000000 --- a/harness/nextgen/model_bitbucket_http_credentials_spec_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BitbucketHttpCredentialsSpecDto struct { -} diff --git a/harness/nextgen/model_bitbucket_server_webhook_events.go b/harness/nextgen/model_bitbucket_server_webhook_events.go deleted file mode 100644 index 30719d2d..00000000 --- a/harness/nextgen/model_bitbucket_server_webhook_events.go +++ /dev/null @@ -1,25 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BitbucketServerWebhookEvents struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - ParserForType *ParserBitbucketServerWebhookEvents `json:"parserForType,omitempty"` - DefaultInstanceForType *BitbucketServerWebhookEvents `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - EventsList []string `json:"eventsList,omitempty"` - EventsCount int32 `json:"eventsCount,omitempty"` - EventsValueList []int32 `json:"eventsValueList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_bitbucket_server_webhook_events_or_builder.go b/harness/nextgen/model_bitbucket_server_webhook_events_or_builder.go deleted file mode 100644 index 084ef6fd..00000000 --- a/harness/nextgen/model_bitbucket_server_webhook_events_or_builder.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BitbucketServerWebhookEventsOrBuilder struct { - EventsList []string `json:"eventsList,omitempty"` - EventsCount int32 `json:"eventsCount,omitempty"` - EventsValueList []int32 `json:"eventsValueList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_github_ssh_credentials_dto.go b/harness/nextgen/model_bitbucket_ssh_credentials.go similarity index 77% rename from harness/nextgen/model_github_ssh_credentials_dto.go rename to harness/nextgen/model_bitbucket_ssh_credentials.go index ca8751b3..5c62a9fe 100644 --- a/harness/nextgen/model_github_ssh_credentials_dto.go +++ b/harness/nextgen/model_bitbucket_ssh_credentials.go @@ -9,6 +9,7 @@ */ package nextgen -type GithubSshCredentialsDto struct { +// This contains details of the Bitbucket credentials used via SSH connections +type BitbucketSshCredentials struct { SshKeyRef string `json:"sshKeyRef"` } diff --git a/harness/nextgen/model_bitbucket_username_password.go b/harness/nextgen/model_bitbucket_username_password.go new file mode 100644 index 00000000..eb47d465 --- /dev/null +++ b/harness/nextgen/model_bitbucket_username_password.go @@ -0,0 +1,17 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the Bitbucket credentials Specs such as references of username and password +type BitbucketUsernamePassword struct { + Username string `json:"username,omitempty"` + UsernameRef string `json:"usernameRef,omitempty"` + PasswordRef string `json:"passwordRef"` +} diff --git a/harness/nextgen/model_bitbucket_username_token_api_access_dto.go b/harness/nextgen/model_bitbucket_username_token_api_access.go similarity index 75% rename from harness/nextgen/model_bitbucket_username_token_api_access_dto.go rename to harness/nextgen/model_bitbucket_username_token_api_access.go index 65f115cc..6979f918 100644 --- a/harness/nextgen/model_bitbucket_username_token_api_access_dto.go +++ b/harness/nextgen/model_bitbucket_username_token_api_access.go @@ -9,7 +9,8 @@ */ package nextgen -type BitbucketUsernameTokenApiAccessDto struct { +// This contains details of the Bitbucket API access credentials Specs such as references of username and token +type BitbucketUsernameTokenApiAccess struct { Username string `json:"username,omitempty"` UsernameRef string `json:"usernameRef,omitempty"` TokenRef string `json:"tokenRef"` diff --git a/harness/nextgen/model_build_id_and_instance_count.go b/harness/nextgen/model_build_id_and_instance_count.go deleted file mode 100644 index e54e0d09..00000000 --- a/harness/nextgen/model_build_id_and_instance_count.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type BuildIdAndInstanceCount struct { - BuildId string `json:"buildId,omitempty"` - Count int32 `json:"count,omitempty"` -} diff --git a/harness/nextgen/model_byte_string.go b/harness/nextgen/model_byte_string.go deleted file mode 100644 index 09fb6d54..00000000 --- a/harness/nextgen/model_byte_string.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ByteString struct { - ValidUtf8 bool `json:"validUtf8,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_cd_license_summary.go b/harness/nextgen/model_cd_license_summary.go new file mode 100644 index 00000000..001b5fd9 --- /dev/null +++ b/harness/nextgen/model_cd_license_summary.go @@ -0,0 +1,20 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the Continuous Delivery License Summary in Harness +type CdLicenseSummary struct { + Edition string `json:"edition,omitempty"` + LicenseType string `json:"licenseType,omitempty"` + ModuleType string `json:"moduleType,omitempty"` + MaxExpiryTime int64 `json:"maxExpiryTime,omitempty"` + TotalWorkload int32 `json:"totalWorkload,omitempty"` + TotalServiceInstances int32 `json:"totalServiceInstances,omitempty"` +} diff --git a/harness/nextgen/model_cd_module_license.go b/harness/nextgen/model_cd_module_license.go new file mode 100644 index 00000000..da51899c --- /dev/null +++ b/harness/nextgen/model_cd_module_license.go @@ -0,0 +1,27 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the Continuous Delivery License in Harness +type CdModuleLicense struct { + Id string `json:"id,omitempty"` + AccountIdentifier string `json:"accountIdentifier,omitempty"` + ModuleType string `json:"moduleType,omitempty"` + Edition string `json:"edition,omitempty"` + LicenseType string `json:"licenseType,omitempty"` + Status string `json:"status,omitempty"` + StartTime int64 `json:"startTime,omitempty"` + ExpiryTime int64 `json:"expiryTime,omitempty"` + CreatedAt int64 `json:"createdAt,omitempty"` + LastModifiedAt int64 `json:"lastModifiedAt,omitempty"` + CdLicenseType string `json:"cdLicenseType,omitempty"` + Workloads int32 `json:"workloads,omitempty"` + ServiceInstances int32 `json:"serviceInstances,omitempty"` +} diff --git a/harness/nextgen/model_cd_pipeline_module_info.go b/harness/nextgen/model_cd_pipeline_module_info.go deleted file mode 100644 index 58d97e3c..00000000 --- a/harness/nextgen/model_cd_pipeline_module_info.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type CdPipelineModuleInfo struct { - ServiceIdentifiers []string `json:"serviceIdentifiers,omitempty"` - EnvIdentifiers []string `json:"envIdentifiers,omitempty"` - ServiceDefinitionTypes []string `json:"serviceDefinitionTypes,omitempty"` - EnvironmentTypes []string `json:"environmentTypes,omitempty"` - InfrastructureTypes []string `json:"infrastructureTypes,omitempty"` -} diff --git a/harness/nextgen/model_cd_stage_module_info.go b/harness/nextgen/model_cd_stage_module_info.go deleted file mode 100644 index daec7402..00000000 --- a/harness/nextgen/model_cd_stage_module_info.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type CdStageModuleInfo struct { - ServiceInfo *ServiceExecutionSummary `json:"serviceInfo,omitempty"` - InfraExecutionSummary *InfraExecutionSummary `json:"infraExecutionSummary,omitempty"` - NodeExecutionId string `json:"nodeExecutionId,omitempty"` -} diff --git a/harness/nextgen/model_ce_aws_connector_dto.go b/harness/nextgen/model_ce_aws_connector_dto.go index 4de93f96..11909ef5 100644 --- a/harness/nextgen/model_ce_aws_connector_dto.go +++ b/harness/nextgen/model_ce_aws_connector_dto.go @@ -10,8 +10,8 @@ package nextgen type CeAwsConnectorDto struct { - CrossAccountAccess *CrossAccountAccessDto `json:"crossAccountAccess"` - CurAttributes *AwsCurAttributesDto `json:"curAttributes,omitempty"` - AwsAccountId string `json:"awsAccountId,omitempty"` - FeaturesEnabled []string `json:"featuresEnabled,omitempty"` + CrossAccountAccess *CrossAccountAccess `json:"crossAccountAccess"` + CurAttributes *AwsCurAttributesDto `json:"curAttributes,omitempty"` + AwsAccountId string `json:"awsAccountId,omitempty"` + FeaturesEnabled []string `json:"featuresEnabled,omitempty"` } diff --git a/harness/nextgen/model_ce_license_summary_dto.go b/harness/nextgen/model_ce_license_summary.go similarity index 84% rename from harness/nextgen/model_ce_license_summary_dto.go rename to harness/nextgen/model_ce_license_summary.go index 0059abf9..54cb6499 100644 --- a/harness/nextgen/model_ce_license_summary_dto.go +++ b/harness/nextgen/model_ce_license_summary.go @@ -9,7 +9,8 @@ */ package nextgen -type CeLicenseSummaryDto struct { +// This contains details of the Cloud Cost Management License Summary in Harness +type CeLicenseSummary struct { Edition string `json:"edition,omitempty"` LicenseType string `json:"licenseType,omitempty"` ModuleType string `json:"moduleType,omitempty"` diff --git a/harness/nextgen/model_ce_module_license_dto.go b/harness/nextgen/model_ce_module_license.go similarity index 90% rename from harness/nextgen/model_ce_module_license_dto.go rename to harness/nextgen/model_ce_module_license.go index 9c000481..d61db4e8 100644 --- a/harness/nextgen/model_ce_module_license_dto.go +++ b/harness/nextgen/model_ce_module_license.go @@ -9,7 +9,8 @@ */ package nextgen -type CeModuleLicenseDto struct { +// This contains details of the Cloud Cost Management License in Harness +type CeModuleLicense struct { Id string `json:"id,omitempty"` AccountIdentifier string `json:"accountIdentifier,omitempty"` ModuleType string `json:"moduleType,omitempty"` diff --git a/harness/nextgen/model_cf_license_summary_dto.go b/harness/nextgen/model_cf_license_summary.go similarity index 87% rename from harness/nextgen/model_cf_license_summary_dto.go rename to harness/nextgen/model_cf_license_summary.go index b5edbcd3..539517b8 100644 --- a/harness/nextgen/model_cf_license_summary_dto.go +++ b/harness/nextgen/model_cf_license_summary.go @@ -9,7 +9,8 @@ */ package nextgen -type CfLicenseSummaryDto struct { +// This contains details of the Feature Flags License Summary in Harness +type CfLicenseSummary struct { Edition string `json:"edition,omitempty"` LicenseType string `json:"licenseType,omitempty"` ModuleType string `json:"moduleType,omitempty"` diff --git a/harness/nextgen/model_cf_module_license_dto.go b/harness/nextgen/model_cf_module_license.go similarity index 91% rename from harness/nextgen/model_cf_module_license_dto.go rename to harness/nextgen/model_cf_module_license.go index 678af002..9d20dee4 100644 --- a/harness/nextgen/model_cf_module_license_dto.go +++ b/harness/nextgen/model_cf_module_license.go @@ -9,7 +9,8 @@ */ package nextgen -type CfModuleLicenseDto struct { +// This contains details of the Feature Flags License in Harness +type CfModuleLicense struct { Id string `json:"id,omitempty"` AccountIdentifier string `json:"accountIdentifier,omitempty"` ModuleType string `json:"moduleType,omitempty"` diff --git a/harness/nextgen/model_check_expiry_result_dto.go b/harness/nextgen/model_check_expiry_result_dto.go deleted file mode 100644 index e3afbf42..00000000 --- a/harness/nextgen/model_check_expiry_result_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type CheckExpiryResultDto struct { - ShouldDelete bool `json:"shouldDelete,omitempty"` - ExpiryTime int64 `json:"expiryTime,omitempty"` -} diff --git a/harness/nextgen/model_ci_license_summary_dto.go b/harness/nextgen/model_ci_license_summary.go similarity index 84% rename from harness/nextgen/model_ci_license_summary_dto.go rename to harness/nextgen/model_ci_license_summary.go index aafcd468..20a54da9 100644 --- a/harness/nextgen/model_ci_license_summary_dto.go +++ b/harness/nextgen/model_ci_license_summary.go @@ -9,7 +9,8 @@ */ package nextgen -type CiLicenseSummaryDto struct { +// This contains details of the Continuous Integration License Summary in Harness +type CiLicenseSummary struct { Edition string `json:"edition,omitempty"` LicenseType string `json:"licenseType,omitempty"` ModuleType string `json:"moduleType,omitempty"` diff --git a/harness/nextgen/model_ci_module_license_dto.go b/harness/nextgen/model_ci_module_license.go similarity index 90% rename from harness/nextgen/model_ci_module_license_dto.go rename to harness/nextgen/model_ci_module_license.go index e9483e8f..1dffcfab 100644 --- a/harness/nextgen/model_ci_module_license_dto.go +++ b/harness/nextgen/model_ci_module_license.go @@ -9,7 +9,8 @@ */ package nextgen -type CiModuleLicenseDto struct { +// This contains details of the Continuous Integration License in Harness +type CiModuleLicense struct { Id string `json:"id,omitempty"` AccountIdentifier string `json:"accountIdentifier,omitempty"` ModuleType string `json:"moduleType,omitempty"` diff --git a/harness/nextgen/model_connected_argo_git_ops_info_dto.go b/harness/nextgen/model_connected_argo_git_ops_info_dto.go deleted file mode 100644 index 78041168..00000000 --- a/harness/nextgen/model_connected_argo_git_ops_info_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ConnectedArgoGitOpsInfoDto struct { - Type_ string `json:"type,omitempty"` - AdapterUrl string `json:"adapterUrl"` -} diff --git a/harness/nextgen/model_connectivity_check_summary_dto.go b/harness/nextgen/model_connectivity_check_summary_dto.go deleted file mode 100644 index 0b9dc149..00000000 --- a/harness/nextgen/model_connectivity_check_summary_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ConnectivityCheckSummaryDto struct { - SuccessCount int64 `json:"successCount,omitempty"` - FailureCount int64 `json:"failureCount,omitempty"` - StartTime int64 `json:"startTime,omitempty"` - EndTime int64 `json:"endTime,omitempty"` -} diff --git a/harness/nextgen/model_connector.go b/harness/nextgen/model_connector.go index 71fb2c38..fcd64b04 100644 --- a/harness/nextgen/model_connector.go +++ b/harness/nextgen/model_connector.go @@ -11,5 +11,5 @@ package nextgen // This is the view of Connector entity as defined in Harness. type Connector struct { - Connector *ConnectorInfoDto `json:"connector,omitempty"` + Connector *ConnectorInfo `json:"connector,omitempty"` } diff --git a/harness/nextgen/model_connector_config.go b/harness/nextgen/model_connector_config.go new file mode 100644 index 00000000..1cbec42a --- /dev/null +++ b/harness/nextgen/model_connector_config.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This is the view of the ConnectorConfig entity defined in Harness +type ConnectorConfig struct { +} diff --git a/harness/nextgen/model_connector_config_dto.go b/harness/nextgen/model_connector_config_dto.go deleted file mode 100644 index a6799ee3..00000000 --- a/harness/nextgen/model_connector_config_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ConnectorConfigDto struct { -} diff --git a/harness/nextgen/model_connector_info.go b/harness/nextgen/model_connector_info.go new file mode 100644 index 00000000..b455713d --- /dev/null +++ b/harness/nextgen/model_connector_info.go @@ -0,0 +1,48 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import ( + "encoding/json" +) + +type ConnectorInfo struct { + Name string `json:"name"` + Identifier string `json:"identifier"` + Description string `json:"description,omitempty"` + OrgIdentifier string `json:"orgIdentifier,omitempty"` + ProjectIdentifier string `json:"projectIdentifier,omitempty"` + Tags map[string]string `json:"tags,omitempty"` + Type_ ConnectorType `json:"type"` + AppDynamics *AppDynamicsConnectorDto `json:"-"` + Artifactory *ArtifactoryConnector `json:"-"` + Aws *AwsConnector `json:"-"` + AwsCC *CeAwsConnectorDto `json:"-"` + AwsKms *AwsKmsConnectorDto `json:"-"` + AwsSecretManager *AwsSecretManagerDto `json:"-"` + BitBucket *BitbucketConnector `json:"-"` + Datadog *DatadogConnectorDto `json:"-"` + DockerRegistry *DockerConnector `json:"-"` + Dynatrace *DynatraceConnectorDto `json:"-"` + Gcp *GcpConnector `json:"-"` + Git *GitConfig `json:"-"` + Github *GithubConnector `json:"-"` + Gitlab *GitlabConnector `json:"-"` + HttpHelm *HttpHelmConnector `json:"-"` + Jira *JiraConnector `json:"-"` + K8sCluster *KubernetesClusterConfig `json:"-"` + NewRelic *NewRelicConnectorDto `json:"-"` + Nexus *NexusConnector `json:"-"` + PagerDuty *PagerDutyConnectorDto `json:"-"` + Prometheus *PrometheusConnectorDto `json:"-"` + Splunk *SplunkConnectorDto `json:"-"` + SumoLogic *SumoLogicConnectorDto `json:"-"` + Spec json.RawMessage `json:"spec"` +} diff --git a/harness/nextgen/model_connector_info_dto.go b/harness/nextgen/model_connector_info_dto.go deleted file mode 100644 index 410c5d09..00000000 --- a/harness/nextgen/model_connector_info_dto.go +++ /dev/null @@ -1,34 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -import ( - "encoding/json" -) - -type ConnectorInfoDto struct { - Name string `json:"name"` - Identifier string `json:"identifier"` - Description string `json:"description,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Type_ string `json:"type"` - Artifactory *ArtifactoryConnectorDto `json:"-"` - AwsCC *CeAwsConnectorDto `json:"-"` - Aws *AwsConnectorDto `json:"-"` - DockerRegistry *DockerConnectorDto `json:"-"` - Gcp *GcpConnectorDto `json:"-"` - Git *GitConfigDto `json:"-"` - HttpHelm *HttpHelmConnectorDto `json:"-"` - K8sCluster *KubernetesClusterConfigDto `json:"-"` - Nexus *NexusConnectorDto `json:"-"` - Spec json.RawMessage `json:"spec"` -} diff --git a/harness/nextgen/model_connector_info_serializer.go b/harness/nextgen/model_connector_info_serializer.go index 15a7ccc2..82b5a770 100644 --- a/harness/nextgen/model_connector_info_serializer.go +++ b/harness/nextgen/model_connector_info_serializer.go @@ -5,9 +5,9 @@ import ( "fmt" ) -func (a *ConnectorInfoDto) UnmarshalJSON(data []byte) error { +func (a *ConnectorInfo) UnmarshalJSON(data []byte) error { - type Alias ConnectorInfoDto + type Alias ConnectorInfo aux := &struct { *Alias @@ -21,24 +21,52 @@ func (a *ConnectorInfoDto) UnmarshalJSON(data []byte) error { } switch a.Type_ { - case ConnectorTypes.Artifactory.String(): + case ConnectorTypes.AppDynamics: + err = json.Unmarshal(aux.Spec, &a.AppDynamics) + case ConnectorTypes.Artifactory: err = json.Unmarshal(aux.Spec, &a.Artifactory) - case ConnectorTypes.Aws.String(): + case ConnectorTypes.Aws: err = json.Unmarshal(aux.Spec, &a.Aws) - case ConnectorTypes.CEAws.String(): + case ConnectorTypes.AwsKms: + err = json.Unmarshal(aux.Spec, &a.AwsKms) + case ConnectorTypes.AwsSecretManager: + err = json.Unmarshal(aux.Spec, &a.AwsSecretManager) + case ConnectorTypes.CEAws: err = json.Unmarshal(aux.Spec, &a.AwsCC) - case ConnectorTypes.DockerRegistry.String(): + case ConnectorTypes.Bitbucket: + err = json.Unmarshal(aux.Spec, &a.BitBucket) + case ConnectorTypes.Datadog: + err = json.Unmarshal(aux.Spec, &a.Datadog) + case ConnectorTypes.DockerRegistry: err = json.Unmarshal(aux.Spec, &a.DockerRegistry) - case ConnectorTypes.Gcp.String(): + case ConnectorTypes.Dynatrace: + err = json.Unmarshal(aux.Spec, &a.Dynatrace) + case ConnectorTypes.Gcp: err = json.Unmarshal(aux.Spec, &a.Gcp) - case ConnectorTypes.Git.String(): + case ConnectorTypes.Git: err = json.Unmarshal(aux.Spec, &a.Git) - case ConnectorTypes.HttpHelmRepo.String(): + case ConnectorTypes.Github: + err = json.Unmarshal(aux.Spec, &a.Github) + case ConnectorTypes.Gitlab: + err = json.Unmarshal(aux.Spec, &a.Gitlab) + case ConnectorTypes.HttpHelmRepo: err = json.Unmarshal(aux.Spec, &a.HttpHelm) - case ConnectorTypes.K8sCluster.String(): + case ConnectorTypes.Jira: + err = json.Unmarshal(aux.Spec, &a.Jira) + case ConnectorTypes.K8sCluster: err = json.Unmarshal(aux.Spec, &a.K8sCluster) - case ConnectorTypes.Nexus.String(): + case ConnectorTypes.Nexus: err = json.Unmarshal(aux.Spec, &a.Nexus) + case ConnectorTypes.NewRelic: + err = json.Unmarshal(aux.Spec, &a.NewRelic) + case ConnectorTypes.PagerDuty: + err = json.Unmarshal(aux.Spec, &a.PagerDuty) + case ConnectorTypes.Prometheus: + err = json.Unmarshal(aux.Spec, &a.Prometheus) + case ConnectorTypes.Splunk: + err = json.Unmarshal(aux.Spec, &a.Splunk) + case ConnectorTypes.SumoLogic: + err = json.Unmarshal(aux.Spec, &a.SumoLogic) default: panic(fmt.Sprintf("unknown connector type %s", a.Type_)) } @@ -46,31 +74,59 @@ func (a *ConnectorInfoDto) UnmarshalJSON(data []byte) error { return err } -func (a *ConnectorInfoDto) MarshalJSON() ([]byte, error) { - type Alias ConnectorInfoDto +func (a *ConnectorInfo) MarshalJSON() ([]byte, error) { + type Alias ConnectorInfo var spec []byte var err error switch a.Type_ { - case ConnectorTypes.Artifactory.String(): + case ConnectorTypes.AppDynamics: + spec, err = json.Marshal(a.AppDynamics) + case ConnectorTypes.Artifactory: spec, err = json.Marshal(a.Artifactory) - case ConnectorTypes.Aws.String(): + case ConnectorTypes.Aws: spec, err = json.Marshal(a.Aws) - case ConnectorTypes.CEAws.String(): + case ConnectorTypes.AwsKms: + spec, err = json.Marshal(a.AwsKms) + case ConnectorTypes.AwsSecretManager: + spec, err = json.Marshal(a.AwsSecretManager) + case ConnectorTypes.CEAws: spec, err = json.Marshal(a.AwsCC) - case ConnectorTypes.DockerRegistry.String(): + case ConnectorTypes.Bitbucket: + spec, err = json.Marshal(a.BitBucket) + case ConnectorTypes.Datadog: + spec, err = json.Marshal(a.Datadog) + case ConnectorTypes.DockerRegistry: spec, err = json.Marshal(a.DockerRegistry) - case ConnectorTypes.Gcp.String(): + case ConnectorTypes.Dynatrace: + spec, err = json.Marshal(a.Dynatrace) + case ConnectorTypes.Gcp: spec, err = json.Marshal(a.Gcp) - case ConnectorTypes.Git.String(): + case ConnectorTypes.Git: spec, err = json.Marshal(a.Git) - case ConnectorTypes.HttpHelmRepo.String(): + case ConnectorTypes.Github: + spec, err = json.Marshal(a.Github) + case ConnectorTypes.Gitlab: + spec, err = json.Marshal(a.Gitlab) + case ConnectorTypes.HttpHelmRepo: spec, err = json.Marshal(a.HttpHelm) - case ConnectorTypes.K8sCluster.String(): + case ConnectorTypes.Jira: + spec, err = json.Marshal(a.Jira) + case ConnectorTypes.K8sCluster: spec, err = json.Marshal(a.K8sCluster) - case ConnectorTypes.Nexus.String(): + case ConnectorTypes.NewRelic: + spec, err = json.Marshal(a.NewRelic) + case ConnectorTypes.Nexus: spec, err = json.Marshal(a.Nexus) + case ConnectorTypes.PagerDuty: + spec, err = json.Marshal(a.PagerDuty) + case ConnectorTypes.Prometheus: + spec, err = json.Marshal(a.Prometheus) + case ConnectorTypes.Splunk: + spec, err = json.Marshal(a.Splunk) + case ConnectorTypes.SumoLogic: + spec, err = json.Marshal(a.SumoLogic) default: panic(fmt.Sprintf("unknown connector type %s", a.Type_)) } diff --git a/harness/nextgen/model_connector_response.go b/harness/nextgen/model_connector_response.go index 672ca9c1..b566d2d8 100644 --- a/harness/nextgen/model_connector_response.go +++ b/harness/nextgen/model_connector_response.go @@ -11,7 +11,7 @@ package nextgen // Connetor Resource along with metadata type ConnectorResponse struct { - Connector *ConnectorInfoDto `json:"connector,omitempty"` + Connector *ConnectorInfo `json:"connector,omitempty"` CreatedAt int64 `json:"createdAt,omitempty"` LastModifiedAt int64 `json:"lastModifiedAt,omitempty"` Status *ConnectorConnectivityDetails `json:"status,omitempty"` diff --git a/harness/nextgen/model_create_invite_dto.go b/harness/nextgen/model_create_invite.go similarity index 86% rename from harness/nextgen/model_create_invite_dto.go rename to harness/nextgen/model_create_invite.go index 7d4dfdb1..ecbc668d 100644 --- a/harness/nextgen/model_create_invite_dto.go +++ b/harness/nextgen/model_create_invite.go @@ -9,7 +9,8 @@ */ package nextgen -type CreateInviteDto struct { +// This is the view of the CreateInvite entity defined in Harness +type CreateInvite struct { Users []string `json:"users,omitempty"` RoleBindings []RoleBinding `json:"roleBindings,omitempty"` InviteType string `json:"inviteType,omitempty"` diff --git a/harness/nextgen/model_create_prdto.go b/harness/nextgen/model_create_pr.go similarity index 89% rename from harness/nextgen/model_create_prdto.go rename to harness/nextgen/model_create_pr.go index aaeabd1d..b8330034 100644 --- a/harness/nextgen/model_create_prdto.go +++ b/harness/nextgen/model_create_pr.go @@ -9,6 +9,7 @@ */ package nextgen -type CreatePrdto struct { +// This contains PR Id +type CreatePr struct { PrNumber int32 `json:"prNumber,omitempty"` } diff --git a/harness/nextgen/model_cross_account_access_dto.go b/harness/nextgen/model_cross_account_access.go similarity index 83% rename from harness/nextgen/model_cross_account_access_dto.go rename to harness/nextgen/model_cross_account_access.go index 7ea2cc9c..8dff2d2d 100644 --- a/harness/nextgen/model_cross_account_access_dto.go +++ b/harness/nextgen/model_cross_account_access.go @@ -9,7 +9,8 @@ */ package nextgen -type CrossAccountAccessDto struct { +// This contains AWS connector cross account access details +type CrossAccountAccess struct { CrossAccountRoleArn string `json:"crossAccountRoleArn"` ExternalId string `json:"externalId,omitempty"` } diff --git a/harness/nextgen/model_custom_health_connector_dto.go b/harness/nextgen/model_custom_health_connector_dto.go new file mode 100644 index 00000000..291e2a7f --- /dev/null +++ b/harness/nextgen/model_custom_health_connector_dto.go @@ -0,0 +1,20 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +type CustomHealthConnectorDto struct { + BaseURL string `json:"baseURL"` + Headers []CustomHealthKeyAndValue `json:"headers,omitempty"` + Params []CustomHealthKeyAndValue `json:"params,omitempty"` + Method string `json:"method"` + ValidationBody string `json:"validationBody,omitempty"` + ValidationPath string `json:"validationPath,omitempty"` + DelegateSelectors []string `json:"delegateSelectors,omitempty"` +} diff --git a/harness/nextgen/model_custom_health_key_and_value.go b/harness/nextgen/model_custom_health_key_and_value.go new file mode 100644 index 00000000..412766ea --- /dev/null +++ b/harness/nextgen/model_custom_health_key_and_value.go @@ -0,0 +1,18 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +type CustomHealthKeyAndValue struct { + Key string `json:"key"` + IsValueEncrypted bool `json:"isValueEncrypted"` + EncryptedValueRef string `json:"encryptedValueRef,omitempty"` + Value string `json:"value,omitempty"` + ValueEncrypted bool `json:"valueEncrypted,omitempty"` +} diff --git a/harness/nextgen/model_custom_restriction.go b/harness/nextgen/model_custom_restriction.go new file mode 100644 index 00000000..9f8d2492 --- /dev/null +++ b/harness/nextgen/model_custom_restriction.go @@ -0,0 +1,15 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the Custom Restriction in Harness +type CustomRestriction struct { + RestrictionType string `json:"restrictionType"` +} diff --git a/harness/nextgen/model_custom_restriction_dto.go b/harness/nextgen/model_custom_restriction_dto.go deleted file mode 100644 index 76f02393..00000000 --- a/harness/nextgen/model_custom_restriction_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type CustomRestrictionDto struct { -} diff --git a/harness/nextgen/model_custom_restriction_evaluation_dto.go b/harness/nextgen/model_custom_restriction_evaluation_dto.go deleted file mode 100644 index 95d252b9..00000000 --- a/harness/nextgen/model_custom_restriction_evaluation_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type CustomRestrictionEvaluationDto struct { - AccountIdentifier string `json:"accountIdentifier,omitempty"` - FeatureRestrictionName string `json:"featureRestrictionName,omitempty"` - ModuleType string `json:"moduleType,omitempty"` - Edition string `json:"edition,omitempty"` -} diff --git a/harness/nextgen/model_restriction_metadata_dto.go b/harness/nextgen/model_custom_restriction_metadata.go similarity index 80% rename from harness/nextgen/model_restriction_metadata_dto.go rename to harness/nextgen/model_custom_restriction_metadata.go index 02da07d3..b6d48278 100644 --- a/harness/nextgen/model_restriction_metadata_dto.go +++ b/harness/nextgen/model_custom_restriction_metadata.go @@ -9,6 +9,7 @@ */ package nextgen -type RestrictionMetadataDto struct { +// This contains metadata of the Custom Restriction in Harness +type CustomRestrictionMetadata struct { RestrictionType string `json:"restrictionType,omitempty"` } diff --git a/harness/nextgen/model_cv_license_summary_dto.go b/harness/nextgen/model_cv_license_summary.go similarity index 83% rename from harness/nextgen/model_cv_license_summary_dto.go rename to harness/nextgen/model_cv_license_summary.go index a501e2e6..ba3e742e 100644 --- a/harness/nextgen/model_cv_license_summary_dto.go +++ b/harness/nextgen/model_cv_license_summary.go @@ -9,7 +9,8 @@ */ package nextgen -type CvLicenseSummaryDto struct { +// This contains details of the Test Intelligence License Summary in Harness +type CvLicenseSummary struct { Edition string `json:"edition,omitempty"` LicenseType string `json:"licenseType,omitempty"` ModuleType string `json:"moduleType,omitempty"` diff --git a/harness/nextgen/model_cv_module_license_dto.go b/harness/nextgen/model_cv_module_license.go similarity index 90% rename from harness/nextgen/model_cv_module_license_dto.go rename to harness/nextgen/model_cv_module_license.go index 7e49be84..cad08ae4 100644 --- a/harness/nextgen/model_cv_module_license_dto.go +++ b/harness/nextgen/model_cv_module_license.go @@ -9,7 +9,8 @@ */ package nextgen -type CvModuleLicenseDto struct { +// This contains details of the Test Intelligence License in Harness +type CvModuleLicense struct { Id string `json:"id,omitempty"` AccountIdentifier string `json:"accountIdentifier,omitempty"` ModuleType string `json:"moduleType,omitempty"` diff --git a/harness/nextgen/model_dashboard_execution_status_info.go b/harness/nextgen/model_dashboard_execution_status_info.go deleted file mode 100644 index 0f0aa624..00000000 --- a/harness/nextgen/model_dashboard_execution_status_info.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DashboardExecutionStatusInfo struct { - Failure []ExecutionStatusInfo `json:"failure,omitempty"` - Pending []ExecutionStatusInfo `json:"pending,omitempty"` - Active []ExecutionStatusInfo `json:"active,omitempty"` -} diff --git a/harness/nextgen/model_dashboard_workload_deployment.go b/harness/nextgen/model_dashboard_workload_deployment.go deleted file mode 100644 index 29924b3b..00000000 --- a/harness/nextgen/model_dashboard_workload_deployment.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DashboardWorkloadDeployment struct { - WorkloadDeploymentInfoList []WorkloadDeploymentInfo `json:"workloadDeploymentInfoList,omitempty"` -} diff --git a/harness/nextgen/model_decryptable_entity.go b/harness/nextgen/model_decryptable_entity.go deleted file mode 100644 index 32b4d780..00000000 --- a/harness/nextgen/model_decryptable_entity.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DecryptableEntity struct { -} diff --git a/harness/nextgen/model_decryptable_entity_with_encryption_consumers.go b/harness/nextgen/model_decryptable_entity_with_encryption_consumers.go deleted file mode 100644 index c586f27f..00000000 --- a/harness/nextgen/model_decryptable_entity_with_encryption_consumers.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DecryptableEntityWithEncryptionConsumers struct { - EncryptedDataDetailList []EncryptedDataDetail `json:"encryptedDataDetailList,omitempty"` - DecryptableEntity *DecryptableEntity `json:"decryptableEntity,omitempty"` -} diff --git a/harness/nextgen/model_delegate_configuration.go b/harness/nextgen/model_delegate_configuration.go index 9dfe0617..6e059358 100644 --- a/harness/nextgen/model_delegate_configuration.go +++ b/harness/nextgen/model_delegate_configuration.go @@ -12,4 +12,5 @@ package nextgen type DelegateConfiguration struct { DelegateVersions []string `json:"delegateVersions,omitempty"` Action string `json:"action,omitempty"` + AccountVersion bool `json:"accountVersion,omitempty"` } diff --git a/harness/nextgen/model_delegate_response_data.go b/harness/nextgen/model_delegate_response_data.go deleted file mode 100644 index e8352913..00000000 --- a/harness/nextgen/model_delegate_response_data.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DelegateResponseData struct { - Class string `json:"@class"` -} diff --git a/harness/nextgen/model_deployment.go b/harness/nextgen/model_deployment.go deleted file mode 100644 index 2da925bf..00000000 --- a/harness/nextgen/model_deployment.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type Deployment struct { - Count int64 `json:"count,omitempty"` -} diff --git a/harness/nextgen/model_deployment_change_rates.go b/harness/nextgen/model_deployment_change_rates.go deleted file mode 100644 index abc6d770..00000000 --- a/harness/nextgen/model_deployment_change_rates.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DeploymentChangeRates struct { - FailureRate float64 `json:"failureRate,omitempty"` - FailureRateChangeRate float64 `json:"failureRateChangeRate,omitempty"` - Frequency float64 `json:"frequency,omitempty"` - FrequencyChangeRate float64 `json:"frequencyChangeRate,omitempty"` -} diff --git a/harness/nextgen/model_deployment_count.go b/harness/nextgen/model_deployment_count.go deleted file mode 100644 index 37496f69..00000000 --- a/harness/nextgen/model_deployment_count.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DeploymentCount struct { - Total int64 `json:"total,omitempty"` - Success int64 `json:"success,omitempty"` - Failure int64 `json:"failure,omitempty"` -} diff --git a/harness/nextgen/model_deployment_date_and_count.go b/harness/nextgen/model_deployment_date_and_count.go deleted file mode 100644 index ac8545a1..00000000 --- a/harness/nextgen/model_deployment_date_and_count.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DeploymentDateAndCount struct { - Time int64 `json:"time,omitempty"` - Deployments *Deployment `json:"deployments,omitempty"` -} diff --git a/harness/nextgen/model_deployment_stats_summary.go b/harness/nextgen/model_deployment_stats_summary.go deleted file mode 100644 index 8ec1cfb0..00000000 --- a/harness/nextgen/model_deployment_stats_summary.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DeploymentStatsSummary struct { - TotalCount int64 `json:"totalCount,omitempty"` - TotalCountChangeRate float64 `json:"totalCountChangeRate,omitempty"` - FailureRate float64 `json:"failureRate,omitempty"` - FailureRateChangeRate float64 `json:"failureRateChangeRate,omitempty"` - DeploymentRate float64 `json:"deploymentRate,omitempty"` - DeploymentRateChangeRate float64 `json:"deploymentRateChangeRate,omitempty"` - TimeBasedDeploymentInfoList []TimeBasedDeploymentInfo `json:"timeBasedDeploymentInfoList,omitempty"` -} diff --git a/harness/nextgen/model_deployments_info.go b/harness/nextgen/model_deployments_info.go deleted file mode 100644 index fe9004a8..00000000 --- a/harness/nextgen/model_deployments_info.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DeploymentsInfo struct { - Deployments []ExecutionStatusInfo `json:"deployments,omitempty"` -} diff --git a/harness/nextgen/model_descriptor.go b/harness/nextgen/model_descriptor.go deleted file mode 100644 index dd8cea05..00000000 --- a/harness/nextgen/model_descriptor.go +++ /dev/null @@ -1,26 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type Descriptor struct { - Index int32 `json:"index,omitempty"` - Proto *DescriptorProto `json:"proto,omitempty"` - FullName string `json:"fullName,omitempty"` - File *FileDescriptor `json:"file,omitempty"` - ContainingType *Descriptor `json:"containingType,omitempty"` - NestedTypes []Descriptor `json:"nestedTypes,omitempty"` - EnumTypes []EnumDescriptor `json:"enumTypes,omitempty"` - Fields []FieldDescriptor `json:"fields,omitempty"` - Extensions []FieldDescriptor `json:"extensions,omitempty"` - Oneofs []OneofDescriptor `json:"oneofs,omitempty"` - Options *MessageOptions `json:"options,omitempty"` - Extendable bool `json:"extendable,omitempty"` - Name string `json:"name,omitempty"` -} diff --git a/harness/nextgen/model_descriptor_proto.go b/harness/nextgen/model_descriptor_proto.go deleted file mode 100644 index c0f8e534..00000000 --- a/harness/nextgen/model_descriptor_proto.go +++ /dev/null @@ -1,49 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DescriptorProto struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Options *MessageOptions `json:"options,omitempty"` - ExtensionRangeList []ExtensionRange `json:"extensionRangeList,omitempty"` - ReservedRangeList []ReservedRange `json:"reservedRangeList,omitempty"` - ReservedNameList []string `json:"reservedNameList,omitempty"` - OneofDeclCount int32 `json:"oneofDeclCount,omitempty"` - NestedTypeCount int32 `json:"nestedTypeCount,omitempty"` - EnumTypeCount int32 `json:"enumTypeCount,omitempty"` - ExtensionCount int32 `json:"extensionCount,omitempty"` - ReservedRangeOrBuilderList []ReservedRangeOrBuilder `json:"reservedRangeOrBuilderList,omitempty"` - ReservedRangeCount int32 `json:"reservedRangeCount,omitempty"` - ReservedNameCount int32 `json:"reservedNameCount,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - ParserForType *ParserDescriptorProto `json:"parserForType,omitempty"` - DefaultInstanceForType *DescriptorProto `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - FieldCount int32 `json:"fieldCount,omitempty"` - EnumTypeList []EnumDescriptorProto `json:"enumTypeList,omitempty"` - EnumTypeOrBuilderList []EnumDescriptorProtoOrBuilder `json:"enumTypeOrBuilderList,omitempty"` - ExtensionList []FieldDescriptorProto `json:"extensionList,omitempty"` - FieldList []FieldDescriptorProto `json:"fieldList,omitempty"` - OneofDeclOrBuilderList []OneofDescriptorProtoOrBuilder `json:"oneofDeclOrBuilderList,omitempty"` - FieldOrBuilderList []FieldDescriptorProtoOrBuilder `json:"fieldOrBuilderList,omitempty"` - NestedTypeList []DescriptorProto `json:"nestedTypeList,omitempty"` - NestedTypeOrBuilderList []DescriptorProtoOrBuilder `json:"nestedTypeOrBuilderList,omitempty"` - ExtensionRangeOrBuilderList []ExtensionRangeOrBuilder `json:"extensionRangeOrBuilderList,omitempty"` - ExtensionRangeCount int32 `json:"extensionRangeCount,omitempty"` - OneofDeclList []OneofDescriptorProto `json:"oneofDeclList,omitempty"` - ExtensionOrBuilderList []FieldDescriptorProtoOrBuilder `json:"extensionOrBuilderList,omitempty"` - OptionsOrBuilder *MessageOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - Name string `json:"name,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_descriptor_proto_or_builder.go b/harness/nextgen/model_descriptor_proto_or_builder.go deleted file mode 100644 index be553dc1..00000000 --- a/harness/nextgen/model_descriptor_proto_or_builder.go +++ /dev/null @@ -1,44 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DescriptorProtoOrBuilder struct { - Options *MessageOptions `json:"options,omitempty"` - ExtensionRangeList []ExtensionRange `json:"extensionRangeList,omitempty"` - ReservedRangeList []ReservedRange `json:"reservedRangeList,omitempty"` - ReservedNameList []string `json:"reservedNameList,omitempty"` - OneofDeclCount int32 `json:"oneofDeclCount,omitempty"` - NestedTypeCount int32 `json:"nestedTypeCount,omitempty"` - EnumTypeCount int32 `json:"enumTypeCount,omitempty"` - ExtensionCount int32 `json:"extensionCount,omitempty"` - ReservedRangeOrBuilderList []ReservedRangeOrBuilder `json:"reservedRangeOrBuilderList,omitempty"` - ReservedRangeCount int32 `json:"reservedRangeCount,omitempty"` - ReservedNameCount int32 `json:"reservedNameCount,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - FieldCount int32 `json:"fieldCount,omitempty"` - EnumTypeList []EnumDescriptorProto `json:"enumTypeList,omitempty"` - EnumTypeOrBuilderList []EnumDescriptorProtoOrBuilder `json:"enumTypeOrBuilderList,omitempty"` - ExtensionList []FieldDescriptorProto `json:"extensionList,omitempty"` - FieldList []FieldDescriptorProto `json:"fieldList,omitempty"` - OneofDeclOrBuilderList []OneofDescriptorProtoOrBuilder `json:"oneofDeclOrBuilderList,omitempty"` - FieldOrBuilderList []FieldDescriptorProtoOrBuilder `json:"fieldOrBuilderList,omitempty"` - ExtensionRangeOrBuilderList []ExtensionRangeOrBuilder `json:"extensionRangeOrBuilderList,omitempty"` - ExtensionRangeCount int32 `json:"extensionRangeCount,omitempty"` - OneofDeclList []OneofDescriptorProto `json:"oneofDeclList,omitempty"` - ExtensionOrBuilderList []FieldDescriptorProtoOrBuilder `json:"extensionOrBuilderList,omitempty"` - OptionsOrBuilder *MessageOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - Name string `json:"name,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_docker_auth_credentials.go b/harness/nextgen/model_docker_auth_credentials.go new file mode 100644 index 00000000..ae185dc7 --- /dev/null +++ b/harness/nextgen/model_docker_auth_credentials.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of credentials for Docker Authentication +type DockerAuthCredentials struct { +} diff --git a/harness/nextgen/model_docker_auth_credentials_dto.go b/harness/nextgen/model_docker_auth_credentials_dto.go deleted file mode 100644 index e737a1a7..00000000 --- a/harness/nextgen/model_docker_auth_credentials_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DockerAuthCredentialsDto struct { -} diff --git a/harness/nextgen/model_ng_access_with_encryption_consumer.go b/harness/nextgen/model_docker_authentication.go similarity index 56% rename from harness/nextgen/model_ng_access_with_encryption_consumer.go rename to harness/nextgen/model_docker_authentication.go index 904013b5..8bbac6c4 100644 --- a/harness/nextgen/model_ng_access_with_encryption_consumer.go +++ b/harness/nextgen/model_docker_authentication.go @@ -9,7 +9,11 @@ */ package nextgen -type NgAccessWithEncryptionConsumer struct { - NgAccess *NgAccess `json:"ngAccess,omitempty"` - DecryptableEntity *DecryptableEntity `json:"decryptableEntity,omitempty"` +import "encoding/json" + +// This contains details of Docker Authentication +type DockerAuthentication struct { + Type_ DockerAuthType `json:"type"` + UsernamePassword *DockerUserNamePassword `json:"-"` + Spec json.RawMessage `json:"spec,omitempty"` } diff --git a/harness/nextgen/model_docker_authentication_serializer.go b/harness/nextgen/model_docker_authentication_serializer.go index f1e01029..56658005 100644 --- a/harness/nextgen/model_docker_authentication_serializer.go +++ b/harness/nextgen/model_docker_authentication_serializer.go @@ -5,9 +5,9 @@ import ( "fmt" ) -func (a *DockerAuthenticationDto) UnmarshalJSON(data []byte) error { +func (a *DockerAuthentication) UnmarshalJSON(data []byte) error { - type Alias DockerAuthenticationDto + type Alias DockerAuthentication aux := &struct { *Alias @@ -21,9 +21,9 @@ func (a *DockerAuthenticationDto) UnmarshalJSON(data []byte) error { } switch a.Type_ { - case DockerAuthTypes.UsernamePassword.String(): + case DockerAuthTypes.UsernamePassword: err = json.Unmarshal(aux.Spec, &a.UsernamePassword) - case DockerAuthTypes.Anonymous.String(): + case DockerAuthTypes.Anonymous: // nothing to do default: panic(fmt.Sprintf("unknown docker auth method type %s", a.Type_)) @@ -32,16 +32,16 @@ func (a *DockerAuthenticationDto) UnmarshalJSON(data []byte) error { return err } -func (a *DockerAuthenticationDto) MarshalJSON() ([]byte, error) { - type Alias DockerAuthenticationDto +func (a *DockerAuthentication) MarshalJSON() ([]byte, error) { + type Alias DockerAuthentication var spec []byte var err error switch a.Type_ { - case DockerAuthTypes.UsernamePassword.String(): + case DockerAuthTypes.UsernamePassword: spec, err = json.Marshal(a.UsernamePassword) - case DockerAuthTypes.Anonymous.String(): + case DockerAuthTypes.Anonymous: // nothing to do default: panic(fmt.Sprintf("unknown docker auth method type %s", a.Type_)) diff --git a/harness/nextgen/model_docker_build_details_dto.go b/harness/nextgen/model_docker_build_details_dto.go deleted file mode 100644 index 3723d111..00000000 --- a/harness/nextgen/model_docker_build_details_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DockerBuildDetailsDto struct { - Tag string `json:"tag,omitempty"` - BuildUrl string `json:"buildUrl,omitempty"` - Metadata map[string]string `json:"metadata,omitempty"` - Labels map[string]string `json:"labels,omitempty"` - ImagePath string `json:"imagePath,omitempty"` -} diff --git a/harness/nextgen/model_rest_response_verify_token_response_dto.go b/harness/nextgen/model_docker_connector.go similarity index 52% rename from harness/nextgen/model_rest_response_verify_token_response_dto.go rename to harness/nextgen/model_docker_connector.go index 9e73f3f2..e672530d 100644 --- a/harness/nextgen/model_rest_response_verify_token_response_dto.go +++ b/harness/nextgen/model_docker_connector.go @@ -9,8 +9,10 @@ */ package nextgen -type RestResponseVerifyTokenResponseDto struct { - MetaData map[string]interface{} `json:"metaData,omitempty"` - Resource *VerifyTokenResponseDto `json:"resource,omitempty"` - ResponseMessages []ResponseMessage `json:"responseMessages,omitempty"` +// This contains details of Docker Connector +type DockerConnector struct { + DockerRegistryUrl string `json:"dockerRegistryUrl"` + ProviderType string `json:"providerType"` + Auth *DockerAuthentication `json:"auth,omitempty"` + DelegateSelectors []string `json:"delegateSelectors,omitempty"` } diff --git a/harness/nextgen/model_docker_connector_dto.go b/harness/nextgen/model_docker_connector_dto.go deleted file mode 100644 index cbfa3940..00000000 --- a/harness/nextgen/model_docker_connector_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DockerConnectorDto struct { - DockerRegistryUrl string `json:"dockerRegistryUrl"` - ProviderType string `json:"providerType"` - Auth *DockerAuthenticationDto `json:"auth,omitempty"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` -} diff --git a/harness/nextgen/model_docker_request_dto.go b/harness/nextgen/model_docker_request_dto.go deleted file mode 100644 index f04d631c..00000000 --- a/harness/nextgen/model_docker_request_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DockerRequestDto struct { - Tag string `json:"tag,omitempty"` - TagRegex string `json:"tagRegex,omitempty"` - TagsList []string `json:"tagsList,omitempty"` -} diff --git a/harness/nextgen/model_docker_response_dto.go b/harness/nextgen/model_docker_response_dto.go deleted file mode 100644 index 9a067079..00000000 --- a/harness/nextgen/model_docker_response_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DockerResponseDto struct { - BuildDetailsList []DockerBuildDetailsDto `json:"buildDetailsList,omitempty"` -} diff --git a/harness/nextgen/model_bitbucket_username_password_dto.go b/harness/nextgen/model_docker_user_name_password.go similarity index 84% rename from harness/nextgen/model_bitbucket_username_password_dto.go rename to harness/nextgen/model_docker_user_name_password.go index 26f25252..51f5dbba 100644 --- a/harness/nextgen/model_bitbucket_username_password_dto.go +++ b/harness/nextgen/model_docker_user_name_password.go @@ -9,7 +9,8 @@ */ package nextgen -type BitbucketUsernamePasswordDto struct { +// This contains details of Docker Username and Password +type DockerUserNamePassword struct { Username string `json:"username,omitempty"` UsernameRef string `json:"usernameRef,omitempty"` PasswordRef string `json:"passwordRef"` diff --git a/harness/nextgen/model_active_service_instance_summary.go b/harness/nextgen/model_duration_restriction.go similarity index 63% rename from harness/nextgen/model_active_service_instance_summary.go rename to harness/nextgen/model_duration_restriction.go index 0caf3063..283f1cd9 100644 --- a/harness/nextgen/model_active_service_instance_summary.go +++ b/harness/nextgen/model_duration_restriction.go @@ -9,7 +9,8 @@ */ package nextgen -type ActiveServiceInstanceSummary struct { - ChangeRate float64 `json:"changeRate,omitempty"` - CountDetails *InstanceCountDetailsByEnvTypeBase `json:"countDetails,omitempty"` +// This contains details of the Duration Restriction in Harness +type DurationRestriction struct { + RestrictionType string `json:"restrictionType"` + TimeUnit *TimeUnit `json:"timeUnit,omitempty"` } diff --git a/harness/nextgen/model_duration_restriction_dto.go b/harness/nextgen/model_duration_restriction_dto.go deleted file mode 100644 index 585de0b0..00000000 --- a/harness/nextgen/model_duration_restriction_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type DurationRestrictionDto struct { - TimeUnit *TimeUnit `json:"timeUnit,omitempty"` -} diff --git a/harness/nextgen/model_duration_restriction_metadata_dto.go b/harness/nextgen/model_duration_restriction_metadata.go similarity index 81% rename from harness/nextgen/model_duration_restriction_metadata_dto.go rename to harness/nextgen/model_duration_restriction_metadata.go index 8d67ed7a..bacdf565 100644 --- a/harness/nextgen/model_duration_restriction_metadata_dto.go +++ b/harness/nextgen/model_duration_restriction_metadata.go @@ -9,7 +9,8 @@ */ package nextgen -type DurationRestrictionMetadataDto struct { +// This contains metadata of the Duration Restriction in Harness +type DurationRestrictionMetadata struct { RestrictionType string `json:"restrictionType,omitempty"` TimeUnit *TimeUnit `json:"timeUnit,omitempty"` } diff --git a/harness/nextgen/model_ecr_build_details_dto.go b/harness/nextgen/model_ecr_build_details_dto.go deleted file mode 100644 index 8112e508..00000000 --- a/harness/nextgen/model_ecr_build_details_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EcrBuildDetailsDto struct { - Tag string `json:"tag,omitempty"` - BuildUrl string `json:"buildUrl,omitempty"` - Metadata map[string]string `json:"metadata,omitempty"` - Labels map[string]string `json:"labels,omitempty"` - ImagePath string `json:"imagePath,omitempty"` -} diff --git a/harness/nextgen/model_ecr_list_images_dto.go b/harness/nextgen/model_ecr_list_images_dto.go deleted file mode 100644 index bf90968c..00000000 --- a/harness/nextgen/model_ecr_list_images_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EcrListImagesDto struct { - Images []string `json:"images,omitempty"` -} diff --git a/harness/nextgen/model_ecr_request_dto.go b/harness/nextgen/model_ecr_request_dto.go deleted file mode 100644 index d475d4af..00000000 --- a/harness/nextgen/model_ecr_request_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EcrRequestDto struct { - Tag string `json:"tag,omitempty"` - TagRegex string `json:"tagRegex,omitempty"` - TagsList []string `json:"tagsList,omitempty"` - Region string `json:"region,omitempty"` -} diff --git a/harness/nextgen/model_ecr_response_dto.go b/harness/nextgen/model_ecr_response_dto.go deleted file mode 100644 index 98d08328..00000000 --- a/harness/nextgen/model_ecr_response_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EcrResponseDto struct { - BuildDetailsList []EcrBuildDetailsDto `json:"buildDetailsList,omitempty"` -} diff --git a/harness/nextgen/model_edition_action_dto.go b/harness/nextgen/model_edition_action.go similarity index 82% rename from harness/nextgen/model_edition_action_dto.go rename to harness/nextgen/model_edition_action.go index fe850ee6..ef81a638 100644 --- a/harness/nextgen/model_edition_action_dto.go +++ b/harness/nextgen/model_edition_action.go @@ -9,7 +9,8 @@ */ package nextgen -type EditionActionDto struct { +// This contains allowed Actions and Reason under the Edition +type EditionAction struct { Action string `json:"action,omitempty"` Reason string `json:"reason,omitempty"` } diff --git a/harness/nextgen/model_email_config_dto.go b/harness/nextgen/model_email_config_dto.go deleted file mode 100644 index 151accad..00000000 --- a/harness/nextgen/model_email_config_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EmailConfigDto struct { - Type_ string `json:"type,omitempty"` - GroupEmail string `json:"groupEmail"` -} diff --git a/harness/nextgen/model_encrypted_data_detail.go b/harness/nextgen/model_encrypted_data_detail.go deleted file mode 100644 index 7d344ab3..00000000 --- a/harness/nextgen/model_encrypted_data_detail.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EncryptedDataDetail struct { - EncryptedData *EncryptedRecordData `json:"encryptedData,omitempty"` - EncryptionConfig *EncryptionConfig `json:"encryptionConfig,omitempty"` - FieldName string `json:"fieldName,omitempty"` - Identifier *SecretUniqueIdentifier `json:"identifier,omitempty"` -} diff --git a/harness/nextgen/model_encrypted_data_params.go b/harness/nextgen/model_encrypted_data_params.go deleted file mode 100644 index b59ffa58..00000000 --- a/harness/nextgen/model_encrypted_data_params.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EncryptedDataParams struct { - Name string `json:"name,omitempty"` - Value string `json:"value,omitempty"` -} diff --git a/harness/nextgen/model_encrypted_record_data.go b/harness/nextgen/model_encrypted_record_data.go deleted file mode 100644 index 7d1fe56a..00000000 --- a/harness/nextgen/model_encrypted_record_data.go +++ /dev/null @@ -1,27 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EncryptedRecordData struct { - Uuid string `json:"uuid,omitempty"` - Name string `json:"name,omitempty"` - Path string `json:"path,omitempty"` - Parameters []EncryptedDataParams `json:"parameters,omitempty"` - EncryptionKey string `json:"encryptionKey,omitempty"` - EncryptedValue []string `json:"encryptedValue,omitempty"` - KmsId string `json:"kmsId,omitempty"` - EncryptionType string `json:"encryptionType,omitempty"` - BackupEncryptedValue []string `json:"backupEncryptedValue,omitempty"` - BackupEncryptionKey string `json:"backupEncryptionKey,omitempty"` - BackupKmsId string `json:"backupKmsId,omitempty"` - BackupEncryptionType string `json:"backupEncryptionType,omitempty"` - Base64Encoded bool `json:"base64Encoded,omitempty"` - AdditionalMetadata *AdditionalMetadata `json:"additionalMetadata,omitempty"` -} diff --git a/harness/nextgen/model_encryption_config.go b/harness/nextgen/model_encryption_config.go deleted file mode 100644 index 4be1bd80..00000000 --- a/harness/nextgen/model_encryption_config.go +++ /dev/null @@ -1,23 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EncryptionConfig struct { - Default_ bool `json:"default,omitempty"` - EncryptionType string `json:"encryptionType,omitempty"` - AccountId string `json:"accountId,omitempty"` - NumOfEncryptedValue int32 `json:"numOfEncryptedValue,omitempty"` - EncryptionServiceUrl string `json:"encryptionServiceUrl,omitempty"` - ValidationCriteria string `json:"validationCriteria,omitempty"` - GlobalKms bool `json:"globalKms,omitempty"` - Uuid string `json:"uuid,omitempty"` - Name string `json:"name,omitempty"` - Type_ string `json:"type,omitempty"` -} diff --git a/harness/nextgen/model_entity_detail.go b/harness/nextgen/model_entity_detail.go deleted file mode 100644 index 57c1081d..00000000 --- a/harness/nextgen/model_entity_detail.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EntityDetail struct { - Type_ string `json:"type,omitempty"` - EntityRef *EntityReference `json:"entityRef,omitempty"` - Name string `json:"name,omitempty"` -} diff --git a/harness/nextgen/model_entity_references_dto.go b/harness/nextgen/model_entity_references_dto.go deleted file mode 100644 index 04ed5c1f..00000000 --- a/harness/nextgen/model_entity_references_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EntityReferencesDto struct { - EntitySetupUsageBatchList []EntitySetupUsageBatchDto `json:"entitySetupUsageBatchList,omitempty"` -} diff --git a/harness/nextgen/model_entity_referred_by_pipeline_setup_usage_detail.go b/harness/nextgen/model_entity_referred_by_pipeline_setup_usage_detail.go deleted file mode 100644 index ca65e733..00000000 --- a/harness/nextgen/model_entity_referred_by_pipeline_setup_usage_detail.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EntityReferredByPipelineSetupUsageDetail struct { - Type_ string `json:"type"` - Identifier string `json:"identifier,omitempty"` - ReferenceType string `json:"referenceType,omitempty"` -} diff --git a/harness/nextgen/model_entity_setup_usage_batch_dto.go b/harness/nextgen/model_entity_setup_usage_batch_dto.go deleted file mode 100644 index 613908cf..00000000 --- a/harness/nextgen/model_entity_setup_usage_batch_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EntitySetupUsageBatchDto struct { - ReferredByEntity string `json:"referredByEntity,omitempty"` - ReferredEntities []EntitySetupUsageDto `json:"referredEntities,omitempty"` -} diff --git a/harness/nextgen/model_entity_setup_usage_dto.go b/harness/nextgen/model_entity_setup_usage_dto.go deleted file mode 100644 index 229caafe..00000000 --- a/harness/nextgen/model_entity_setup_usage_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EntitySetupUsageDto struct { - AccountIdentifier string `json:"accountIdentifier,omitempty"` - ReferredEntity *EntityDetail `json:"referredEntity,omitempty"` - ReferredByEntity *EntityDetail `json:"referredByEntity"` - Detail *SetupUsageDetail `json:"detail,omitempty"` - CreatedAt int64 `json:"createdAt,omitempty"` -} diff --git a/harness/nextgen/model_enum_descriptor.go b/harness/nextgen/model_enum_descriptor.go deleted file mode 100644 index d5f0ddab..00000000 --- a/harness/nextgen/model_enum_descriptor.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumDescriptor struct { - Index int32 `json:"index,omitempty"` - Proto *EnumDescriptorProto `json:"proto,omitempty"` - FullName string `json:"fullName,omitempty"` - File *FileDescriptor `json:"file,omitempty"` - ContainingType *Descriptor `json:"containingType,omitempty"` - Values []EnumValueDescriptor `json:"values,omitempty"` - Options *EnumOptions `json:"options,omitempty"` - Name string `json:"name,omitempty"` -} diff --git a/harness/nextgen/model_enum_descriptor_proto.go b/harness/nextgen/model_enum_descriptor_proto.go deleted file mode 100644 index bbfec9ac..00000000 --- a/harness/nextgen/model_enum_descriptor_proto.go +++ /dev/null @@ -1,34 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumDescriptorProto struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Options *EnumOptions `json:"options,omitempty"` - ReservedRangeList []EnumReservedRange `json:"reservedRangeList,omitempty"` - ReservedNameList []string `json:"reservedNameList,omitempty"` - ReservedRangeOrBuilderList []EnumReservedRangeOrBuilder `json:"reservedRangeOrBuilderList,omitempty"` - ReservedRangeCount int32 `json:"reservedRangeCount,omitempty"` - ReservedNameCount int32 `json:"reservedNameCount,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - ParserForType *ParserEnumDescriptorProto `json:"parserForType,omitempty"` - DefaultInstanceForType *EnumDescriptorProto `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - ValueCount int32 `json:"valueCount,omitempty"` - ValueList []EnumValueDescriptorProto `json:"valueList,omitempty"` - ValueOrBuilderList []EnumValueDescriptorProtoOrBuilder `json:"valueOrBuilderList,omitempty"` - OptionsOrBuilder *EnumOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - Name string `json:"name,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_enum_descriptor_proto_or_builder.go b/harness/nextgen/model_enum_descriptor_proto_or_builder.go deleted file mode 100644 index ac5c6f46..00000000 --- a/harness/nextgen/model_enum_descriptor_proto_or_builder.go +++ /dev/null @@ -1,31 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumDescriptorProtoOrBuilder struct { - Options *EnumOptions `json:"options,omitempty"` - ReservedRangeList []EnumReservedRange `json:"reservedRangeList,omitempty"` - ReservedNameList []string `json:"reservedNameList,omitempty"` - ReservedRangeOrBuilderList []EnumReservedRangeOrBuilder `json:"reservedRangeOrBuilderList,omitempty"` - ReservedRangeCount int32 `json:"reservedRangeCount,omitempty"` - ReservedNameCount int32 `json:"reservedNameCount,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - ValueCount int32 `json:"valueCount,omitempty"` - ValueList []EnumValueDescriptorProto `json:"valueList,omitempty"` - ValueOrBuilderList []EnumValueDescriptorProtoOrBuilder `json:"valueOrBuilderList,omitempty"` - OptionsOrBuilder *EnumOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - Name string `json:"name,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_enum_options.go b/harness/nextgen/model_enum_options.go deleted file mode 100644 index bd96ca19..00000000 --- a/harness/nextgen/model_enum_options.go +++ /dev/null @@ -1,28 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumOptions struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - ParserForType *ParserEnumOptions `json:"parserForType,omitempty"` - DefaultInstanceForType *EnumOptions `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - AllowAlias bool `json:"allowAlias,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - AllFieldsRaw map[string]interface{} `json:"allFieldsRaw,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_enum_options_or_builder.go b/harness/nextgen/model_enum_options_or_builder.go deleted file mode 100644 index c8c92b32..00000000 --- a/harness/nextgen/model_enum_options_or_builder.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumOptionsOrBuilder struct { - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - AllowAlias bool `json:"allowAlias,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_enum_reserved_range.go b/harness/nextgen/model_enum_reserved_range.go deleted file mode 100644 index f0aef106..00000000 --- a/harness/nextgen/model_enum_reserved_range.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumReservedRange struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - End int32 `json:"end,omitempty"` - Start int32 `json:"start,omitempty"` - ParserForType *ParserEnumReservedRange `json:"parserForType,omitempty"` - DefaultInstanceForType *EnumReservedRange `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_enum_reserved_range_or_builder.go b/harness/nextgen/model_enum_reserved_range_or_builder.go deleted file mode 100644 index 7b031e72..00000000 --- a/harness/nextgen/model_enum_reserved_range_or_builder.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumReservedRangeOrBuilder struct { - End int32 `json:"end,omitempty"` - Start int32 `json:"start,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_enum_value_descriptor.go b/harness/nextgen/model_enum_value_descriptor.go deleted file mode 100644 index 80283471..00000000 --- a/harness/nextgen/model_enum_value_descriptor.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumValueDescriptor struct { - Index int32 `json:"index,omitempty"` - Proto *EnumValueDescriptorProto `json:"proto,omitempty"` - FullName string `json:"fullName,omitempty"` - File *FileDescriptor `json:"file,omitempty"` - Type_ *EnumDescriptor `json:"type,omitempty"` - Options *EnumValueOptions `json:"options,omitempty"` - Name string `json:"name,omitempty"` - Number int32 `json:"number,omitempty"` -} diff --git a/harness/nextgen/model_enum_value_descriptor_proto.go b/harness/nextgen/model_enum_value_descriptor_proto.go deleted file mode 100644 index 966d2136..00000000 --- a/harness/nextgen/model_enum_value_descriptor_proto.go +++ /dev/null @@ -1,27 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumValueDescriptorProto struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Options *EnumValueOptions `json:"options,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - ParserForType *ParserEnumValueDescriptorProto `json:"parserForType,omitempty"` - DefaultInstanceForType *EnumValueDescriptorProto `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - OptionsOrBuilder *EnumValueOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - Name string `json:"name,omitempty"` - Number int32 `json:"number,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_enum_value_descriptor_proto_or_builder.go b/harness/nextgen/model_enum_value_descriptor_proto_or_builder.go deleted file mode 100644 index 024f2edf..00000000 --- a/harness/nextgen/model_enum_value_descriptor_proto_or_builder.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumValueDescriptorProtoOrBuilder struct { - Options *EnumValueOptions `json:"options,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - OptionsOrBuilder *EnumValueOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - Name string `json:"name,omitempty"` - Number int32 `json:"number,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_enum_value_options.go b/harness/nextgen/model_enum_value_options.go deleted file mode 100644 index 8c0d6644..00000000 --- a/harness/nextgen/model_enum_value_options.go +++ /dev/null @@ -1,27 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumValueOptions struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - ParserForType *ParserEnumValueOptions `json:"parserForType,omitempty"` - DefaultInstanceForType *EnumValueOptions `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - AllFieldsRaw map[string]interface{} `json:"allFieldsRaw,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_enum_value_options_or_builder.go b/harness/nextgen/model_enum_value_options_or_builder.go deleted file mode 100644 index cd9e4a33..00000000 --- a/harness/nextgen/model_enum_value_options_or_builder.go +++ /dev/null @@ -1,23 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnumValueOptionsOrBuilder struct { - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_env_build_id_and_instance_count_info.go b/harness/nextgen/model_env_build_id_and_instance_count_info.go deleted file mode 100644 index 861296a5..00000000 --- a/harness/nextgen/model_env_build_id_and_instance_count_info.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnvBuildIdAndInstanceCountInfo struct { - EnvId string `json:"envId,omitempty"` - EnvName string `json:"envName,omitempty"` - BuildIdAndInstanceCountList []BuildIdAndInstanceCount `json:"buildIdAndInstanceCountList,omitempty"` -} diff --git a/harness/nextgen/model_env_build_id_and_instance_count_info_list.go b/harness/nextgen/model_env_build_id_and_instance_count_info_list.go deleted file mode 100644 index 262a8029..00000000 --- a/harness/nextgen/model_env_build_id_and_instance_count_info_list.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnvBuildIdAndInstanceCountInfoList struct { - EnvBuildIdAndInstanceCountInfoList []EnvBuildIdAndInstanceCountInfo `json:"envBuildIdAndInstanceCountInfoList,omitempty"` -} diff --git a/harness/nextgen/model_env_count.go b/harness/nextgen/model_env_count.go deleted file mode 100644 index bd61a301..00000000 --- a/harness/nextgen/model_env_count.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnvCount struct { - TotalCount int64 `json:"totalCount,omitempty"` - NewCount int64 `json:"newCount,omitempty"` -} diff --git a/harness/nextgen/model_env_id_count_pair.go b/harness/nextgen/model_env_id_count_pair.go deleted file mode 100644 index 1f21455e..00000000 --- a/harness/nextgen/model_env_id_count_pair.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnvIdCountPair struct { - EnvId string `json:"envId,omitempty"` - Count int32 `json:"count,omitempty"` -} diff --git a/harness/nextgen/model_environment_request_dto.go b/harness/nextgen/model_environment_request.go similarity index 91% rename from harness/nextgen/model_environment_request_dto.go rename to harness/nextgen/model_environment_request.go index cbd4badb..23d0dbb8 100644 --- a/harness/nextgen/model_environment_request_dto.go +++ b/harness/nextgen/model_environment_request.go @@ -9,7 +9,8 @@ */ package nextgen -type EnvironmentRequestDto struct { +// This is the EnvironmentRequest entity defined in Harness +type EnvironmentRequest struct { OrgIdentifier string `json:"orgIdentifier,omitempty"` ProjectIdentifier string `json:"projectIdentifier,omitempty"` Identifier string `json:"identifier,omitempty"` diff --git a/harness/nextgen/model_environment_response.go b/harness/nextgen/model_environment_response.go index d4d75125..742f5267 100644 --- a/harness/nextgen/model_environment_response.go +++ b/harness/nextgen/model_environment_response.go @@ -10,7 +10,7 @@ package nextgen type EnvironmentResponse struct { - Environment *EnvironmentResponseDto `json:"environment,omitempty"` - CreatedAt int64 `json:"createdAt,omitempty"` - LastModifiedAt int64 `json:"lastModifiedAt,omitempty"` + Environment *EnvironmentResponse `json:"environment,omitempty"` + CreatedAt int64 `json:"createdAt,omitempty"` + LastModifiedAt int64 `json:"lastModifiedAt,omitempty"` } diff --git a/harness/nextgen/model_environment_response_dto.go b/harness/nextgen/model_environment_response_dto.go deleted file mode 100644 index 62a922e9..00000000 --- a/harness/nextgen/model_environment_response_dto.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type EnvironmentResponseDto struct { - AccountId string `json:"accountId,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Identifier string `json:"identifier,omitempty"` - Name string `json:"name,omitempty"` - Description string `json:"description,omitempty"` - Color string `json:"color,omitempty"` - Type_ string `json:"type,omitempty"` - Deleted bool `json:"deleted,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Version int64 `json:"version,omitempty"` -} diff --git a/harness/nextgen/model_error.go b/harness/nextgen/model_error.go index 050d1e5e..12992280 100644 --- a/harness/nextgen/model_error.go +++ b/harness/nextgen/model_error.go @@ -18,4 +18,5 @@ type ModelError struct { DetailedMessage string `json:"detailedMessage,omitempty"` ResponseMessages []ResponseMessage `json:"responseMessages,omitempty"` Metadata *ErrorMetadataDto `json:"metadata,omitempty"` + Errors []ValidationError `json:"errors,omitempty"` } diff --git a/harness/nextgen/model_execution_deployment.go b/harness/nextgen/model_execution_deployment.go deleted file mode 100644 index 33955f9c..00000000 --- a/harness/nextgen/model_execution_deployment.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ExecutionDeployment struct { - Time int64 `json:"time,omitempty"` - Deployments *DeploymentCount `json:"deployments,omitempty"` -} diff --git a/harness/nextgen/model_execution_deployment_info.go b/harness/nextgen/model_execution_deployment_info.go deleted file mode 100644 index 65f3be99..00000000 --- a/harness/nextgen/model_execution_deployment_info.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ExecutionDeploymentInfo struct { - ExecutionDeploymentList []ExecutionDeployment `json:"executionDeploymentList,omitempty"` -} diff --git a/harness/nextgen/model_execution_status_info.go b/harness/nextgen/model_execution_status_info.go deleted file mode 100644 index e58d4d4a..00000000 --- a/harness/nextgen/model_execution_status_info.go +++ /dev/null @@ -1,23 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ExecutionStatusInfo struct { - PipelineName string `json:"pipelineName,omitempty"` - PipelineIdentifier string `json:"pipelineIdentifier,omitempty"` - StartTs int64 `json:"startTs,omitempty"` - EndTs int64 `json:"endTs,omitempty"` - Status string `json:"status,omitempty"` - PlanExecutionId string `json:"planExecutionId,omitempty"` - GitInfo *GitInfo `json:"gitInfo,omitempty"` - TriggerType string `json:"triggerType,omitempty"` - Author *AuthorInfo `json:"author,omitempty"` - ServiceInfoList []ServiceDeploymentInfo `json:"serviceInfoList,omitempty"` -} diff --git a/harness/nextgen/model_extension_range.go b/harness/nextgen/model_extension_range.go deleted file mode 100644 index 5dc57f00..00000000 --- a/harness/nextgen/model_extension_range.go +++ /dev/null @@ -1,26 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ExtensionRange struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Options *ExtensionRangeOptions `json:"options,omitempty"` - End int32 `json:"end,omitempty"` - Start int32 `json:"start,omitempty"` - ParserForType *ParserExtensionRange `json:"parserForType,omitempty"` - DefaultInstanceForType *ExtensionRange `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - OptionsOrBuilder *ExtensionRangeOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_extension_range_options.go b/harness/nextgen/model_extension_range_options.go deleted file mode 100644 index de9f60ec..00000000 --- a/harness/nextgen/model_extension_range_options.go +++ /dev/null @@ -1,26 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ExtensionRangeOptions struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - ParserForType *ParserExtensionRangeOptions `json:"parserForType,omitempty"` - DefaultInstanceForType *ExtensionRangeOptions `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - AllFieldsRaw map[string]interface{} `json:"allFieldsRaw,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_extension_range_options_or_builder.go b/harness/nextgen/model_extension_range_options_or_builder.go deleted file mode 100644 index 26e0ea0a..00000000 --- a/harness/nextgen/model_extension_range_options_or_builder.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ExtensionRangeOptionsOrBuilder struct { - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_extension_range_or_builder.go b/harness/nextgen/model_extension_range_or_builder.go deleted file mode 100644 index cef52723..00000000 --- a/harness/nextgen/model_extension_range_or_builder.go +++ /dev/null @@ -1,23 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ExtensionRangeOrBuilder struct { - Options *ExtensionRangeOptions `json:"options,omitempty"` - End int32 `json:"end,omitempty"` - Start int32 `json:"start,omitempty"` - OptionsOrBuilder *ExtensionRangeOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_feature_restriction_detail_list_request.go b/harness/nextgen/model_feature_restriction_detail_list_request.go new file mode 100644 index 00000000..17f3d85e --- /dev/null +++ b/harness/nextgen/model_feature_restriction_detail_list_request.go @@ -0,0 +1,15 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains a list of feature restriction detail request objects defined in Harness +type FeatureRestrictionDetailListRequest struct { + Names []string `json:"names"` +} diff --git a/harness/nextgen/model_feature_restriction_detail_request.go b/harness/nextgen/model_feature_restriction_detail_request.go index 2f7859c4..70d6f5c2 100644 --- a/harness/nextgen/model_feature_restriction_detail_request.go +++ b/harness/nextgen/model_feature_restriction_detail_request.go @@ -9,7 +9,7 @@ */ package nextgen -// This is the view of a feature restriction detail request object defined in Harness +// This contains a feature restriction detail request object defined in Harness type FeatureRestrictionDetailRequest struct { Name string `json:"name"` } diff --git a/harness/nextgen/model_feature_restriction_details.go b/harness/nextgen/model_feature_restriction_details.go index 66083ecd..2ec85f00 100644 --- a/harness/nextgen/model_feature_restriction_details.go +++ b/harness/nextgen/model_feature_restriction_details.go @@ -9,12 +9,12 @@ */ package nextgen -// This is the view of a feature restriction details object defined in Harness +// This contains the feature restriction details object defined in Harness type FeatureRestrictionDetails struct { - Name string `json:"name,omitempty"` - Description string `json:"description,omitempty"` - ModuleType string `json:"moduleType,omitempty"` - Allowed bool `json:"allowed,omitempty"` - RestrictionType string `json:"restrictionType,omitempty"` - Restriction *RestrictionDto `json:"restriction,omitempty"` + Name string `json:"name,omitempty"` + Description string `json:"description,omitempty"` + ModuleType string `json:"moduleType,omitempty"` + Allowed bool `json:"allowed,omitempty"` + RestrictionType string `json:"restrictionType,omitempty"` + Restriction *Restriction `json:"restriction,omitempty"` } diff --git a/harness/nextgen/model_feature_restriction_metadata.go b/harness/nextgen/model_feature_restriction_metadata.go index 8e059160..ba0d4c17 100644 --- a/harness/nextgen/model_feature_restriction_metadata.go +++ b/harness/nextgen/model_feature_restriction_metadata.go @@ -9,10 +9,10 @@ */ package nextgen -// This is the view of a feature restriction metadata object defined in Harness +// This contains metadata of the feature restriction object defined in Harness type FeatureRestrictionMetadata struct { - Name string `json:"name,omitempty"` - ModuleType string `json:"moduleType,omitempty"` - Edition string `json:"edition,omitempty"` - RestrictionMetadata map[string]RestrictionMetadataDto `json:"restrictionMetadata,omitempty"` + Name string `json:"name,omitempty"` + ModuleType string `json:"moduleType,omitempty"` + Edition string `json:"edition,omitempty"` + RestrictionMetadata map[string]RestrictionMetadata `json:"restrictionMetadata,omitempty"` } diff --git a/harness/nextgen/model_feature_restriction_usage_dto.go b/harness/nextgen/model_feature_restriction_usage_dto.go deleted file mode 100644 index bbe909f2..00000000 --- a/harness/nextgen/model_feature_restriction_usage_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FeatureRestrictionUsageDto struct { - Count int64 `json:"count,omitempty"` -} diff --git a/harness/nextgen/model_field_descriptor.go b/harness/nextgen/model_field_descriptor.go deleted file mode 100644 index 03334235..00000000 --- a/harness/nextgen/model_field_descriptor.go +++ /dev/null @@ -1,38 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FieldDescriptor struct { - Index int32 `json:"index,omitempty"` - Proto *FieldDescriptorProto `json:"proto,omitempty"` - FullName string `json:"fullName,omitempty"` - JsonName string `json:"jsonName,omitempty"` - File *FileDescriptor `json:"file,omitempty"` - ExtensionScope *Descriptor `json:"extensionScope,omitempty"` - Type_ string `json:"type,omitempty"` - ContainingType *Descriptor `json:"containingType,omitempty"` - MessageType *Descriptor `json:"messageType,omitempty"` - ContainingOneof *OneofDescriptor `json:"containingOneof,omitempty"` - EnumType *EnumDescriptor `json:"enumType,omitempty"` - DefaultValue *interface{} `json:"defaultValue,omitempty"` - Options *FieldOptions `json:"options,omitempty"` - Optional bool `json:"optional,omitempty"` - JavaType string `json:"javaType,omitempty"` - LiteJavaType string `json:"liteJavaType,omitempty"` - Packable bool `json:"packable,omitempty"` - Repeated bool `json:"repeated,omitempty"` - LiteType string `json:"liteType,omitempty"` - Packed bool `json:"packed,omitempty"` - MapField bool `json:"mapField,omitempty"` - Required bool `json:"required,omitempty"` - Extension bool `json:"extension,omitempty"` - Name string `json:"name,omitempty"` - Number int32 `json:"number,omitempty"` -} diff --git a/harness/nextgen/model_field_descriptor_proto.go b/harness/nextgen/model_field_descriptor_proto.go deleted file mode 100644 index 6169293c..00000000 --- a/harness/nextgen/model_field_descriptor_proto.go +++ /dev/null @@ -1,38 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FieldDescriptorProto struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Label string `json:"label,omitempty"` - Options *FieldOptions `json:"options,omitempty"` - JsonName string `json:"jsonName,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - ParserForType *ParserFieldDescriptorProto `json:"parserForType,omitempty"` - DefaultInstanceForType *FieldDescriptorProto `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - TypeNameBytes *ByteString `json:"typeNameBytes,omitempty"` - ExtendeeBytes *ByteString `json:"extendeeBytes,omitempty"` - DefaultValueBytes *ByteString `json:"defaultValueBytes,omitempty"` - JsonNameBytes *ByteString `json:"jsonNameBytes,omitempty"` - OneofIndex int32 `json:"oneofIndex,omitempty"` - Extendee string `json:"extendee,omitempty"` - OptionsOrBuilder *FieldOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - Name string `json:"name,omitempty"` - TypeName string `json:"typeName,omitempty"` - Type_ string `json:"type,omitempty"` - DefaultValue string `json:"defaultValue,omitempty"` - Number int32 `json:"number,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_field_descriptor_proto_or_builder.go b/harness/nextgen/model_field_descriptor_proto_or_builder.go deleted file mode 100644 index faa00b33..00000000 --- a/harness/nextgen/model_field_descriptor_proto_or_builder.go +++ /dev/null @@ -1,35 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FieldDescriptorProtoOrBuilder struct { - Label string `json:"label,omitempty"` - Options *FieldOptions `json:"options,omitempty"` - JsonName string `json:"jsonName,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - TypeNameBytes *ByteString `json:"typeNameBytes,omitempty"` - ExtendeeBytes *ByteString `json:"extendeeBytes,omitempty"` - DefaultValueBytes *ByteString `json:"defaultValueBytes,omitempty"` - JsonNameBytes *ByteString `json:"jsonNameBytes,omitempty"` - OneofIndex int32 `json:"oneofIndex,omitempty"` - Extendee string `json:"extendee,omitempty"` - OptionsOrBuilder *FieldOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - Name string `json:"name,omitempty"` - TypeName string `json:"typeName,omitempty"` - Type_ string `json:"type,omitempty"` - DefaultValue string `json:"defaultValue,omitempty"` - Number int32 `json:"number,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_field_options.go b/harness/nextgen/model_field_options.go deleted file mode 100644 index c3e30e2e..00000000 --- a/harness/nextgen/model_field_options.go +++ /dev/null @@ -1,32 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FieldOptions struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Ctype string `json:"ctype,omitempty"` - Deprecated bool `json:"deprecated,omitempty"` - Weak bool `json:"weak,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - ParserForType *ParserFieldOptions `json:"parserForType,omitempty"` - DefaultInstanceForType *FieldOptions `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - Lazy bool `json:"lazy,omitempty"` - Jstype string `json:"jstype,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - Packed bool `json:"packed,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - AllFieldsRaw map[string]interface{} `json:"allFieldsRaw,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_field_options_or_builder.go b/harness/nextgen/model_field_options_or_builder.go deleted file mode 100644 index 0fd7b815..00000000 --- a/harness/nextgen/model_field_options_or_builder.go +++ /dev/null @@ -1,28 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FieldOptionsOrBuilder struct { - Ctype string `json:"ctype,omitempty"` - Deprecated bool `json:"deprecated,omitempty"` - Weak bool `json:"weak,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - Lazy bool `json:"lazy,omitempty"` - Jstype string `json:"jstype,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - Packed bool `json:"packed,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_file_descriptor.go b/harness/nextgen/model_file_descriptor.go deleted file mode 100644 index 0954f893..00000000 --- a/harness/nextgen/model_file_descriptor.go +++ /dev/null @@ -1,26 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FileDescriptor struct { - Proto *FileDescriptorProto `json:"proto,omitempty"` - MessageTypes []Descriptor `json:"messageTypes,omitempty"` - EnumTypes []EnumDescriptor `json:"enumTypes,omitempty"` - Services []ServiceDescriptor `json:"services,omitempty"` - Extensions []FieldDescriptor `json:"extensions,omitempty"` - Dependencies []FileDescriptor `json:"dependencies,omitempty"` - PublicDependencies []FileDescriptor `json:"publicDependencies,omitempty"` - FullName string `json:"fullName,omitempty"` - Options *FileOptions `json:"options,omitempty"` - Syntax string `json:"syntax,omitempty"` - Name string `json:"name,omitempty"` - Package_ string `json:"package,omitempty"` - File *FileDescriptor `json:"file,omitempty"` -} diff --git a/harness/nextgen/model_file_descriptor_proto.go b/harness/nextgen/model_file_descriptor_proto.go deleted file mode 100644 index fe2700a2..00000000 --- a/harness/nextgen/model_file_descriptor_proto.go +++ /dev/null @@ -1,50 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FileDescriptorProto struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Options *FileOptions `json:"options,omitempty"` - PublicDependencyCount int32 `json:"publicDependencyCount,omitempty"` - EnumTypeCount int32 `json:"enumTypeCount,omitempty"` - ExtensionCount int32 `json:"extensionCount,omitempty"` - ServiceCount int32 `json:"serviceCount,omitempty"` - Syntax string `json:"syntax,omitempty"` - ServiceList []ServiceDescriptorProto `json:"serviceList,omitempty"` - DependencyCount int32 `json:"dependencyCount,omitempty"` - MessageTypeCount int32 `json:"messageTypeCount,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - PackageBytes *ByteString `json:"packageBytes,omitempty"` - DependencyList []string `json:"dependencyList,omitempty"` - ParserForType *ParserFileDescriptorProto `json:"parserForType,omitempty"` - DefaultInstanceForType *FileDescriptorProto `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - WeakDependencyList []int32 `json:"weakDependencyList,omitempty"` - MessageTypeList []DescriptorProto `json:"messageTypeList,omitempty"` - MessageTypeOrBuilderList []DescriptorProtoOrBuilder `json:"messageTypeOrBuilderList,omitempty"` - EnumTypeList []EnumDescriptorProto `json:"enumTypeList,omitempty"` - EnumTypeOrBuilderList []EnumDescriptorProtoOrBuilder `json:"enumTypeOrBuilderList,omitempty"` - ServiceOrBuilderList []ServiceDescriptorProtoOrBuilder `json:"serviceOrBuilderList,omitempty"` - ExtensionList []FieldDescriptorProto `json:"extensionList,omitempty"` - PublicDependencyList []int32 `json:"publicDependencyList,omitempty"` - WeakDependencyCount int32 `json:"weakDependencyCount,omitempty"` - ExtensionOrBuilderList []FieldDescriptorProtoOrBuilder `json:"extensionOrBuilderList,omitempty"` - OptionsOrBuilder *FileOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - SourceCodeInfo *SourceCodeInfo `json:"sourceCodeInfo,omitempty"` - SourceCodeInfoOrBuilder *SourceCodeInfoOrBuilder `json:"sourceCodeInfoOrBuilder,omitempty"` - SyntaxBytes *ByteString `json:"syntaxBytes,omitempty"` - Name string `json:"name,omitempty"` - Package_ string `json:"package,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_file_options.go b/harness/nextgen/model_file_options.go deleted file mode 100644 index b1396990..00000000 --- a/harness/nextgen/model_file_options.go +++ /dev/null @@ -1,56 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FileOptions struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - ParserForType *ParserFileOptions `json:"parserForType,omitempty"` - DefaultInstanceForType *FileOptions `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - JavaPackage string `json:"javaPackage,omitempty"` - JavaPackageBytes *ByteString `json:"javaPackageBytes,omitempty"` - JavaOuterClassname string `json:"javaOuterClassname,omitempty"` - JavaOuterClassnameBytes *ByteString `json:"javaOuterClassnameBytes,omitempty"` - JavaMultipleFiles bool `json:"javaMultipleFiles,omitempty"` - JavaGenerateEqualsAndHash bool `json:"javaGenerateEqualsAndHash,omitempty"` - OptimizeFor string `json:"optimizeFor,omitempty"` - GoPackage string `json:"goPackage,omitempty"` - GoPackageBytes *ByteString `json:"goPackageBytes,omitempty"` - CcGenericServices bool `json:"ccGenericServices,omitempty"` - JavaGenericServices bool `json:"javaGenericServices,omitempty"` - PyGenericServices bool `json:"pyGenericServices,omitempty"` - PhpGenericServices bool `json:"phpGenericServices,omitempty"` - CcEnableArenas bool `json:"ccEnableArenas,omitempty"` - ObjcClassPrefix string `json:"objcClassPrefix,omitempty"` - ObjcClassPrefixBytes *ByteString `json:"objcClassPrefixBytes,omitempty"` - CsharpNamespace string `json:"csharpNamespace,omitempty"` - CsharpNamespaceBytes *ByteString `json:"csharpNamespaceBytes,omitempty"` - SwiftPrefix string `json:"swiftPrefix,omitempty"` - SwiftPrefixBytes *ByteString `json:"swiftPrefixBytes,omitempty"` - PhpClassPrefix string `json:"phpClassPrefix,omitempty"` - PhpClassPrefixBytes *ByteString `json:"phpClassPrefixBytes,omitempty"` - PhpNamespace string `json:"phpNamespace,omitempty"` - PhpNamespaceBytes *ByteString `json:"phpNamespaceBytes,omitempty"` - PhpMetadataNamespace string `json:"phpMetadataNamespace,omitempty"` - PhpMetadataNamespaceBytes *ByteString `json:"phpMetadataNamespaceBytes,omitempty"` - RubyPackage string `json:"rubyPackage,omitempty"` - RubyPackageBytes *ByteString `json:"rubyPackageBytes,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - JavaStringCheckUtf8 bool `json:"javaStringCheckUtf8,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - AllFieldsRaw map[string]interface{} `json:"allFieldsRaw,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_file_options_or_builder.go b/harness/nextgen/model_file_options_or_builder.go deleted file mode 100644 index d3322b1e..00000000 --- a/harness/nextgen/model_file_options_or_builder.go +++ /dev/null @@ -1,52 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FileOptionsOrBuilder struct { - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - JavaPackage string `json:"javaPackage,omitempty"` - JavaPackageBytes *ByteString `json:"javaPackageBytes,omitempty"` - JavaOuterClassname string `json:"javaOuterClassname,omitempty"` - JavaOuterClassnameBytes *ByteString `json:"javaOuterClassnameBytes,omitempty"` - JavaMultipleFiles bool `json:"javaMultipleFiles,omitempty"` - JavaGenerateEqualsAndHash bool `json:"javaGenerateEqualsAndHash,omitempty"` - OptimizeFor string `json:"optimizeFor,omitempty"` - GoPackage string `json:"goPackage,omitempty"` - GoPackageBytes *ByteString `json:"goPackageBytes,omitempty"` - CcGenericServices bool `json:"ccGenericServices,omitempty"` - JavaGenericServices bool `json:"javaGenericServices,omitempty"` - PyGenericServices bool `json:"pyGenericServices,omitempty"` - PhpGenericServices bool `json:"phpGenericServices,omitempty"` - CcEnableArenas bool `json:"ccEnableArenas,omitempty"` - ObjcClassPrefix string `json:"objcClassPrefix,omitempty"` - ObjcClassPrefixBytes *ByteString `json:"objcClassPrefixBytes,omitempty"` - CsharpNamespace string `json:"csharpNamespace,omitempty"` - CsharpNamespaceBytes *ByteString `json:"csharpNamespaceBytes,omitempty"` - SwiftPrefix string `json:"swiftPrefix,omitempty"` - SwiftPrefixBytes *ByteString `json:"swiftPrefixBytes,omitempty"` - PhpClassPrefix string `json:"phpClassPrefix,omitempty"` - PhpClassPrefixBytes *ByteString `json:"phpClassPrefixBytes,omitempty"` - PhpNamespace string `json:"phpNamespace,omitempty"` - PhpNamespaceBytes *ByteString `json:"phpNamespaceBytes,omitempty"` - PhpMetadataNamespace string `json:"phpMetadataNamespace,omitempty"` - PhpMetadataNamespaceBytes *ByteString `json:"phpMetadataNamespaceBytes,omitempty"` - RubyPackage string `json:"rubyPackage,omitempty"` - RubyPackageBytes *ByteString `json:"rubyPackageBytes,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - JavaStringCheckUtf8 bool `json:"javaStringCheckUtf8,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_files_identifier_body.go b/harness/nextgen/model_files_identifier_body.go deleted file mode 100644 index 333a86d3..00000000 --- a/harness/nextgen/model_files_identifier_body.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FilesIdentifierBody struct { - File *interface{} `json:"file,omitempty"` - Spec string `json:"spec,omitempty"` -} diff --git a/harness/nextgen/model_filter_dto.go b/harness/nextgen/model_filter_dto.go deleted file mode 100644 index 1681c864..00000000 --- a/harness/nextgen/model_filter_dto.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FilterDto struct { - Name string `json:"name"` - Identifier string `json:"identifier"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - FilterProperties *FilterPropertiesDto `json:"filterProperties"` - FilterVisibility string `json:"filterVisibility,omitempty"` -} diff --git a/harness/nextgen/model_filter_properties_dto.go b/harness/nextgen/model_filter_properties.go similarity index 82% rename from harness/nextgen/model_filter_properties_dto.go rename to harness/nextgen/model_filter_properties.go index 74c7742a..9357165d 100644 --- a/harness/nextgen/model_filter_properties_dto.go +++ b/harness/nextgen/model_filter_properties.go @@ -9,7 +9,8 @@ */ package nextgen -type FilterPropertiesDto struct { +// This is the view of the Filter Properties entity defined in Harness +type FilterProperties struct { Tags map[string]string `json:"tags,omitempty"` FilterType string `json:"filterType,omitempty"` } diff --git a/harness/nextgen/model_flow_control_config.go b/harness/nextgen/model_flow_control_config.go deleted file mode 100644 index baf0998e..00000000 --- a/harness/nextgen/model_flow_control_config.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type FlowControlConfig struct { - Barriers []BarrierInfoConfig `json:"barriers,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_organization_aggregate_dto.go b/harness/nextgen/model_full_sync_request.go similarity index 50% rename from harness/nextgen/model_response_dto_organization_aggregate_dto.go rename to harness/nextgen/model_full_sync_request.go index f58925db..5cb40b2d 100644 --- a/harness/nextgen/model_response_dto_organization_aggregate_dto.go +++ b/harness/nextgen/model_full_sync_request.go @@ -9,9 +9,11 @@ */ package nextgen -type ResponseDtoOrganizationAggregateDto struct { - Status string `json:"status,omitempty"` - Data *OrganizationAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` +// The full sync request +type FullSyncRequest struct { + CreatePR bool `json:"createPR,omitempty"` + Branch string `json:"branch"` + TargetBranchForPR string `json:"targetBranchForPR,omitempty"` + CommitMessage string `json:"commitMessage,omitempty"` + YamlGitConfigIdentifier string `json:"yamlGitConfigIdentifier"` } diff --git a/harness/nextgen/model_add_users_dto.go b/harness/nextgen/model_gcp_connector.go similarity index 61% rename from harness/nextgen/model_add_users_dto.go rename to harness/nextgen/model_gcp_connector.go index 8d624973..206bbfdf 100644 --- a/harness/nextgen/model_add_users_dto.go +++ b/harness/nextgen/model_gcp_connector.go @@ -9,8 +9,8 @@ */ package nextgen -type AddUsersDto struct { - Emails []string `json:"emails,omitempty"` - RoleBindings []RoleBinding `json:"roleBindings,omitempty"` - UserGroups []string `json:"userGroups,omitempty"` +// This contains GCP connector details +type GcpConnector struct { + Credential *GcpConnectorCredential `json:"credential,omitempty"` + DelegateSelectors []string `json:"delegateSelectors,omitempty"` } diff --git a/harness/nextgen/model_deployment_info.go b/harness/nextgen/model_gcp_connector_credential.go similarity index 59% rename from harness/nextgen/model_deployment_info.go rename to harness/nextgen/model_gcp_connector_credential.go index 39d894d8..18febf4d 100644 --- a/harness/nextgen/model_deployment_info.go +++ b/harness/nextgen/model_gcp_connector_credential.go @@ -9,8 +9,11 @@ */ package nextgen -type DeploymentInfo struct { - Count int64 `json:"count,omitempty"` - Rate float64 `json:"rate,omitempty"` - CountList []DeploymentDateAndCount `json:"countList,omitempty"` +import "encoding/json" + +// This contains GCP connector credentials +type GcpConnectorCredential struct { + Type_ GcpAuthType `json:"type"` + ManualConfig *GcpManualDetails `json:"-"` + Spec json.RawMessage `json:"spec,omitempty"` } diff --git a/harness/nextgen/model_gcp_connector_credential_serializer.go b/harness/nextgen/model_gcp_connector_credential_serializer.go index 8f909bf2..b35a653b 100644 --- a/harness/nextgen/model_gcp_connector_credential_serializer.go +++ b/harness/nextgen/model_gcp_connector_credential_serializer.go @@ -5,9 +5,9 @@ import ( "fmt" ) -func (a *GcpConnectorCredentialDto) UnmarshalJSON(data []byte) error { +func (a *GcpConnectorCredential) UnmarshalJSON(data []byte) error { - type Alias GcpConnectorCredentialDto + type Alias GcpConnectorCredential aux := &struct { *Alias @@ -21,9 +21,9 @@ func (a *GcpConnectorCredentialDto) UnmarshalJSON(data []byte) error { } switch a.Type_ { - case GcpAuthTypes.ManualConfig.String(): + case GcpAuthTypes.ManualConfig: err = json.Unmarshal(aux.Spec, &a.ManualConfig) - case GcpAuthTypes.InheritFromDelegate.String(): + case GcpAuthTypes.InheritFromDelegate: // do nothing default: panic(fmt.Sprintf("unknown gcp auth type %s", a.Type_)) @@ -32,16 +32,16 @@ func (a *GcpConnectorCredentialDto) UnmarshalJSON(data []byte) error { return err } -func (a *GcpConnectorCredentialDto) MarshalJSON() ([]byte, error) { - type Alias GcpConnectorCredentialDto +func (a *GcpConnectorCredential) MarshalJSON() ([]byte, error) { + type Alias GcpConnectorCredential var spec []byte var err error switch a.Type_ { - case GcpAuthTypes.ManualConfig.String(): + case GcpAuthTypes.ManualConfig: spec, err = json.Marshal(a.ManualConfig) - case GcpAuthTypes.InheritFromDelegate.String(): + case GcpAuthTypes.InheritFromDelegate: // do nothing default: panic(fmt.Sprintf("unknown gcp auth type %s", a.Type_)) diff --git a/harness/nextgen/model_gcp_connector_dto.go b/harness/nextgen/model_gcp_connector_dto.go deleted file mode 100644 index 37a58a2a..00000000 --- a/harness/nextgen/model_gcp_connector_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GcpConnectorDto struct { - Credential *GcpConnectorCredentialDto `json:"credential,omitempty"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` -} diff --git a/harness/nextgen/model_aws_code_commit_credentials_dto.go b/harness/nextgen/model_gcp_credential_spec.go similarity index 81% rename from harness/nextgen/model_aws_code_commit_credentials_dto.go rename to harness/nextgen/model_gcp_credential_spec.go index 67c5b357..0594652a 100644 --- a/harness/nextgen/model_aws_code_commit_credentials_dto.go +++ b/harness/nextgen/model_gcp_credential_spec.go @@ -9,5 +9,6 @@ */ package nextgen -type AwsCodeCommitCredentialsDto struct { +// This contains GCP connector credentials spec +type GcpCredentialSpec struct { } diff --git a/harness/nextgen/model_gcp_credential_spec_dto.go b/harness/nextgen/model_gcp_credential_spec_dto.go deleted file mode 100644 index 21a196eb..00000000 --- a/harness/nextgen/model_gcp_credential_spec_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GcpCredentialSpecDto struct { -} diff --git a/harness/nextgen/model_gcp_kms_config_dto.go b/harness/nextgen/model_gcp_kms_config_dto.go deleted file mode 100644 index 75ee837a..00000000 --- a/harness/nextgen/model_gcp_kms_config_dto.go +++ /dev/null @@ -1,29 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GcpKmsConfigDto struct { - Name string `json:"name,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Identifier string `json:"identifier,omitempty"` - Description string `json:"description,omitempty"` - EncryptionType string `json:"encryptionType,omitempty"` - HarnessManaged bool `json:"harnessManaged,omitempty"` - Default_ bool `json:"default,omitempty"` - ProjectId string `json:"projectId,omitempty"` - Region string `json:"region,omitempty"` - KeyRing string `json:"keyRing,omitempty"` - KeyName string `json:"keyName,omitempty"` - Credentials []string `json:"credentials,omitempty"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` -} diff --git a/harness/nextgen/model_gcp_manual_details_dto.go b/harness/nextgen/model_gcp_manual_details.go similarity index 83% rename from harness/nextgen/model_gcp_manual_details_dto.go rename to harness/nextgen/model_gcp_manual_details.go index daa25ce9..90aaae5f 100644 --- a/harness/nextgen/model_gcp_manual_details_dto.go +++ b/harness/nextgen/model_gcp_manual_details.go @@ -9,6 +9,7 @@ */ package nextgen -type GcpManualDetailsDto struct { +// This contains GCP manual credentials details +type GcpManualDetails struct { SecretKeyRef string `json:"secretKeyRef"` } diff --git a/harness/nextgen/model_gcr_build_details_dto.go b/harness/nextgen/model_gcr_build_details_dto.go deleted file mode 100644 index 6e1c4419..00000000 --- a/harness/nextgen/model_gcr_build_details_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GcrBuildDetailsDto struct { - Tag string `json:"tag,omitempty"` - BuildUrl string `json:"buildUrl,omitempty"` - Metadata map[string]string `json:"metadata,omitempty"` - Labels map[string]string `json:"labels,omitempty"` - ImagePath string `json:"imagePath,omitempty"` -} diff --git a/harness/nextgen/model_gcr_request_dto.go b/harness/nextgen/model_gcr_request_dto.go deleted file mode 100644 index 7a2d68df..00000000 --- a/harness/nextgen/model_gcr_request_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GcrRequestDto struct { - Tag string `json:"tag,omitempty"` - TagRegex string `json:"tagRegex,omitempty"` - TagsList []string `json:"tagsList,omitempty"` - RegistryHostname string `json:"registryHostname,omitempty"` -} diff --git a/harness/nextgen/model_gcr_response_dto.go b/harness/nextgen/model_gcr_response_dto.go deleted file mode 100644 index 8331a6b4..00000000 --- a/harness/nextgen/model_gcr_response_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GcrResponseDto struct { - BuildDetailsList []GcrBuildDetailsDto `json:"buildDetailsList,omitempty"` -} diff --git a/harness/nextgen/model_base_ssh_spec_dto.go b/harness/nextgen/model_git_authentication.go similarity index 77% rename from harness/nextgen/model_base_ssh_spec_dto.go rename to harness/nextgen/model_git_authentication.go index f95cb8ee..d6128464 100644 --- a/harness/nextgen/model_base_ssh_spec_dto.go +++ b/harness/nextgen/model_git_authentication.go @@ -9,6 +9,7 @@ */ package nextgen -type BaseSshSpecDto struct { +// This is a interface for details of the Generic Git authentication information +type GitAuthentication struct { Type_ string `json:"type"` } diff --git a/harness/nextgen/model_git_authentication_dto.go b/harness/nextgen/model_git_authentication_dto.go deleted file mode 100644 index b21fe82f..00000000 --- a/harness/nextgen/model_git_authentication_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitAuthenticationDto struct { - Type_ string `json:"type"` -} diff --git a/harness/nextgen/model_git_branch_dto.go b/harness/nextgen/model_git_branch.go similarity index 83% rename from harness/nextgen/model_git_branch_dto.go rename to harness/nextgen/model_git_branch.go index 84f918df..79e0415b 100644 --- a/harness/nextgen/model_git_branch_dto.go +++ b/harness/nextgen/model_git_branch.go @@ -9,7 +9,8 @@ */ package nextgen -type GitBranchDto struct { +// This contains details of the branch, like Branch name, Sync Status. +type GitBranch struct { BranchName string `json:"branchName,omitempty"` BranchSyncStatus string `json:"branchSyncStatus,omitempty"` } diff --git a/harness/nextgen/model_git_sync_entity_list_dto.go b/harness/nextgen/model_git_branch_list.go similarity index 62% rename from harness/nextgen/model_git_sync_entity_list_dto.go rename to harness/nextgen/model_git_branch_list.go index 6cf0cbe2..507c15fc 100644 --- a/harness/nextgen/model_git_sync_entity_list_dto.go +++ b/harness/nextgen/model_git_branch_list.go @@ -9,8 +9,8 @@ */ package nextgen -type GitSyncEntityListDto struct { - EntityType string `json:"entityType,omitempty"` - Count int64 `json:"count,omitempty"` - GitSyncEntities []GitSyncEntityDto `json:"gitSyncEntities,omitempty"` +// This contains the details of branches and the default branch +type GitBranchList struct { + DefaultBranch *GitBranch `json:"defaultBranch,omitempty"` + Branches *PageResponseGitBranch `json:"branches,omitempty"` } diff --git a/harness/nextgen/model_git_branch_list_dto.go b/harness/nextgen/model_git_branch_list_dto.go deleted file mode 100644 index af567210..00000000 --- a/harness/nextgen/model_git_branch_list_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitBranchListDto struct { - DefaultBranch *GitBranchDto `json:"defaultBranch,omitempty"` - Branches *PageResponseGitBranchDto `json:"branches,omitempty"` -} diff --git a/harness/nextgen/model_git_config_dto.go b/harness/nextgen/model_git_config.go similarity index 79% rename from harness/nextgen/model_git_config_dto.go rename to harness/nextgen/model_git_config.go index 7e2267a7..7c3afb75 100644 --- a/harness/nextgen/model_git_config_dto.go +++ b/harness/nextgen/model_git_config.go @@ -9,18 +9,17 @@ */ package nextgen -import ( - "encoding/json" -) +import "encoding/json" -type GitConfigDto struct { +// This contains details of the Generic Git connector +type GitConfig struct { Url string `json:"url"` ValidationRepo string `json:"validationRepo,omitempty"` BranchName string `json:"branchName,omitempty"` DelegateSelectors []string `json:"delegateSelectors,omitempty"` - Type_ string `json:"type"` + Type_ GitAuthType `json:"type"` Http *GitHttpAuthenticationDto `json:"-"` - Ssh *GitSshAuthenticationDto `json:"-"` + Ssh *GitSshAuthentication `json:"-"` ConnectionType string `json:"connectionType"` Spec json.RawMessage `json:"spec"` } diff --git a/harness/nextgen/model_git_config_serializer.go b/harness/nextgen/model_git_config_serializer.go index c58c5537..0cca0116 100644 --- a/harness/nextgen/model_git_config_serializer.go +++ b/harness/nextgen/model_git_config_serializer.go @@ -5,9 +5,9 @@ import ( "fmt" ) -func (a *GitConfigDto) UnmarshalJSON(data []byte) error { +func (a *GitConfig) UnmarshalJSON(data []byte) error { - type Alias GitConfigDto + type Alias GitConfig aux := &struct { *Alias @@ -21,9 +21,9 @@ func (a *GitConfigDto) UnmarshalJSON(data []byte) error { } switch a.Type_ { - case GitAuthTypes.Http.String(): + case GitAuthTypes.Http: err = json.Unmarshal(aux.Spec, &a.Http) - case GitAuthTypes.Ssh.String(): + case GitAuthTypes.Ssh: err = json.Unmarshal(aux.Spec, &a.Ssh) default: panic(fmt.Sprintf("unknown git auth method type %s", a.Type_)) @@ -32,16 +32,16 @@ func (a *GitConfigDto) UnmarshalJSON(data []byte) error { return err } -func (a *GitConfigDto) MarshalJSON() ([]byte, error) { - type Alias GitConfigDto +func (a *GitConfig) MarshalJSON() ([]byte, error) { + type Alias GitConfig var spec []byte var err error switch a.Type_ { - case GitAuthTypes.Http.String(): + case GitAuthTypes.Http: spec, err = json.Marshal(a.Http) - case GitAuthTypes.Ssh.String(): + case GitAuthTypes.Ssh: spec, err = json.Marshal(a.Ssh) default: panic(fmt.Sprintf("unknown git auth method type %s", a.Type_)) diff --git a/harness/nextgen/model_git_enabled_dto.go b/harness/nextgen/model_git_enabled.go similarity index 84% rename from harness/nextgen/model_git_enabled_dto.go rename to harness/nextgen/model_git_enabled.go index f27c2830..8a24855d 100644 --- a/harness/nextgen/model_git_enabled_dto.go +++ b/harness/nextgen/model_git_enabled.go @@ -9,7 +9,8 @@ */ package nextgen -type GitEnabledDto struct { +// This contains details of mode of connectivity and Git Sync Enablement +type GitEnabled struct { IsGitSyncEnabled bool `json:"isGitSyncEnabled,omitempty"` ConnectivityMode string `json:"connectivityMode,omitempty"` GitSyncEnabled bool `json:"gitSyncEnabled,omitempty"` diff --git a/harness/nextgen/model_git_entity_branch_summary_filter_dto.go b/harness/nextgen/model_git_entity_branch_summary_filter.go similarity index 78% rename from harness/nextgen/model_git_entity_branch_summary_filter_dto.go rename to harness/nextgen/model_git_entity_branch_summary_filter.go index a1df7857..b95aa79e 100644 --- a/harness/nextgen/model_git_entity_branch_summary_filter_dto.go +++ b/harness/nextgen/model_git_entity_branch_summary_filter.go @@ -9,7 +9,8 @@ */ package nextgen -type GitEntityBranchSummaryFilterDto struct { +// This contains filters for Git Sync Entity such as Module Type, Entity Type and Search Term +type GitEntityBranchSummaryFilter struct { ModuleType string `json:"moduleType,omitempty"` EntityTypes []string `json:"entityTypes,omitempty"` SearchTerm string `json:"searchTerm,omitempty"` diff --git a/harness/nextgen/model_git_entity_summary_filter_dto.go b/harness/nextgen/model_git_entity_summary_filter.go similarity index 80% rename from harness/nextgen/model_git_entity_summary_filter_dto.go rename to harness/nextgen/model_git_entity_summary_filter.go index 1278aa34..5b0e9225 100644 --- a/harness/nextgen/model_git_entity_summary_filter_dto.go +++ b/harness/nextgen/model_git_entity_summary_filter.go @@ -9,7 +9,8 @@ */ package nextgen -type GitEntitySummaryFilterDto struct { +// This contains filters for Git Sync Entity such as Module Type, Entity Type, Git Sync Config Ids and Search Term +type GitEntitySummaryFilter struct { ModuleType string `json:"moduleType,omitempty"` GitSyncConfigIdentifiers []string `json:"gitSyncConfigIdentifiers,omitempty"` EntityTypes []string `json:"entityTypes,omitempty"` diff --git a/harness/nextgen/model_git_http_authentication_dto.go b/harness/nextgen/model_git_http_authentication_dto.go index 713c64ff..6fc407e9 100644 --- a/harness/nextgen/model_git_http_authentication_dto.go +++ b/harness/nextgen/model_git_http_authentication_dto.go @@ -10,7 +10,7 @@ package nextgen type GitHttpAuthenticationDto struct { - Type_ string `json:"type"` + Type_ string `json:"-"` Username string `json:"username,omitempty"` UsernameRef string `json:"usernameRef,omitempty"` PasswordRef string `json:"passwordRef"` diff --git a/harness/nextgen/model_git_info.go b/harness/nextgen/model_git_info.go deleted file mode 100644 index 391a0ba9..00000000 --- a/harness/nextgen/model_git_info.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitInfo struct { - SourceBranch string `json:"sourceBranch,omitempty"` - TargetBranch string `json:"targetBranch,omitempty"` - Commit string `json:"commit,omitempty"` - CommitID string `json:"commitID,omitempty"` - EventType string `json:"eventType,omitempty"` - RepoName string `json:"repoName,omitempty"` -} diff --git a/harness/nextgen/model_git_ops_info_dto.go b/harness/nextgen/model_git_ops_info_dto.go deleted file mode 100644 index 71b65261..00000000 --- a/harness/nextgen/model_git_ops_info_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitOpsInfoDto struct { - Type_ string `json:"type,omitempty"` -} diff --git a/harness/nextgen/model_git_ops_provider_dto.go b/harness/nextgen/model_git_ops_provider_dto.go deleted file mode 100644 index 1769d411..00000000 --- a/harness/nextgen/model_git_ops_provider_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitOpsProviderDto struct { - Name string `json:"name"` - Identifier string `json:"identifier"` - Description string `json:"description,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Spec *GitOpsInfoDto `json:"spec"` -} diff --git a/harness/nextgen/model_git_ops_provider_response_dto.go b/harness/nextgen/model_git_ops_provider_response_dto.go deleted file mode 100644 index d120373f..00000000 --- a/harness/nextgen/model_git_ops_provider_response_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitOpsProviderResponseDto struct { - Name string `json:"name"` - Identifier string `json:"identifier"` - Description string `json:"description,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Spec *GitOpsInfoDto `json:"spec"` -} diff --git a/harness/nextgen/model_gitlab_ssh_credentials_dto.go b/harness/nextgen/model_git_ssh_authentication.go similarity index 70% rename from harness/nextgen/model_gitlab_ssh_credentials_dto.go rename to harness/nextgen/model_git_ssh_authentication.go index 177b096b..e9f67ed2 100644 --- a/harness/nextgen/model_gitlab_ssh_credentials_dto.go +++ b/harness/nextgen/model_git_ssh_authentication.go @@ -9,6 +9,8 @@ */ package nextgen -type GitlabSshCredentialsDto struct { +// This contains details of the Generic Git authentication information used via SSH connections +type GitSshAuthentication struct { + Type_ string `json:"type"` SshKeyRef string `json:"sshKeyRef"` } diff --git a/harness/nextgen/model_git_sync_config.go b/harness/nextgen/model_git_sync_config.go new file mode 100644 index 00000000..8048f9e4 --- /dev/null +++ b/harness/nextgen/model_git_sync_config.go @@ -0,0 +1,23 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// Contains information of Git Sync Config +type GitSyncConfig struct { + Identifier string `json:"identifier,omitempty"` + Name string `json:"name,omitempty"` + ProjectIdentifier string `json:"projectIdentifier,omitempty"` + OrgIdentifier string `json:"orgIdentifier,omitempty"` + GitConnectorRef string `json:"gitConnectorRef,omitempty"` + Repo string `json:"repo,omitempty"` + Branch string `json:"branch,omitempty"` + GitConnectorType string `json:"gitConnectorType"` + GitSyncFolderConfigDTOs []GitSyncFolderConfig `json:"gitSyncFolderConfigDTOs,omitempty"` +} diff --git a/harness/nextgen/model_git_sync_config_dto.go b/harness/nextgen/model_git_sync_config_dto.go deleted file mode 100644 index 175d8e45..00000000 --- a/harness/nextgen/model_git_sync_config_dto.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitSyncConfigDto struct { - Identifier string `json:"identifier,omitempty"` - Name string `json:"name,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - GitConnectorRef string `json:"gitConnectorRef,omitempty"` - Repo string `json:"repo,omitempty"` - Branch string `json:"branch,omitempty"` - GitConnectorType string `json:"gitConnectorType"` - GitSyncFolderConfigDTOs []GitSyncFolderConfigDto `json:"gitSyncFolderConfigDTOs,omitempty"` -} diff --git a/harness/nextgen/model_git_sync_entity_dto.go b/harness/nextgen/model_git_sync_entity.go similarity index 93% rename from harness/nextgen/model_git_sync_entity_dto.go rename to harness/nextgen/model_git_sync_entity.go index b29b1844..e0fac3eb 100644 --- a/harness/nextgen/model_git_sync_entity_dto.go +++ b/harness/nextgen/model_git_sync_entity.go @@ -9,7 +9,8 @@ */ package nextgen -type GitSyncEntityDto struct { +// Contains information of Git Sync Entity +type GitSyncEntity struct { EntityName string `json:"entityName,omitempty"` EntityType string `json:"entityType,omitempty"` EntityIdentifier string `json:"entityIdentifier,omitempty"` diff --git a/harness/nextgen/model_account_resources_dto.go b/harness/nextgen/model_git_sync_entity_list.go similarity index 56% rename from harness/nextgen/model_account_resources_dto.go rename to harness/nextgen/model_git_sync_entity_list.go index bfc66b52..9f3a8c37 100644 --- a/harness/nextgen/model_account_resources_dto.go +++ b/harness/nextgen/model_git_sync_entity_list.go @@ -9,9 +9,9 @@ */ package nextgen -type AccountResourcesDto struct { - ConnectorsCount int64 `json:"connectorsCount,omitempty"` - SecretsCount int64 `json:"secretsCount,omitempty"` - DelegatesCount int64 `json:"delegatesCount,omitempty"` - TemplatesCount int64 `json:"templatesCount,omitempty"` +// Contains list of Entities based on Entity Type +type GitSyncEntityList struct { + EntityType string `json:"entityType,omitempty"` + Count int64 `json:"count,omitempty"` + GitSyncEntities []GitSyncEntity `json:"gitSyncEntities,omitempty"` } diff --git a/harness/nextgen/model_git_sync_error.go b/harness/nextgen/model_git_sync_error.go new file mode 100644 index 00000000..5aba0ad4 --- /dev/null +++ b/harness/nextgen/model_git_sync_error.go @@ -0,0 +1,26 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains Git Sync Error Details +type GitSyncError struct { + AccountIdentifier string `json:"accountIdentifier,omitempty"` + RepoUrl string `json:"repoUrl,omitempty"` + RepoId string `json:"repoId,omitempty"` + BranchName string `json:"branchName,omitempty"` + ChangeType string `json:"changeType,omitempty"` + CompleteFilePath string `json:"completeFilePath,omitempty"` + EntityType string `json:"entityType,omitempty"` + FailureReason string `json:"failureReason,omitempty"` + Status string `json:"status,omitempty"` + ErrorType string `json:"errorType,omitempty"` + AdditionalErrorDetails *GitSyncErrorDetails `json:"additionalErrorDetails,omitempty"` + CreatedAt int64 `json:"createdAt,omitempty"` +} diff --git a/harness/nextgen/model_git_sync_error_aggregate_by_commit.go b/harness/nextgen/model_git_sync_error_aggregate_by_commit.go new file mode 100644 index 00000000..aa17ec40 --- /dev/null +++ b/harness/nextgen/model_git_sync_error_aggregate_by_commit.go @@ -0,0 +1,21 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains a list of Git Sync Error details for a particular Commit +type GitSyncErrorAggregateByCommit struct { + GitCommitId string `json:"gitCommitId,omitempty"` + FailedCount int32 `json:"failedCount,omitempty"` + RepoId string `json:"repoId,omitempty"` + BranchName string `json:"branchName,omitempty"` + CommitMessage string `json:"commitMessage,omitempty"` + CreatedAt int64 `json:"createdAt,omitempty"` + ErrorsForSummaryView []GitSyncError `json:"errorsForSummaryView,omitempty"` +} diff --git a/harness/nextgen/model_git_sync_error_aggregate_by_commit_dto.go b/harness/nextgen/model_git_sync_error_aggregate_by_commit_dto.go deleted file mode 100644 index f4a9f4f9..00000000 --- a/harness/nextgen/model_git_sync_error_aggregate_by_commit_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitSyncErrorAggregateByCommitDto struct { - GitCommitId string `json:"gitCommitId,omitempty"` - FailedCount int32 `json:"failedCount,omitempty"` - RepoId string `json:"repoId,omitempty"` - BranchName string `json:"branchName,omitempty"` - CommitMessage string `json:"commitMessage,omitempty"` - CreatedAt int64 `json:"createdAt,omitempty"` - ErrorsForSummaryView []GitSyncErrorDto `json:"errorsForSummaryView,omitempty"` -} diff --git a/harness/nextgen/model_git_sync_error_count_dto.go b/harness/nextgen/model_git_sync_error_count.go similarity index 81% rename from harness/nextgen/model_git_sync_error_count_dto.go rename to harness/nextgen/model_git_sync_error_count.go index 92369d8d..0181b1a6 100644 --- a/harness/nextgen/model_git_sync_error_count_dto.go +++ b/harness/nextgen/model_git_sync_error_count.go @@ -9,7 +9,8 @@ */ package nextgen -type GitSyncErrorCountDto struct { +// This contains the count of all Git To Harness errors and connectivity errors +type GitSyncErrorCount struct { GitToHarnessErrorCount int64 `json:"gitToHarnessErrorCount,omitempty"` ConnectivityErrorCount int64 `json:"connectivityErrorCount,omitempty"` } diff --git a/harness/nextgen/model_git_sync_error_details.go b/harness/nextgen/model_git_sync_error_details.go new file mode 100644 index 00000000..4d2c768d --- /dev/null +++ b/harness/nextgen/model_git_sync_error_details.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains Git Sync error details specific to Error Type +type GitSyncErrorDetails struct { +} diff --git a/harness/nextgen/model_git_sync_error_details_dto.go b/harness/nextgen/model_git_sync_error_details_dto.go deleted file mode 100644 index a7c4e3fb..00000000 --- a/harness/nextgen/model_git_sync_error_details_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitSyncErrorDetailsDto struct { -} diff --git a/harness/nextgen/model_git_sync_error_dto.go b/harness/nextgen/model_git_sync_error_dto.go deleted file mode 100644 index 3a351c26..00000000 --- a/harness/nextgen/model_git_sync_error_dto.go +++ /dev/null @@ -1,25 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitSyncErrorDto struct { - AccountIdentifier string `json:"accountIdentifier,omitempty"` - RepoUrl string `json:"repoUrl,omitempty"` - RepoId string `json:"repoId,omitempty"` - BranchName string `json:"branchName,omitempty"` - ChangeType string `json:"changeType,omitempty"` - CompleteFilePath string `json:"completeFilePath,omitempty"` - EntityType string `json:"entityType,omitempty"` - FailureReason string `json:"failureReason,omitempty"` - Status string `json:"status,omitempty"` - ErrorType string `json:"errorType,omitempty"` - AdditionalErrorDetails *GitSyncErrorDetailsDto `json:"additionalErrorDetails,omitempty"` - CreatedAt int64 `json:"createdAt,omitempty"` -} diff --git a/harness/nextgen/model_git_sync_folder_config_dto.go b/harness/nextgen/model_git_sync_folder_config.go similarity index 88% rename from harness/nextgen/model_git_sync_folder_config_dto.go rename to harness/nextgen/model_git_sync_folder_config.go index b7ae4310..f6c02254 100644 --- a/harness/nextgen/model_git_sync_folder_config_dto.go +++ b/harness/nextgen/model_git_sync_folder_config.go @@ -9,7 +9,8 @@ */ package nextgen -type GitSyncFolderConfigDto struct { +// This contains details of Root Folder +type GitSyncFolderConfig struct { RootFolder string `json:"rootFolder,omitempty"` IsDefault bool `json:"isDefault,omitempty"` Identifier string `json:"identifier,omitempty"` diff --git a/harness/nextgen/model_git_sync_repo_files.go b/harness/nextgen/model_git_sync_repo_files.go new file mode 100644 index 00000000..afca2c13 --- /dev/null +++ b/harness/nextgen/model_git_sync_repo_files.go @@ -0,0 +1,16 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains a list of Entities with specific Git Sync Config Id +type GitSyncRepoFiles struct { + GitSyncConfigIdentifier string `json:"gitSyncConfigIdentifier,omitempty"` + GitSyncEntityLists []GitSyncEntityList `json:"gitSyncEntityLists,omitempty"` +} diff --git a/harness/nextgen/model_git_sync_repo_files_dto.go b/harness/nextgen/model_git_sync_repo_files_dto.go deleted file mode 100644 index a85f12f0..00000000 --- a/harness/nextgen/model_git_sync_repo_files_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitSyncRepoFilesDto struct { - GitSyncConfigIdentifier string `json:"gitSyncConfigIdentifier,omitempty"` - GitSyncEntityLists []GitSyncEntityListDto `json:"gitSyncEntityLists,omitempty"` -} diff --git a/harness/nextgen/model_http_helm_authentication_dto.go b/harness/nextgen/model_git_sync_repo_files_list.go similarity index 59% rename from harness/nextgen/model_http_helm_authentication_dto.go rename to harness/nextgen/model_git_sync_repo_files_list.go index 7d46cd5d..3e29ee89 100644 --- a/harness/nextgen/model_http_helm_authentication_dto.go +++ b/harness/nextgen/model_git_sync_repo_files_list.go @@ -9,12 +9,8 @@ */ package nextgen -import ( - "encoding/json" -) - -type HttpHelmAuthenticationDto struct { - Type_ string `json:"type"` - UsernamePassword *HttpHelmUsernamePasswordDto `json:"-"` - Spec json.RawMessage `json:"spec,omitempty"` +// This contains a list of Repo Files with a specific ModuleType +type GitSyncRepoFilesList struct { + ModuleType string `json:"moduleType,omitempty"` + GitSyncRepoFilesList []GitSyncRepoFiles `json:"gitSyncRepoFilesList,omitempty"` } diff --git a/harness/nextgen/model_git_sync_repo_files_list_dto.go b/harness/nextgen/model_git_sync_repo_files_list_dto.go deleted file mode 100644 index 01cd179a..00000000 --- a/harness/nextgen/model_git_sync_repo_files_list_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitSyncRepoFilesListDto struct { - ModuleType string `json:"moduleType,omitempty"` - GitSyncRepoFilesList []GitSyncRepoFilesDto `json:"gitSyncRepoFilesList,omitempty"` -} diff --git a/harness/nextgen/model_git_sync_settings_dto.go b/harness/nextgen/model_git_sync_settings.go similarity index 88% rename from harness/nextgen/model_git_sync_settings_dto.go rename to harness/nextgen/model_git_sync_settings.go index c28796ea..6ef2a339 100644 --- a/harness/nextgen/model_git_sync_settings_dto.go +++ b/harness/nextgen/model_git_sync_settings.go @@ -9,7 +9,8 @@ */ package nextgen -type GitSyncSettingsDto struct { +// This contains details of Git Sync Settings +type GitSyncSettings struct { AccountIdentifier string `json:"accountIdentifier"` ProjectIdentifier string `json:"projectIdentifier"` OrganizationIdentifier string `json:"organizationIdentifier"` diff --git a/harness/nextgen/model_github_api_access.go b/harness/nextgen/model_github_api_access.go new file mode 100644 index 00000000..a3a6c839 --- /dev/null +++ b/harness/nextgen/model_github_api_access.go @@ -0,0 +1,20 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import "encoding/json" + +// This contains details of the information needed for Github API access +type GithubApiAccess struct { + Type_ GithubApiAccessType `json:"type"` + Spec json.RawMessage `json:"spec,omitempty"` + GithubApp *GithubAppSpec `json:"-"` + Token *GithubTokenSpecDto `json:"-"` +} diff --git a/harness/nextgen/model_github_api_access_dto.go b/harness/nextgen/model_github_api_access_dto.go deleted file mode 100644 index 36e991f3..00000000 --- a/harness/nextgen/model_github_api_access_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GithubApiAccessDto struct { - Type_ string `json:"type"` - Spec *GithubApiAccessSpecDto `json:"spec,omitempty"` -} diff --git a/harness/nextgen/model_github_api_access_serializer.go b/harness/nextgen/model_github_api_access_serializer.go new file mode 100644 index 00000000..36a7cce0 --- /dev/null +++ b/harness/nextgen/model_github_api_access_serializer.go @@ -0,0 +1,57 @@ +package nextgen + +import ( + "encoding/json" + "fmt" +) + +func (a *GithubApiAccess) UnmarshalJSON(data []byte) error { + + type Alias GithubApiAccess + + aux := &struct { + *Alias + }{ + Alias: (*Alias)(a), + } + + err := json.Unmarshal(data, &aux) + if err != nil { + return err + } + + switch a.Type_ { + case GithubApiAccessTypes.GithubApp: + err = json.Unmarshal(aux.Spec, &a.GithubApp) + case GithubApiAccessTypes.Token: + err = json.Unmarshal(aux.Spec, &a.Token) + default: + panic(fmt.Sprintf("unknown github auth method type %s", a.Type_)) + } + + return err +} + +func (a *GithubApiAccess) MarshalJSON() ([]byte, error) { + type Alias GithubApiAccess + + var spec []byte + var err error + + switch a.Type_ { + case GithubApiAccessTypes.GithubApp: + spec, err = json.Marshal(a.GithubApp) + case GithubApiAccessTypes.Token: + spec, err = json.Marshal(a.Token) + default: + panic(fmt.Sprintf("unknown github auth method type %s", a.Type_)) + } + + if err != nil { + return nil, err + } + + a.Spec = json.RawMessage(spec) + + return json.Marshal((*Alias)(a)) +} diff --git a/harness/nextgen/model_github_api_access_spec.go b/harness/nextgen/model_github_api_access_spec.go new file mode 100644 index 00000000..dde31171 --- /dev/null +++ b/harness/nextgen/model_github_api_access_spec.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the information such as references of username and password needed for Github API access +type GithubApiAccessSpec struct { +} diff --git a/harness/nextgen/model_github_api_access_spec_dto.go b/harness/nextgen/model_github_api_access_spec_dto.go deleted file mode 100644 index 335d7e20..00000000 --- a/harness/nextgen/model_github_api_access_spec_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GithubApiAccessSpecDto struct { -} diff --git a/harness/nextgen/model_github_app_spec_dto.go b/harness/nextgen/model_github_app_spec.go similarity index 79% rename from harness/nextgen/model_github_app_spec_dto.go rename to harness/nextgen/model_github_app_spec.go index 98958fb2..0183e18b 100644 --- a/harness/nextgen/model_github_app_spec_dto.go +++ b/harness/nextgen/model_github_app_spec.go @@ -9,7 +9,8 @@ */ package nextgen -type GithubAppSpecDto struct { +// This contains details of the Github API access credentials Specs such as references of private key +type GithubAppSpec struct { InstallationId string `json:"installationId"` ApplicationId string `json:"applicationId"` PrivateKeyRef string `json:"privateKeyRef"` diff --git a/harness/nextgen/model_github_authentication.go b/harness/nextgen/model_github_authentication.go new file mode 100644 index 00000000..ed77696d --- /dev/null +++ b/harness/nextgen/model_github_authentication.go @@ -0,0 +1,20 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import "encoding/json" + +// This contains details of the information needed for Github access +type GithubAuthentication struct { + Type_ GitAuthType `json:"type"` + Spec json.RawMessage `json:"spec"` + Http *GithubHttpCredentials `json:"-"` + Ssh *GithubSshCredentials `json:"-"` +} diff --git a/harness/nextgen/model_github_authentication_dto.go b/harness/nextgen/model_github_authentication_dto.go deleted file mode 100644 index c9a5085a..00000000 --- a/harness/nextgen/model_github_authentication_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GithubAuthenticationDto struct { - Type_ string `json:"type"` - Spec *GithubCredentialsDto `json:"spec"` -} diff --git a/harness/nextgen/model_github_authentication_serializer.go b/harness/nextgen/model_github_authentication_serializer.go new file mode 100644 index 00000000..864dc383 --- /dev/null +++ b/harness/nextgen/model_github_authentication_serializer.go @@ -0,0 +1,57 @@ +package nextgen + +import ( + "encoding/json" + "fmt" +) + +func (a *GithubAuthentication) UnmarshalJSON(data []byte) error { + + type Alias GithubAuthentication + + aux := &struct { + *Alias + }{ + Alias: (*Alias)(a), + } + + err := json.Unmarshal(data, &aux) + if err != nil { + return err + } + + switch a.Type_ { + case GitAuthTypes.Http: + err = json.Unmarshal(aux.Spec, &a.Http) + case GitAuthTypes.Ssh: + err = json.Unmarshal(aux.Spec, &a.Ssh) + default: + panic(fmt.Sprintf("unknown github auth method type %s", a.Type_)) + } + + return err +} + +func (a *GithubAuthentication) MarshalJSON() ([]byte, error) { + type Alias GithubAuthentication + + var spec []byte + var err error + + switch a.Type_ { + case GitAuthTypes.Http: + spec, err = json.Marshal(a.Http) + case GitAuthTypes.Ssh: + spec, err = json.Marshal(a.Ssh) + default: + panic(fmt.Sprintf("unknown github auth method type %s", a.Type_)) + } + + if err != nil { + return nil, err + } + + a.Spec = json.RawMessage(spec) + + return json.Marshal((*Alias)(a)) +} diff --git a/harness/nextgen/model_github_connector.go b/harness/nextgen/model_github_connector.go new file mode 100644 index 00000000..527df2fe --- /dev/null +++ b/harness/nextgen/model_github_connector.go @@ -0,0 +1,21 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of Github connectors +type GithubConnector struct { + Url string `json:"url"` + ValidationRepo string `json:"validationRepo,omitempty"` + Authentication *GithubAuthentication `json:"authentication"` + ApiAccess *GithubApiAccess `json:"apiAccess,omitempty"` + DelegateSelectors []string `json:"delegateSelectors,omitempty"` + ExecuteOnDelegate bool `json:"executeOnDelegate,omitempty"` + Type_ GitConnectorType `json:"type"` +} diff --git a/harness/nextgen/model_github_connector_dto.go b/harness/nextgen/model_github_connector_dto.go deleted file mode 100644 index 32d325e3..00000000 --- a/harness/nextgen/model_github_connector_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GithubConnectorDto struct { - Url string `json:"url"` - ValidationRepo string `json:"validationRepo,omitempty"` - Authentication *GithubAuthenticationDto `json:"authentication"` - ApiAccess *GithubApiAccessDto `json:"apiAccess,omitempty"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` - ExecuteOnManager bool `json:"executeOnManager,omitempty"` - Type_ string `json:"type"` -} diff --git a/harness/nextgen/model_artifactory_auth_credentials_dto.go b/harness/nextgen/model_github_credentials.go similarity index 79% rename from harness/nextgen/model_artifactory_auth_credentials_dto.go rename to harness/nextgen/model_github_credentials.go index 84333f37..f1033656 100644 --- a/harness/nextgen/model_artifactory_auth_credentials_dto.go +++ b/harness/nextgen/model_github_credentials.go @@ -9,5 +9,6 @@ */ package nextgen -type ArtifactoryAuthCredentialsDto struct { +// This is a interface for details of the Github credentials +type GithubCredentials struct { } diff --git a/harness/nextgen/model_github_credentials_dto.go b/harness/nextgen/model_github_credentials_dto.go deleted file mode 100644 index 7460df4b..00000000 --- a/harness/nextgen/model_github_credentials_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GithubCredentialsDto struct { -} diff --git a/harness/nextgen/model_artifactory_authentication_dto.go b/harness/nextgen/model_github_http_credentials.go similarity index 54% rename from harness/nextgen/model_artifactory_authentication_dto.go rename to harness/nextgen/model_github_http_credentials.go index 179d01ea..98b34ecc 100644 --- a/harness/nextgen/model_artifactory_authentication_dto.go +++ b/harness/nextgen/model_github_http_credentials.go @@ -9,12 +9,11 @@ */ package nextgen -import ( - "encoding/json" -) +import "encoding/json" -type ArtifactoryAuthenticationDto struct { - Type_ string `json:"type"` - UsernamePassword *ArtifactoryUsernamePasswordAuthDto `json:"-"` - Spec json.RawMessage `json:"spec,omitempty"` +// This contains details of the Github credentials used via HTTP connections +type GithubHttpCredentials struct { + Type_ GithubHttpCredentialType `json:"type"` + Spec json.RawMessage `json:"spec"` + UsernameToken *GithubUsernameToken `json:"-"` } diff --git a/harness/nextgen/model_github_http_credentials_dto.go b/harness/nextgen/model_github_http_credentials_dto.go deleted file mode 100644 index daaf0a32..00000000 --- a/harness/nextgen/model_github_http_credentials_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GithubHttpCredentialsDto struct { - Type_ string `json:"type"` - Spec *GithubHttpCredentialsSpecDto `json:"spec"` -} diff --git a/harness/nextgen/model_github_http_credentials_serializer.go b/harness/nextgen/model_github_http_credentials_serializer.go new file mode 100644 index 00000000..849ebbee --- /dev/null +++ b/harness/nextgen/model_github_http_credentials_serializer.go @@ -0,0 +1,53 @@ +package nextgen + +import ( + "encoding/json" + "fmt" +) + +func (a *GithubHttpCredentials) UnmarshalJSON(data []byte) error { + + type Alias GithubHttpCredentials + + aux := &struct { + *Alias + }{ + Alias: (*Alias)(a), + } + + err := json.Unmarshal(data, &aux) + if err != nil { + return err + } + + switch a.Type_ { + case GithubHttpCredentialTypes.UsernameToken: + err = json.Unmarshal(aux.Spec, &a.UsernameToken) + default: + panic(fmt.Sprintf("unknown http credentials method type %s", a.Type_)) + } + + return err +} + +func (a *GithubHttpCredentials) MarshalJSON() ([]byte, error) { + type Alias GithubHttpCredentials + + var spec []byte + var err error + + switch a.Type_ { + case GithubHttpCredentialTypes.UsernameToken: + spec, err = json.Marshal(a.UsernameToken) + default: + panic(fmt.Sprintf("unknown git auth method type %s", a.Type_)) + } + + if err != nil { + return nil, err + } + + a.Spec = json.RawMessage(spec) + + return json.Marshal((*Alias)(a)) +} diff --git a/harness/nextgen/model_github_http_credentials_spec.go b/harness/nextgen/model_github_http_credentials_spec.go new file mode 100644 index 00000000..61681aae --- /dev/null +++ b/harness/nextgen/model_github_http_credentials_spec.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This is a interface for details of the Github credentials Specs such as references of username and password +type GithubHttpCredentialsSpec struct { +} diff --git a/harness/nextgen/model_github_http_credentials_spec_dto.go b/harness/nextgen/model_github_http_credentials_spec_dto.go deleted file mode 100644 index b8d63e2f..00000000 --- a/harness/nextgen/model_github_http_credentials_spec_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GithubHttpCredentialsSpecDto struct { -} diff --git a/harness/nextgen/model_bitbucket_ssh_credentials_dto.go b/harness/nextgen/model_github_ssh_credentials.go similarity index 78% rename from harness/nextgen/model_bitbucket_ssh_credentials_dto.go rename to harness/nextgen/model_github_ssh_credentials.go index 6d01ed09..19e9c2f7 100644 --- a/harness/nextgen/model_bitbucket_ssh_credentials_dto.go +++ b/harness/nextgen/model_github_ssh_credentials.go @@ -9,6 +9,7 @@ */ package nextgen -type BitbucketSshCredentialsDto struct { +// This contains details of the Github credentials used via SSH connections +type GithubSshCredentials struct { SshKeyRef string `json:"sshKeyRef"` } diff --git a/harness/nextgen/model_gitlab_token_spec_dto.go b/harness/nextgen/model_github_token_spec.go similarity index 74% rename from harness/nextgen/model_gitlab_token_spec_dto.go rename to harness/nextgen/model_github_token_spec.go index d4e42a98..53705d46 100644 --- a/harness/nextgen/model_gitlab_token_spec_dto.go +++ b/harness/nextgen/model_github_token_spec.go @@ -9,6 +9,7 @@ */ package nextgen -type GitlabTokenSpecDto struct { +// This contains details of the information such as references of token needed for Github API access +type GithubTokenSpec struct { TokenRef string `json:"tokenRef"` } diff --git a/harness/nextgen/model_github_username_password.go b/harness/nextgen/model_github_username_password.go new file mode 100644 index 00000000..bfc1f70b --- /dev/null +++ b/harness/nextgen/model_github_username_password.go @@ -0,0 +1,17 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the Github credentials Specs such as references of username and password +type GithubUsernamePassword struct { + Username string `json:"username,omitempty"` + UsernameRef string `json:"usernameRef,omitempty"` + PasswordRef string `json:"passwordRef"` +} diff --git a/harness/nextgen/model_github_username_token_dto.go b/harness/nextgen/model_github_username_token.go similarity index 78% rename from harness/nextgen/model_github_username_token_dto.go rename to harness/nextgen/model_github_username_token.go index cd0367c7..736cf3a6 100644 --- a/harness/nextgen/model_github_username_token_dto.go +++ b/harness/nextgen/model_github_username_token.go @@ -9,7 +9,8 @@ */ package nextgen -type GithubUsernameTokenDto struct { +// This contains details of the Github credentials Specs such as references of username and token +type GithubUsernameToken struct { Username string `json:"username,omitempty"` UsernameRef string `json:"usernameRef,omitempty"` TokenRef string `json:"tokenRef"` diff --git a/harness/nextgen/model_github_webhook_events.go b/harness/nextgen/model_github_webhook_events.go deleted file mode 100644 index 256dbbd3..00000000 --- a/harness/nextgen/model_github_webhook_events.go +++ /dev/null @@ -1,25 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GithubWebhookEvents struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - ParserForType *ParserGithubWebhookEvents `json:"parserForType,omitempty"` - DefaultInstanceForType *GithubWebhookEvents `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - EventsList []string `json:"eventsList,omitempty"` - EventsCount int32 `json:"eventsCount,omitempty"` - EventsValueList []int32 `json:"eventsValueList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_github_webhook_events_or_builder.go b/harness/nextgen/model_github_webhook_events_or_builder.go deleted file mode 100644 index dec9ea23..00000000 --- a/harness/nextgen/model_github_webhook_events_or_builder.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GithubWebhookEventsOrBuilder struct { - EventsList []string `json:"eventsList,omitempty"` - EventsCount int32 `json:"eventsCount,omitempty"` - EventsValueList []int32 `json:"eventsValueList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_gcp_connector_credential_dto.go b/harness/nextgen/model_gitlab_api_access.go similarity index 58% rename from harness/nextgen/model_gcp_connector_credential_dto.go rename to harness/nextgen/model_gitlab_api_access.go index c182b94f..d59d22ea 100644 --- a/harness/nextgen/model_gcp_connector_credential_dto.go +++ b/harness/nextgen/model_gitlab_api_access.go @@ -9,12 +9,11 @@ */ package nextgen -import ( - "encoding/json" -) +import "encoding/json" -type GcpConnectorCredentialDto struct { - Type_ string `json:"type"` - ManualConfig *GcpManualDetailsDto `json:"-"` - Spec json.RawMessage `json:"spec,omitempty"` +// This contains details of the information needed for Gitlab API access +type GitlabApiAccess struct { + Type_ GitlabApiAuthType `json:"type"` + Token *GitlabTokenSpec `json:"-"` + Spec json.RawMessage `json:"spec,omitempty"` } diff --git a/harness/nextgen/model_gitlab_api_access_dto.go b/harness/nextgen/model_gitlab_api_access_dto.go deleted file mode 100644 index c123541f..00000000 --- a/harness/nextgen/model_gitlab_api_access_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitlabApiAccessDto struct { - Type_ string `json:"type"` - Spec *GitlabApiAccessSpecDto `json:"spec,omitempty"` -} diff --git a/harness/nextgen/model_gitlab_api_access_serializer.go b/harness/nextgen/model_gitlab_api_access_serializer.go new file mode 100644 index 00000000..dc6fc5a9 --- /dev/null +++ b/harness/nextgen/model_gitlab_api_access_serializer.go @@ -0,0 +1,53 @@ +package nextgen + +import ( + "encoding/json" + "fmt" +) + +func (a *GitlabApiAccess) UnmarshalJSON(data []byte) error { + + type Alias GitlabApiAccess + + aux := &struct { + *Alias + }{ + Alias: (*Alias)(a), + } + + err := json.Unmarshal(data, &aux) + if err != nil { + return err + } + + switch a.Type_ { + case GitlabApiAuthTypes.Token: + err = json.Unmarshal(aux.Spec, &a.Token) + default: + panic(fmt.Sprintf("unknown gitlab auth method type %s", a.Type_)) + } + + return err +} + +func (a *GitlabApiAccess) MarshalJSON() ([]byte, error) { + type Alias GitlabApiAccess + + var spec []byte + var err error + + switch a.Type_ { + case GitlabApiAuthTypes.Token: + spec, err = json.Marshal(a.Token) + default: + panic(fmt.Sprintf("unknown gitlab auth method type %s", a.Type_)) + } + + if err != nil { + return nil, err + } + + a.Spec = json.RawMessage(spec) + + return json.Marshal((*Alias)(a)) +} diff --git a/harness/nextgen/model_gitlab_api_access_spec.go b/harness/nextgen/model_gitlab_api_access_spec.go new file mode 100644 index 00000000..8659e636 --- /dev/null +++ b/harness/nextgen/model_gitlab_api_access_spec.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the information such as references of username and password needed for Gitlab API access +type GitlabApiAccessSpec struct { +} diff --git a/harness/nextgen/model_gitlab_api_access_spec_dto.go b/harness/nextgen/model_gitlab_api_access_spec_dto.go deleted file mode 100644 index 9d58bc31..00000000 --- a/harness/nextgen/model_gitlab_api_access_spec_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitlabApiAccessSpecDto struct { -} diff --git a/harness/nextgen/model_gitlab_authentication.go b/harness/nextgen/model_gitlab_authentication.go new file mode 100644 index 00000000..08deff1b --- /dev/null +++ b/harness/nextgen/model_gitlab_authentication.go @@ -0,0 +1,20 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import "encoding/json" + +// This contains details of the information needed for Gitlab access +type GitlabAuthentication struct { + Type_ GitAuthType `json:"type"` + Http *GitlabHttpCredentials `json:"-"` + Ssh *GitlabSshCredentials `json:"-"` + Spec json.RawMessage `json:"spec"` +} diff --git a/harness/nextgen/model_gitlab_authentication_dto.go b/harness/nextgen/model_gitlab_authentication_dto.go deleted file mode 100644 index 2494109f..00000000 --- a/harness/nextgen/model_gitlab_authentication_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitlabAuthenticationDto struct { - Type_ string `json:"type"` - Spec *GitlabCredentialsDto `json:"spec"` -} diff --git a/harness/nextgen/model_gitlab_authentication_serializer.go b/harness/nextgen/model_gitlab_authentication_serializer.go new file mode 100644 index 00000000..4cc27403 --- /dev/null +++ b/harness/nextgen/model_gitlab_authentication_serializer.go @@ -0,0 +1,57 @@ +package nextgen + +import ( + "encoding/json" + "fmt" +) + +func (a *GitlabAuthentication) UnmarshalJSON(data []byte) error { + + type Alias GitlabAuthentication + + aux := &struct { + *Alias + }{ + Alias: (*Alias)(a), + } + + err := json.Unmarshal(data, &aux) + if err != nil { + return err + } + + switch a.Type_ { + case GitAuthTypes.Http: + err = json.Unmarshal(aux.Spec, &a.Http) + case GitAuthTypes.Ssh: + err = json.Unmarshal(aux.Spec, &a.Ssh) + default: + panic(fmt.Sprintf("unknown gitlab auth method type %s", a.Type_)) + } + + return err +} + +func (a *GitlabAuthentication) MarshalJSON() ([]byte, error) { + type Alias GitlabAuthentication + + var spec []byte + var err error + + switch a.Type_ { + case GitAuthTypes.Http: + spec, err = json.Marshal(a.Http) + case GitAuthTypes.Ssh: + spec, err = json.Marshal(a.Ssh) + default: + panic(fmt.Sprintf("unknown gitlab auth method type %s", a.Type_)) + } + + if err != nil { + return nil, err + } + + a.Spec = json.RawMessage(spec) + + return json.Marshal((*Alias)(a)) +} diff --git a/harness/nextgen/model_gitlab_connector.go b/harness/nextgen/model_gitlab_connector.go new file mode 100644 index 00000000..362decb8 --- /dev/null +++ b/harness/nextgen/model_gitlab_connector.go @@ -0,0 +1,20 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of Gitlab connectors +type GitlabConnector struct { + Url string `json:"url"` + ValidationRepo string `json:"validationRepo,omitempty"` + Authentication *GitlabAuthentication `json:"authentication"` + ApiAccess *GitlabApiAccess `json:"apiAccess,omitempty"` + DelegateSelectors []string `json:"delegateSelectors,omitempty"` + Type_ GitConnectorType `json:"type"` +} diff --git a/harness/nextgen/model_gitlab_credentials.go b/harness/nextgen/model_gitlab_credentials.go new file mode 100644 index 00000000..1d6ee3ce --- /dev/null +++ b/harness/nextgen/model_gitlab_credentials.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This is a interface for details of the Gitlab credentials +type GitlabCredentials struct { +} diff --git a/harness/nextgen/model_gitlab_credentials_dto.go b/harness/nextgen/model_gitlab_credentials_dto.go deleted file mode 100644 index f1f44576..00000000 --- a/harness/nextgen/model_gitlab_credentials_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitlabCredentialsDto struct { -} diff --git a/harness/nextgen/model_aws_code_commit_connector_dto.go b/harness/nextgen/model_gitlab_http_credentials.go similarity index 50% rename from harness/nextgen/model_aws_code_commit_connector_dto.go rename to harness/nextgen/model_gitlab_http_credentials.go index c0ea14f9..6b565e5e 100644 --- a/harness/nextgen/model_aws_code_commit_connector_dto.go +++ b/harness/nextgen/model_gitlab_http_credentials.go @@ -9,9 +9,12 @@ */ package nextgen -type AwsCodeCommitConnectorDto struct { - Url string `json:"url"` - Authentication *AwsCodeCommitAuthenticationDto `json:"authentication"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` - Type_ string `json:"type"` +import "encoding/json" + +// This contains details of the Gitlab credentials used via HTTP connections +type GitlabHttpCredentials struct { + Type_ GitlabHttpCredentialType `json:"type"` + UsernamePassword *GitlabUsernamePassword `json:"-"` + UsernameToken *GitlabUsernameToken `json:"-"` + Spec json.RawMessage `json:"spec"` } diff --git a/harness/nextgen/model_gitlab_http_credentials_dto.go b/harness/nextgen/model_gitlab_http_credentials_dto.go deleted file mode 100644 index 5356ca86..00000000 --- a/harness/nextgen/model_gitlab_http_credentials_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitlabHttpCredentialsDto struct { - Type_ string `json:"type"` - Spec *GitlabHttpCredentialsSpecDto `json:"spec"` -} diff --git a/harness/nextgen/model_gitlab_http_credentials_serializer.go b/harness/nextgen/model_gitlab_http_credentials_serializer.go new file mode 100644 index 00000000..9ba29897 --- /dev/null +++ b/harness/nextgen/model_gitlab_http_credentials_serializer.go @@ -0,0 +1,57 @@ +package nextgen + +import ( + "encoding/json" + "fmt" +) + +func (a *GitlabHttpCredentials) UnmarshalJSON(data []byte) error { + + type Alias GitlabHttpCredentials + + aux := &struct { + *Alias + }{ + Alias: (*Alias)(a), + } + + err := json.Unmarshal(data, &aux) + if err != nil { + return err + } + + switch a.Type_ { + case GitlabHttpCredentialTypes.UsernamePassword: + err = json.Unmarshal(aux.Spec, &a.UsernamePassword) + case GitlabHttpCredentialTypes.UsernameToken: + err = json.Unmarshal(aux.Spec, &a.UsernameToken) + default: + panic(fmt.Sprintf("unknown gitlab http auth type %s", a.Type_)) + } + + return err +} + +func (a *GitlabHttpCredentials) MarshalJSON() ([]byte, error) { + type Alias GitlabHttpCredentials + + var spec []byte + var err error + + switch a.Type_ { + case GitlabHttpCredentialTypes.UsernamePassword: + spec, err = json.Marshal(a.UsernamePassword) + case GitlabHttpCredentialTypes.UsernameToken: + spec, err = json.Marshal(a.UsernameToken) + default: + panic(fmt.Sprintf("unknown gitlab http auth type %s", a.Type_)) + } + + if err != nil { + return nil, err + } + + a.Spec = json.RawMessage(spec) + + return json.Marshal((*Alias)(a)) +} diff --git a/harness/nextgen/model_gitlab_http_credentials_spec.go b/harness/nextgen/model_gitlab_http_credentials_spec.go new file mode 100644 index 00000000..0b16bd0d --- /dev/null +++ b/harness/nextgen/model_gitlab_http_credentials_spec.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This is a interface for details of the Gitlab credentials Specs such as references of username and password +type GitlabHttpCredentialsSpec struct { +} diff --git a/harness/nextgen/model_gitlab_http_credentials_spec_dto.go b/harness/nextgen/model_gitlab_http_credentials_spec_dto.go deleted file mode 100644 index d99227b2..00000000 --- a/harness/nextgen/model_gitlab_http_credentials_spec_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitlabHttpCredentialsSpecDto struct { -} diff --git a/harness/nextgen/model_gitlab_kerberos_dto.go b/harness/nextgen/model_gitlab_kerberos.go similarity index 77% rename from harness/nextgen/model_gitlab_kerberos_dto.go rename to harness/nextgen/model_gitlab_kerberos.go index e45dfe66..5eb3b3c5 100644 --- a/harness/nextgen/model_gitlab_kerberos_dto.go +++ b/harness/nextgen/model_gitlab_kerberos.go @@ -9,6 +9,7 @@ */ package nextgen -type GitlabKerberosDto struct { +// This contains details of the Gitlab credentials Specs such as references of Keberos key +type GitlabKerberos struct { KerberosKeyRef string `json:"kerberosKeyRef"` } diff --git a/harness/nextgen/model_git_ssh_authentication_dto.go b/harness/nextgen/model_gitlab_ssh_credentials.go similarity index 78% rename from harness/nextgen/model_git_ssh_authentication_dto.go rename to harness/nextgen/model_gitlab_ssh_credentials.go index 1fd90ea3..9c56c360 100644 --- a/harness/nextgen/model_git_ssh_authentication_dto.go +++ b/harness/nextgen/model_gitlab_ssh_credentials.go @@ -9,7 +9,7 @@ */ package nextgen -type GitSshAuthenticationDto struct { - Type_ string `json:"-"` +// This contains details of the Gitlab credentials used via SSH connections +type GitlabSshCredentials struct { SshKeyRef string `json:"sshKeyRef"` } diff --git a/harness/nextgen/model_gitlab_token_spec.go b/harness/nextgen/model_gitlab_token_spec.go new file mode 100644 index 00000000..088380a8 --- /dev/null +++ b/harness/nextgen/model_gitlab_token_spec.go @@ -0,0 +1,15 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the information such as references of token needed for Gitlab API access +type GitlabTokenSpec struct { + TokenRef string `json:"tokenRef"` +} diff --git a/harness/nextgen/model_gitlab_username_password.go b/harness/nextgen/model_gitlab_username_password.go new file mode 100644 index 00000000..a8ae2df0 --- /dev/null +++ b/harness/nextgen/model_gitlab_username_password.go @@ -0,0 +1,17 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the Gitlab credentials Specs such as references of username and password +type GitlabUsernamePassword struct { + Username string `json:"username,omitempty"` + UsernameRef string `json:"usernameRef,omitempty"` + PasswordRef string `json:"passwordRef"` +} diff --git a/harness/nextgen/model_gitlab_username_password_dto.go b/harness/nextgen/model_gitlab_username_password_dto.go deleted file mode 100644 index 81ce700e..00000000 --- a/harness/nextgen/model_gitlab_username_password_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitlabUsernamePasswordDto struct { - Username string `json:"username,omitempty"` - UsernameRef string `json:"usernameRef,omitempty"` - PasswordRef string `json:"passwordRef"` -} diff --git a/harness/nextgen/model_gitlab_username_token_dto.go b/harness/nextgen/model_gitlab_username_token.go similarity index 78% rename from harness/nextgen/model_gitlab_username_token_dto.go rename to harness/nextgen/model_gitlab_username_token.go index b2ec9deb..579a7b63 100644 --- a/harness/nextgen/model_gitlab_username_token_dto.go +++ b/harness/nextgen/model_gitlab_username_token.go @@ -9,7 +9,8 @@ */ package nextgen -type GitlabUsernameTokenDto struct { +// This contains details of the Gitlab credentials Specs such as references of username and token +type GitlabUsernameToken struct { Username string `json:"username,omitempty"` UsernameRef string `json:"usernameRef,omitempty"` TokenRef string `json:"tokenRef"` diff --git a/harness/nextgen/model_gitlab_webhook_events.go b/harness/nextgen/model_gitlab_webhook_events.go deleted file mode 100644 index 15b00ba8..00000000 --- a/harness/nextgen/model_gitlab_webhook_events.go +++ /dev/null @@ -1,25 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitlabWebhookEvents struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - ParserForType *ParserGitlabWebhookEvents `json:"parserForType,omitempty"` - DefaultInstanceForType *GitlabWebhookEvents `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - EventsList []string `json:"eventsList,omitempty"` - EventsCount int32 `json:"eventsCount,omitempty"` - EventsValueList []int32 `json:"eventsValueList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_gitlab_webhook_events_or_builder.go b/harness/nextgen/model_gitlab_webhook_events_or_builder.go deleted file mode 100644 index 13b4872a..00000000 --- a/harness/nextgen/model_gitlab_webhook_events_or_builder.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type GitlabWebhookEventsOrBuilder struct { - EventsList []string `json:"eventsList,omitempty"` - EventsCount int32 `json:"eventsCount,omitempty"` - EventsValueList []int32 `json:"eventsValueList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_harness_service_info_ng.go b/harness/nextgen/model_harness_service_info_ng.go deleted file mode 100644 index c0d6135e..00000000 --- a/harness/nextgen/model_harness_service_info_ng.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type HarnessServiceInfoNg struct { - ServiceId string `json:"serviceId,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - EnvId string `json:"envId,omitempty"` - InfraMappingId string `json:"infraMappingId,omitempty"` -} diff --git a/harness/nextgen/model_health_deployment_dashboard.go b/harness/nextgen/model_health_deployment_dashboard.go deleted file mode 100644 index 5024feda..00000000 --- a/harness/nextgen/model_health_deployment_dashboard.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type HealthDeploymentDashboard struct { - HealthDeploymentInfo *HealthDeploymentInfo `json:"healthDeploymentInfo,omitempty"` -} diff --git a/harness/nextgen/model_health_deployment_info.go b/harness/nextgen/model_health_deployment_info.go deleted file mode 100644 index 8b65a396..00000000 --- a/harness/nextgen/model_health_deployment_info.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type HealthDeploymentInfo struct { - Total *TotalDeploymentInfo `json:"total,omitempty"` - Success *DeploymentInfo `json:"success,omitempty"` - Failure *DeploymentInfo `json:"failure,omitempty"` -} diff --git a/harness/nextgen/model_availability_restriction_dto.go b/harness/nextgen/model_http_helm_auth_credentials.go similarity index 81% rename from harness/nextgen/model_availability_restriction_dto.go rename to harness/nextgen/model_http_helm_auth_credentials.go index 5654f2b6..228e0ada 100644 --- a/harness/nextgen/model_availability_restriction_dto.go +++ b/harness/nextgen/model_http_helm_auth_credentials.go @@ -9,6 +9,6 @@ */ package nextgen -type AvailabilityRestrictionDto struct { - Enabled bool `json:"enabled,omitempty"` +// This contains http helm auth credentials +type HttpHelmAuthCredentials struct { } diff --git a/harness/nextgen/model_http_helm_auth_credentials_dto.go b/harness/nextgen/model_http_helm_auth_credentials_dto.go deleted file mode 100644 index 986d9f07..00000000 --- a/harness/nextgen/model_http_helm_auth_credentials_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type HttpHelmAuthCredentialsDto struct { -} diff --git a/harness/nextgen/model_http_helm_authentication.go b/harness/nextgen/model_http_helm_authentication.go new file mode 100644 index 00000000..34631892 --- /dev/null +++ b/harness/nextgen/model_http_helm_authentication.go @@ -0,0 +1,19 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import "encoding/json" + +// This contains http helm authentication details +type HttpHelmAuthentication struct { + Type_ HttpHelmAuthType `json:"type"` + UsernamePassword *HttpHelmUsernamePassword `json:"-"` + Spec json.RawMessage `json:"spec,omitempty"` +} diff --git a/harness/nextgen/model_http_helm_authentication_serializer.go b/harness/nextgen/model_http_helm_authentication_serializer.go index fa92a874..47707271 100644 --- a/harness/nextgen/model_http_helm_authentication_serializer.go +++ b/harness/nextgen/model_http_helm_authentication_serializer.go @@ -5,9 +5,9 @@ import ( "fmt" ) -func (a *HttpHelmAuthenticationDto) UnmarshalJSON(data []byte) error { +func (a *HttpHelmAuthentication) UnmarshalJSON(data []byte) error { - type Alias HttpHelmAuthenticationDto + type Alias HttpHelmAuthentication aux := &struct { *Alias @@ -21,9 +21,9 @@ func (a *HttpHelmAuthenticationDto) UnmarshalJSON(data []byte) error { } switch a.Type_ { - case HttpHelmAuthTypes.UsernamePassword.String(): + case HttpHelmAuthTypes.UsernamePassword: err = json.Unmarshal(aux.Spec, &a.UsernamePassword) - case HttpHelmAuthTypes.Anonymous.String(): + case HttpHelmAuthTypes.Anonymous: // nothing to do default: panic(fmt.Sprintf("unknown helm auth method type %s", a.Type_)) @@ -32,16 +32,16 @@ func (a *HttpHelmAuthenticationDto) UnmarshalJSON(data []byte) error { return err } -func (a *HttpHelmAuthenticationDto) MarshalJSON() ([]byte, error) { - type Alias HttpHelmAuthenticationDto +func (a *HttpHelmAuthentication) MarshalJSON() ([]byte, error) { + type Alias HttpHelmAuthentication var spec []byte var err error switch a.Type_ { - case HttpHelmAuthTypes.UsernamePassword.String(): + case HttpHelmAuthTypes.UsernamePassword: spec, err = json.Marshal(a.UsernamePassword) - case HttpHelmAuthTypes.Anonymous.String(): + case HttpHelmAuthTypes.Anonymous: // nothing to do default: panic(fmt.Sprintf("unknown helm auth method type %s", a.Type_)) diff --git a/harness/nextgen/model_nexus_connector_dto.go b/harness/nextgen/model_http_helm_connector.go similarity index 66% rename from harness/nextgen/model_nexus_connector_dto.go rename to harness/nextgen/model_http_helm_connector.go index 2bab0fd6..a9b9cf8f 100644 --- a/harness/nextgen/model_nexus_connector_dto.go +++ b/harness/nextgen/model_http_helm_connector.go @@ -9,9 +9,9 @@ */ package nextgen -type NexusConnectorDto struct { - NexusServerUrl string `json:"nexusServerUrl"` - Version string `json:"version"` - Auth *NexusAuthenticationDto `json:"auth,omitempty"` +// This contains http helm connector details +type HttpHelmConnector struct { + HelmRepoUrl string `json:"helmRepoUrl"` + Auth *HttpHelmAuthentication `json:"auth,omitempty"` DelegateSelectors []string `json:"delegateSelectors,omitempty"` } diff --git a/harness/nextgen/model_http_helm_connector_dto.go b/harness/nextgen/model_http_helm_connector_dto.go deleted file mode 100644 index 31d2b801..00000000 --- a/harness/nextgen/model_http_helm_connector_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type HttpHelmConnectorDto struct { - HelmRepoUrl string `json:"helmRepoUrl"` - Auth *HttpHelmAuthenticationDto `json:"auth,omitempty"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` -} diff --git a/harness/nextgen/model_artifactory_username_password_auth_dto.go b/harness/nextgen/model_http_helm_username_password.go similarity index 84% rename from harness/nextgen/model_artifactory_username_password_auth_dto.go rename to harness/nextgen/model_http_helm_username_password.go index d65d3c92..2cc149e4 100644 --- a/harness/nextgen/model_artifactory_username_password_auth_dto.go +++ b/harness/nextgen/model_http_helm_username_password.go @@ -9,7 +9,8 @@ */ package nextgen -type ArtifactoryUsernamePasswordAuthDto struct { +// This contains http helm username password details +type HttpHelmUsernamePassword struct { Username string `json:"username,omitempty"` UsernameRef string `json:"usernameRef,omitempty"` PasswordRef string `json:"passwordRef"` diff --git a/harness/nextgen/model_http_helm_username_password_dto.go b/harness/nextgen/model_http_helm_username_password_dto.go deleted file mode 100644 index 2b712b7f..00000000 --- a/harness/nextgen/model_http_helm_username_password_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type HttpHelmUsernamePasswordDto struct { - Username string `json:"username,omitempty"` - UsernameRef string `json:"usernameRef,omitempty"` - PasswordRef string `json:"passwordRef"` -} diff --git a/harness/nextgen/model_infra_execution_summary.go b/harness/nextgen/model_infra_execution_summary.go deleted file mode 100644 index d6b1b142..00000000 --- a/harness/nextgen/model_infra_execution_summary.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type InfraExecutionSummary struct { - Identifier string `json:"identifier,omitempty"` - Name string `json:"name,omitempty"` - Type_ string `json:"type,omitempty"` -} diff --git a/harness/nextgen/model_infrastructure_details.go b/harness/nextgen/model_infrastructure_details.go deleted file mode 100644 index 1d08383b..00000000 --- a/harness/nextgen/model_infrastructure_details.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type InfrastructureDetails struct { - Type_ string `json:"type"` -} diff --git a/harness/nextgen/model_input_set_validator.go b/harness/nextgen/model_input_set_validator.go deleted file mode 100644 index 6558910e..00000000 --- a/harness/nextgen/model_input_set_validator.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type InputSetValidator struct { - ValidatorType string `json:"validatorType,omitempty"` - Parameters string `json:"parameters,omitempty"` -} diff --git a/harness/nextgen/model_instance_count_details_by_env_type_base.go b/harness/nextgen/model_instance_count_details_by_env_type_base.go deleted file mode 100644 index bbe64847..00000000 --- a/harness/nextgen/model_instance_count_details_by_env_type_base.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type InstanceCountDetailsByEnvTypeBase struct { - EnvTypeVsInstanceCountMap map[string]int32 `json:"envTypeVsInstanceCountMap,omitempty"` - NonProdInstances int32 `json:"nonProdInstances,omitempty"` - ProdInstances int32 `json:"prodInstances,omitempty"` - TotalInstances int32 `json:"totalInstances,omitempty"` -} diff --git a/harness/nextgen/model_instance_details_by_build_id.go b/harness/nextgen/model_instance_details_by_build_id.go deleted file mode 100644 index a437ecfa..00000000 --- a/harness/nextgen/model_instance_details_by_build_id.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type InstanceDetailsByBuildId struct { - BuildId string `json:"buildId,omitempty"` - Instances []InstanceDetailsDto `json:"instances,omitempty"` -} diff --git a/harness/nextgen/model_instance_details_dto.go b/harness/nextgen/model_instance_details_dto.go deleted file mode 100644 index 9650ca2a..00000000 --- a/harness/nextgen/model_instance_details_dto.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type InstanceDetailsDto struct { - PodName string `json:"podName,omitempty"` - ArtifactName string `json:"artifactName,omitempty"` - ConnectorRef string `json:"connectorRef,omitempty"` - InfrastructureDetails *InfrastructureDetails `json:"infrastructureDetails,omitempty"` - TerraformInstance string `json:"terraformInstance,omitempty"` - DeployedAt int64 `json:"deployedAt,omitempty"` - DeployedById string `json:"deployedById,omitempty"` - DeployedByName string `json:"deployedByName,omitempty"` - PipelineExecutionName string `json:"pipelineExecutionName,omitempty"` -} diff --git a/harness/nextgen/model_instances_by_build_id_list.go b/harness/nextgen/model_instances_by_build_id_list.go deleted file mode 100644 index 825d96f5..00000000 --- a/harness/nextgen/model_instances_by_build_id_list.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type InstancesByBuildIdList struct { - InstancesByBuildIdList []InstanceDetailsByBuildId `json:"instancesByBuildIdList,omitempty"` -} diff --git a/harness/nextgen/model_invite_dto.go b/harness/nextgen/model_invite.go similarity index 92% rename from harness/nextgen/model_invite_dto.go rename to harness/nextgen/model_invite.go index dfdd05af..b89d6523 100644 --- a/harness/nextgen/model_invite_dto.go +++ b/harness/nextgen/model_invite.go @@ -9,7 +9,8 @@ */ package nextgen -type InviteDto struct { +// This is the view of the Invite entity defined in Harness +type Invite struct { Id string `json:"id,omitempty"` Name string `json:"name,omitempty"` Email string `json:"email,omitempty"` diff --git a/harness/nextgen/model_jira_connector_dto.go b/harness/nextgen/model_jira_connector.go similarity index 89% rename from harness/nextgen/model_jira_connector_dto.go rename to harness/nextgen/model_jira_connector.go index f37432ed..ab16abc6 100644 --- a/harness/nextgen/model_jira_connector_dto.go +++ b/harness/nextgen/model_jira_connector.go @@ -9,7 +9,8 @@ */ package nextgen -type JiraConnectorDto struct { +// This contains details of Jira Connector +type JiraConnector struct { JiraUrl string `json:"jiraUrl"` Username string `json:"username,omitempty"` UsernameRef string `json:"usernameRef,omitempty"` diff --git a/harness/nextgen/model_jira_field_allowed_value_ng.go b/harness/nextgen/model_jira_field_allowed_value_ng.go deleted file mode 100644 index 1d49fc45..00000000 --- a/harness/nextgen/model_jira_field_allowed_value_ng.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type JiraFieldAllowedValueNg struct { - Id string `json:"id,omitempty"` - Name string `json:"name,omitempty"` - Value string `json:"value,omitempty"` -} diff --git a/harness/nextgen/model_jira_field_ng.go b/harness/nextgen/model_jira_field_ng.go deleted file mode 100644 index c0ef1f75..00000000 --- a/harness/nextgen/model_jira_field_ng.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type JiraFieldNg struct { - Key string `json:"key"` - Name string `json:"name"` - Required bool `json:"required,omitempty"` - IsCustom bool `json:"isCustom,omitempty"` - Schema *JiraFieldSchemaNg `json:"schema"` - AllowedValues []JiraFieldAllowedValueNg `json:"allowedValues"` - Custom bool `json:"custom,omitempty"` -} diff --git a/harness/nextgen/model_jira_field_schema_ng.go b/harness/nextgen/model_jira_field_schema_ng.go deleted file mode 100644 index 8bbe4a3f..00000000 --- a/harness/nextgen/model_jira_field_schema_ng.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type JiraFieldSchemaNg struct { - Array bool `json:"array,omitempty"` - TypeStr string `json:"typeStr"` - Type_ string `json:"type"` - CustomType string `json:"customType,omitempty"` -} diff --git a/harness/nextgen/model_jira_issue_create_metadata_ng.go b/harness/nextgen/model_jira_issue_create_metadata_ng.go deleted file mode 100644 index ed1aae94..00000000 --- a/harness/nextgen/model_jira_issue_create_metadata_ng.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type JiraIssueCreateMetadataNg struct { - Projects map[string]JiraProjectNg `json:"projects,omitempty"` -} diff --git a/harness/nextgen/model_jira_issue_type_ng.go b/harness/nextgen/model_jira_issue_type_ng.go deleted file mode 100644 index 799164df..00000000 --- a/harness/nextgen/model_jira_issue_type_ng.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type JiraIssueTypeNg struct { - Id string `json:"id"` - Name string `json:"name"` - Description string `json:"description,omitempty"` - Statuses []JiraStatusNg `json:"statuses"` - Fields map[string]JiraFieldNg `json:"fields"` - SubTask bool `json:"subTask,omitempty"` -} diff --git a/harness/nextgen/model_jira_issue_update_metadata_ng.go b/harness/nextgen/model_jira_issue_update_metadata_ng.go deleted file mode 100644 index 075af829..00000000 --- a/harness/nextgen/model_jira_issue_update_metadata_ng.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type JiraIssueUpdateMetadataNg struct { - Fields map[string]JiraFieldNg `json:"fields"` -} diff --git a/harness/nextgen/model_jira_project_basic_ng.go b/harness/nextgen/model_jira_project_basic_ng.go deleted file mode 100644 index c0af61eb..00000000 --- a/harness/nextgen/model_jira_project_basic_ng.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type JiraProjectBasicNg struct { - Id string `json:"id"` - Key string `json:"key"` - Name string `json:"name"` -} diff --git a/harness/nextgen/model_jira_project_ng.go b/harness/nextgen/model_jira_project_ng.go deleted file mode 100644 index 6eae9e3d..00000000 --- a/harness/nextgen/model_jira_project_ng.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type JiraProjectNg struct { - Id string `json:"id"` - Key string `json:"key"` - Name string `json:"name"` - Issuetypes map[string]JiraIssueTypeNg `json:"issuetypes"` -} diff --git a/harness/nextgen/model_jira_status_category_ng.go b/harness/nextgen/model_jira_status_category_ng.go deleted file mode 100644 index d19748e8..00000000 --- a/harness/nextgen/model_jira_status_category_ng.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type JiraStatusCategoryNg struct { - Id int64 `json:"id"` - Key string `json:"key"` - Name string `json:"name"` -} diff --git a/harness/nextgen/model_json_node.go b/harness/nextgen/model_json_node.go deleted file mode 100644 index 59aa803f..00000000 --- a/harness/nextgen/model_json_node.go +++ /dev/null @@ -1,34 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type JsonNode struct { - Float bool `json:"float,omitempty"` - NodeType string `json:"nodeType,omitempty"` - Number bool `json:"number,omitempty"` - Binary bool `json:"binary,omitempty"` - ValueNode bool `json:"valueNode,omitempty"` - ContainerNode bool `json:"containerNode,omitempty"` - MissingNode bool `json:"missingNode,omitempty"` - Pojo bool `json:"pojo,omitempty"` - IntegralNumber bool `json:"integralNumber,omitempty"` - FloatingPointNumber bool `json:"floatingPointNumber,omitempty"` - Short bool `json:"short,omitempty"` - Int_ bool `json:"int,omitempty"` - Long bool `json:"long,omitempty"` - Double bool `json:"double,omitempty"` - BigDecimal bool `json:"bigDecimal,omitempty"` - BigInteger bool `json:"bigInteger,omitempty"` - Textual bool `json:"textual,omitempty"` - Boolean bool `json:"boolean,omitempty"` - Object bool `json:"object,omitempty"` - Array bool `json:"array,omitempty"` - Null bool `json:"null,omitempty"` -} diff --git a/harness/nextgen/model_k8s_infrastructure_details.go b/harness/nextgen/model_k8s_infrastructure_details.go deleted file mode 100644 index 91cd2458..00000000 --- a/harness/nextgen/model_k8s_infrastructure_details.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type K8sInfrastructureDetails struct { - Type_ string `json:"type"` - Namespace string `json:"namespace,omitempty"` - ReleaseName string `json:"releaseName,omitempty"` -} diff --git a/harness/nextgen/model_kerberos_config_dto.go b/harness/nextgen/model_kerberos_config_dto.go deleted file mode 100644 index ae0a4169..00000000 --- a/harness/nextgen/model_kerberos_config_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type KerberosConfigDto struct { - Type_ string `json:"type"` - Principal string `json:"principal"` - Realm string `json:"realm"` - TgtGenerationMethod string `json:"tgtGenerationMethod,omitempty"` - Spec *TgtGenerationSpecDto `json:"spec,omitempty"` -} diff --git a/harness/nextgen/model_kubernetes_auth.go b/harness/nextgen/model_kubernetes_auth.go new file mode 100644 index 00000000..7ab7c8e3 --- /dev/null +++ b/harness/nextgen/model_kubernetes_auth.go @@ -0,0 +1,22 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import "encoding/json" + +// This contains kubernetes auth details +type KubernetesAuth struct { + OpenIdConnect *KubernetesOpenIdConnect `json:"-"` + ServiceAccount *KubernetesServiceAccount `json:"-"` + UsernamePassword *KubernetesUserNamePassword `json:"-"` + ClientKeyCert *KubernetesClientKeyCert `json:"-"` + Type_ KubernetesAuthType `json:"type"` + Spec json.RawMessage `json:"spec"` +} diff --git a/harness/nextgen/model_active_projects_count_dto.go b/harness/nextgen/model_kubernetes_auth_credential.go similarity index 80% rename from harness/nextgen/model_active_projects_count_dto.go rename to harness/nextgen/model_kubernetes_auth_credential.go index c17fa467..828e599b 100644 --- a/harness/nextgen/model_active_projects_count_dto.go +++ b/harness/nextgen/model_kubernetes_auth_credential.go @@ -9,6 +9,6 @@ */ package nextgen -type ActiveProjectsCountDto struct { - Count int32 `json:"count,omitempty"` +// This contains kubernetes auth credentials +type KubernetesAuthCredential struct { } diff --git a/harness/nextgen/model_kubernetes_auth_credential_dto.go b/harness/nextgen/model_kubernetes_auth_credential_dto.go deleted file mode 100644 index 116851ad..00000000 --- a/harness/nextgen/model_kubernetes_auth_credential_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type KubernetesAuthCredentialDto struct { -} diff --git a/harness/nextgen/model_kubernetes_auth_dto.go b/harness/nextgen/model_kubernetes_auth_dto.go deleted file mode 100644 index ad2e706b..00000000 --- a/harness/nextgen/model_kubernetes_auth_dto.go +++ /dev/null @@ -1,23 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -import ( - "encoding/json" -) - -type KubernetesAuthDto struct { - OpenIdConnect *KubernetesOpenIdConnectDto `json:"-"` - ServiceAccount *KubernetesServiceAccountDto `json:"-"` - UsernamePassword *KubernetesUserNamePasswordDto `json:"-"` - ClientKeyCert *KubernetesClientKeyCertDto `json:"-"` - Type_ string `json:"type"` - Spec json.RawMessage `json:"spec"` -} diff --git a/harness/nextgen/model_kubernetes_auth_serializer.go b/harness/nextgen/model_kubernetes_auth_serializer.go index 716a7692..fcf39cbb 100644 --- a/harness/nextgen/model_kubernetes_auth_serializer.go +++ b/harness/nextgen/model_kubernetes_auth_serializer.go @@ -5,9 +5,9 @@ import ( "fmt" ) -func (a *KubernetesAuthDto) UnmarshalJSON(data []byte) error { +func (a *KubernetesAuth) UnmarshalJSON(data []byte) error { - type Alias KubernetesAuthDto + type Alias KubernetesAuth aux := &struct { *Alias @@ -21,13 +21,13 @@ func (a *KubernetesAuthDto) UnmarshalJSON(data []byte) error { } switch a.Type_ { - case KubernetesAuthMethods.ClientKeyCert.String(): + case KubernetesAuthTypes.ClientKeyCert: err = json.Unmarshal(aux.Spec, &a.ClientKeyCert) - case KubernetesAuthMethods.UsernamePassword.String(): + case KubernetesAuthTypes.UsernamePassword: err = json.Unmarshal(aux.Spec, &a.UsernamePassword) - case KubernetesAuthMethods.ServiceAccount.String(): + case KubernetesAuthTypes.ServiceAccount: err = json.Unmarshal(aux.Spec, &a.ServiceAccount) - case KubernetesAuthMethods.OpenIdConnect.String(): + case KubernetesAuthTypes.OpenIdConnect: err = json.Unmarshal(aux.Spec, &a.OpenIdConnect) default: panic(fmt.Sprintf("unknown kubernetes auth method type %s", a.Type_)) @@ -36,20 +36,20 @@ func (a *KubernetesAuthDto) UnmarshalJSON(data []byte) error { return err } -func (a *KubernetesAuthDto) MarshalJSON() ([]byte, error) { - type Alias KubernetesAuthDto +func (a *KubernetesAuth) MarshalJSON() ([]byte, error) { + type Alias KubernetesAuth var spec []byte var err error switch a.Type_ { - case KubernetesAuthMethods.ClientKeyCert.String(): + case KubernetesAuthTypes.ClientKeyCert: spec, err = json.Marshal(a.ClientKeyCert) - case KubernetesAuthMethods.UsernamePassword.String(): + case KubernetesAuthTypes.UsernamePassword: spec, err = json.Marshal(a.UsernamePassword) - case KubernetesAuthMethods.ServiceAccount.String(): + case KubernetesAuthTypes.ServiceAccount: spec, err = json.Marshal(a.ServiceAccount) - case KubernetesAuthMethods.OpenIdConnect.String(): + case KubernetesAuthTypes.OpenIdConnect: spec, err = json.Marshal(a.OpenIdConnect) default: panic(fmt.Sprintf("unknown kubernetes auth method type %s", a.Type_)) diff --git a/harness/nextgen/model_kubernetes_client_key_cert_dto.go b/harness/nextgen/model_kubernetes_client_key_cert.go similarity index 87% rename from harness/nextgen/model_kubernetes_client_key_cert_dto.go rename to harness/nextgen/model_kubernetes_client_key_cert.go index 2993208c..3200d77b 100644 --- a/harness/nextgen/model_kubernetes_client_key_cert_dto.go +++ b/harness/nextgen/model_kubernetes_client_key_cert.go @@ -9,7 +9,8 @@ */ package nextgen -type KubernetesClientKeyCertDto struct { +// This contains kubernetes client key certificate details +type KubernetesClientKeyCert struct { CaCertRef string `json:"caCertRef,omitempty"` ClientCertRef string `json:"clientCertRef"` ClientKeyRef string `json:"clientKeyRef"` diff --git a/harness/nextgen/model_kubernetes_cluster_config.go b/harness/nextgen/model_kubernetes_cluster_config.go new file mode 100644 index 00000000..f0498127 --- /dev/null +++ b/harness/nextgen/model_kubernetes_cluster_config.go @@ -0,0 +1,16 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains kubernetes cluster config details +type KubernetesClusterConfig struct { + Credential *KubernetesCredential `json:"credential"` + DelegateSelectors []string `json:"delegateSelectors,omitempty"` +} diff --git a/harness/nextgen/model_kubernetes_cluster_config_dto.go b/harness/nextgen/model_kubernetes_cluster_config_dto.go deleted file mode 100644 index 8a79dd2d..00000000 --- a/harness/nextgen/model_kubernetes_cluster_config_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type KubernetesClusterConfigDto struct { - Credential *KubernetesCredentialDto `json:"credential"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` -} diff --git a/harness/nextgen/model_kubernetes_cluster_details.go b/harness/nextgen/model_kubernetes_cluster_details.go new file mode 100644 index 00000000..262525d3 --- /dev/null +++ b/harness/nextgen/model_kubernetes_cluster_details.go @@ -0,0 +1,16 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains kubernetes cluster details +type KubernetesClusterDetails struct { + MasterUrl string `json:"masterUrl"` + Auth *KubernetesAuth `json:"auth"` +} diff --git a/harness/nextgen/model_kubernetes_cluster_details_dto.go b/harness/nextgen/model_kubernetes_cluster_details_dto.go deleted file mode 100644 index ae551fa0..00000000 --- a/harness/nextgen/model_kubernetes_cluster_details_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type KubernetesClusterDetailsDto struct { - MasterUrl string `json:"masterUrl"` - Auth *KubernetesAuthDto `json:"auth"` -} diff --git a/harness/nextgen/model_kubernetes_credential.go b/harness/nextgen/model_kubernetes_credential.go new file mode 100644 index 00000000..7e49c156 --- /dev/null +++ b/harness/nextgen/model_kubernetes_credential.go @@ -0,0 +1,19 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +import "encoding/json" + +// This contains kubernetes credentials details +type KubernetesCredential struct { + ManualConfig *KubernetesClusterDetails `json:"-"` + Type_ KubernetesCredentialType `json:"type"` + Spec json.RawMessage `json:"spec,omitempty"` +} diff --git a/harness/nextgen/model_kubernetes_credential_serializer.go b/harness/nextgen/model_kubernetes_credential_serializer.go index 5ae23367..7db192b8 100644 --- a/harness/nextgen/model_kubernetes_credential_serializer.go +++ b/harness/nextgen/model_kubernetes_credential_serializer.go @@ -5,9 +5,9 @@ import ( "fmt" ) -func (a *KubernetesCredentialDto) UnmarshalJSON(data []byte) error { +func (a *KubernetesCredential) UnmarshalJSON(data []byte) error { - type Alias KubernetesCredentialDto + type Alias KubernetesCredential aux := &struct { *Alias @@ -21,10 +21,10 @@ func (a *KubernetesCredentialDto) UnmarshalJSON(data []byte) error { } switch a.Type_ { - case KubernetesCredentialTypes.InheritFromDelegate.String(): + case KubernetesCredentialTypes.InheritFromDelegate: // do nothing - case KubernetesCredentialTypes.ManualConfig.String(): - err = json.Unmarshal(a.Spec, &a.ManualCredentials) + case KubernetesCredentialTypes.ManualConfig: + err = json.Unmarshal(a.Spec, &a.ManualConfig) default: panic(fmt.Sprintf("unknown connector type %s", a.Type_)) } @@ -32,17 +32,17 @@ func (a *KubernetesCredentialDto) UnmarshalJSON(data []byte) error { return err } -func (a *KubernetesCredentialDto) MarshalJSON() ([]byte, error) { - type Alias KubernetesCredentialDto +func (a *KubernetesCredential) MarshalJSON() ([]byte, error) { + type Alias KubernetesCredential var spec []byte var err error switch a.Type_ { - case KubernetesCredentialTypes.InheritFromDelegate.String(): + case KubernetesCredentialTypes.InheritFromDelegate: // do nothing - case KubernetesCredentialTypes.ManualConfig.String(): - spec, err = json.Marshal(a.ManualCredentials) + case KubernetesCredentialTypes.ManualConfig: + spec, err = json.Marshal(a.ManualConfig) default: panic(fmt.Sprintf("unknown connector type %s", a.Type_)) } diff --git a/harness/nextgen/model_additional_metadata.go b/harness/nextgen/model_kubernetes_credential_spec.go similarity index 79% rename from harness/nextgen/model_additional_metadata.go rename to harness/nextgen/model_kubernetes_credential_spec.go index 6d300378..025d2e67 100644 --- a/harness/nextgen/model_additional_metadata.go +++ b/harness/nextgen/model_kubernetes_credential_spec.go @@ -9,6 +9,6 @@ */ package nextgen -type AdditionalMetadata struct { - Values map[string]interface{} `json:"values,omitempty"` +// This contains kubernetes credentials spec details +type KubernetesCredentialSpec struct { } diff --git a/harness/nextgen/model_kubernetes_credential_spec_dto.go b/harness/nextgen/model_kubernetes_credential_spec_dto.go deleted file mode 100644 index 2feb3bd0..00000000 --- a/harness/nextgen/model_kubernetes_credential_spec_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type KubernetesCredentialSpecDto struct { -} diff --git a/harness/nextgen/model_kubernetes_open_id_connect_dto.go b/harness/nextgen/model_kubernetes_open_id_connect.go similarity index 89% rename from harness/nextgen/model_kubernetes_open_id_connect_dto.go rename to harness/nextgen/model_kubernetes_open_id_connect.go index 3918bc91..32a6ab4f 100644 --- a/harness/nextgen/model_kubernetes_open_id_connect_dto.go +++ b/harness/nextgen/model_kubernetes_open_id_connect.go @@ -9,7 +9,8 @@ */ package nextgen -type KubernetesOpenIdConnectDto struct { +// This contains kubernetes open id connect details +type KubernetesOpenIdConnect struct { OidcIssuerUrl string `json:"oidcIssuerUrl,omitempty"` OidcUsername string `json:"oidcUsername,omitempty"` OidcUsernameRef string `json:"oidcUsernameRef,omitempty"` diff --git a/harness/nextgen/model_kubernetes_service_account_dto.go b/harness/nextgen/model_kubernetes_service_account.go similarity index 82% rename from harness/nextgen/model_kubernetes_service_account_dto.go rename to harness/nextgen/model_kubernetes_service_account.go index 20cf4829..d60528b9 100644 --- a/harness/nextgen/model_kubernetes_service_account_dto.go +++ b/harness/nextgen/model_kubernetes_service_account.go @@ -9,6 +9,7 @@ */ package nextgen -type KubernetesServiceAccountDto struct { +// This contains kubernetes service account details +type KubernetesServiceAccount struct { ServiceAccountTokenRef string `json:"serviceAccountTokenRef"` } diff --git a/harness/nextgen/model_github_username_password_dto.go b/harness/nextgen/model_kubernetes_user_name_password.go similarity index 83% rename from harness/nextgen/model_github_username_password_dto.go rename to harness/nextgen/model_kubernetes_user_name_password.go index 51c2db35..d18cd00c 100644 --- a/harness/nextgen/model_github_username_password_dto.go +++ b/harness/nextgen/model_kubernetes_user_name_password.go @@ -9,7 +9,8 @@ */ package nextgen -type GithubUsernamePasswordDto struct { +// This contains kubernetes username password details +type KubernetesUserNamePassword struct { Username string `json:"username,omitempty"` UsernameRef string `json:"usernameRef,omitempty"` PasswordRef string `json:"passwordRef"` diff --git a/harness/nextgen/model_kubernetes_user_name_password_dto.go b/harness/nextgen/model_kubernetes_user_name_password_dto.go deleted file mode 100644 index 38724313..00000000 --- a/harness/nextgen/model_kubernetes_user_name_password_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type KubernetesUserNamePasswordDto struct { - Username string `json:"username,omitempty"` - UsernameRef string `json:"usernameRef,omitempty"` - PasswordRef string `json:"passwordRef"` -} diff --git a/harness/nextgen/model_last_workload_info.go b/harness/nextgen/model_last_workload_info.go deleted file mode 100644 index 64a6fad7..00000000 --- a/harness/nextgen/model_last_workload_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type LastWorkloadInfo struct { - StartTime int64 `json:"startTime,omitempty"` - EndTime int64 `json:"endTime,omitempty"` - DeploymentType string `json:"deploymentType,omitempty"` - Status string `json:"status,omitempty"` -} diff --git a/harness/nextgen/model_local_config_dto.go b/harness/nextgen/model_local_config_dto.go deleted file mode 100644 index 5e1ca64c..00000000 --- a/harness/nextgen/model_local_config_dto.go +++ /dev/null @@ -1,23 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type LocalConfigDto struct { - Name string `json:"name,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Identifier string `json:"identifier,omitempty"` - Description string `json:"description,omitempty"` - EncryptionType string `json:"encryptionType,omitempty"` - HarnessManaged bool `json:"harnessManaged,omitempty"` - Default_ bool `json:"default,omitempty"` -} diff --git a/harness/nextgen/model_location.go b/harness/nextgen/model_location.go deleted file mode 100644 index 61316325..00000000 --- a/harness/nextgen/model_location.go +++ /dev/null @@ -1,32 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type Location struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - SpanList []int32 `json:"spanList,omitempty"` - PathList []int32 `json:"pathList,omitempty"` - ParserForType *ParserLocation `json:"parserForType,omitempty"` - DefaultInstanceForType *Location `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - PathCount int32 `json:"pathCount,omitempty"` - TrailingCommentsBytes *ByteString `json:"trailingCommentsBytes,omitempty"` - LeadingDetachedCommentsList []string `json:"leadingDetachedCommentsList,omitempty"` - SpanCount int32 `json:"spanCount,omitempty"` - LeadingComments string `json:"leadingComments,omitempty"` - LeadingCommentsBytes *ByteString `json:"leadingCommentsBytes,omitempty"` - LeadingDetachedCommentsCount int32 `json:"leadingDetachedCommentsCount,omitempty"` - TrailingComments string `json:"trailingComments,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_location_or_builder.go b/harness/nextgen/model_location_or_builder.go deleted file mode 100644 index cf389715..00000000 --- a/harness/nextgen/model_location_or_builder.go +++ /dev/null @@ -1,29 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type LocationOrBuilder struct { - SpanList []int32 `json:"spanList,omitempty"` - PathList []int32 `json:"pathList,omitempty"` - PathCount int32 `json:"pathCount,omitempty"` - TrailingCommentsBytes *ByteString `json:"trailingCommentsBytes,omitempty"` - LeadingDetachedCommentsList []string `json:"leadingDetachedCommentsList,omitempty"` - SpanCount int32 `json:"spanCount,omitempty"` - LeadingComments string `json:"leadingComments,omitempty"` - LeadingCommentsBytes *ByteString `json:"leadingCommentsBytes,omitempty"` - LeadingDetachedCommentsCount int32 `json:"leadingDetachedCommentsCount,omitempty"` - TrailingComments string `json:"trailingComments,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_managed_argo_git_ops_info_dto.go b/harness/nextgen/model_managed_argo_git_ops_info_dto.go deleted file mode 100644 index 95da461b..00000000 --- a/harness/nextgen/model_managed_argo_git_ops_info_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ManagedArgoGitOpsInfoDto struct { - Type_ string `json:"type,omitempty"` - Namespace string `json:"namespace"` -} diff --git a/harness/nextgen/model_message.go b/harness/nextgen/model_message.go deleted file mode 100644 index ee0641e2..00000000 --- a/harness/nextgen/model_message.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type Message struct { - ParserForType *ParserMessage `json:"parserForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - Initialized bool `json:"initialized,omitempty"` - DefaultInstanceForType *MessageLite `json:"defaultInstanceForType,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` -} diff --git a/harness/nextgen/model_message_lite.go b/harness/nextgen/model_message_lite.go deleted file mode 100644 index ed82f18f..00000000 --- a/harness/nextgen/model_message_lite.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type MessageLite struct { - ParserForType *ParserMessageLite `json:"parserForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - Initialized bool `json:"initialized,omitempty"` - DefaultInstanceForType *MessageLite `json:"defaultInstanceForType,omitempty"` -} diff --git a/harness/nextgen/model_message_options.go b/harness/nextgen/model_message_options.go deleted file mode 100644 index e96eac7a..00000000 --- a/harness/nextgen/model_message_options.go +++ /dev/null @@ -1,30 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type MessageOptions struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - ParserForType *ParserMessageOptions `json:"parserForType,omitempty"` - DefaultInstanceForType *MessageOptions `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - MessageSetWireFormat bool `json:"messageSetWireFormat,omitempty"` - NoStandardDescriptorAccessor bool `json:"noStandardDescriptorAccessor,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - MapEntry bool `json:"mapEntry,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - AllFieldsRaw map[string]interface{} `json:"allFieldsRaw,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_message_options_or_builder.go b/harness/nextgen/model_message_options_or_builder.go deleted file mode 100644 index b80ee27c..00000000 --- a/harness/nextgen/model_message_options_or_builder.go +++ /dev/null @@ -1,26 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type MessageOptionsOrBuilder struct { - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - MessageSetWireFormat bool `json:"messageSetWireFormat,omitempty"` - NoStandardDescriptorAccessor bool `json:"noStandardDescriptorAccessor,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - MapEntry bool `json:"mapEntry,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_method_descriptor.go b/harness/nextgen/model_method_descriptor.go deleted file mode 100644 index 81070baf..00000000 --- a/harness/nextgen/model_method_descriptor.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type MethodDescriptor struct { - Index int32 `json:"index,omitempty"` - Proto *MethodDescriptorProto `json:"proto,omitempty"` - FullName string `json:"fullName,omitempty"` - File *FileDescriptor `json:"file,omitempty"` - Service *ServiceDescriptor `json:"service,omitempty"` - InputType *Descriptor `json:"inputType,omitempty"` - OutputType *Descriptor `json:"outputType,omitempty"` - Options *MethodOptions `json:"options,omitempty"` - ClientStreaming bool `json:"clientStreaming,omitempty"` - ServerStreaming bool `json:"serverStreaming,omitempty"` - Name string `json:"name,omitempty"` -} diff --git a/harness/nextgen/model_method_descriptor_proto.go b/harness/nextgen/model_method_descriptor_proto.go deleted file mode 100644 index 122656d8..00000000 --- a/harness/nextgen/model_method_descriptor_proto.go +++ /dev/null @@ -1,32 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type MethodDescriptorProto struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Options *MethodOptions `json:"options,omitempty"` - OutputType string `json:"outputType,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - ParserForType *ParserMethodDescriptorProto `json:"parserForType,omitempty"` - DefaultInstanceForType *MethodDescriptorProto `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - InputType string `json:"inputType,omitempty"` - OptionsOrBuilder *MethodOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - ClientStreaming bool `json:"clientStreaming,omitempty"` - ServerStreaming bool `json:"serverStreaming,omitempty"` - InputTypeBytes *ByteString `json:"inputTypeBytes,omitempty"` - OutputTypeBytes *ByteString `json:"outputTypeBytes,omitempty"` - Name string `json:"name,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_method_descriptor_proto_or_builder.go b/harness/nextgen/model_method_descriptor_proto_or_builder.go deleted file mode 100644 index d4aa85f5..00000000 --- a/harness/nextgen/model_method_descriptor_proto_or_builder.go +++ /dev/null @@ -1,29 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type MethodDescriptorProtoOrBuilder struct { - Options *MethodOptions `json:"options,omitempty"` - OutputType string `json:"outputType,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - InputType string `json:"inputType,omitempty"` - OptionsOrBuilder *MethodOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - ClientStreaming bool `json:"clientStreaming,omitempty"` - ServerStreaming bool `json:"serverStreaming,omitempty"` - InputTypeBytes *ByteString `json:"inputTypeBytes,omitempty"` - OutputTypeBytes *ByteString `json:"outputTypeBytes,omitempty"` - Name string `json:"name,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_method_options.go b/harness/nextgen/model_method_options.go deleted file mode 100644 index 13c11b33..00000000 --- a/harness/nextgen/model_method_options.go +++ /dev/null @@ -1,28 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type MethodOptions struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - ParserForType *ParserMethodOptions `json:"parserForType,omitempty"` - DefaultInstanceForType *MethodOptions `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - IdempotencyLevel string `json:"idempotencyLevel,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - AllFieldsRaw map[string]interface{} `json:"allFieldsRaw,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_method_options_or_builder.go b/harness/nextgen/model_method_options_or_builder.go deleted file mode 100644 index a686b444..00000000 --- a/harness/nextgen/model_method_options_or_builder.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type MethodOptionsOrBuilder struct { - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - IdempotencyLevel string `json:"idempotencyLevel,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_microsoft_teams_config_dto.go b/harness/nextgen/model_microsoft_teams_config_dto.go deleted file mode 100644 index 885ee5e9..00000000 --- a/harness/nextgen/model_microsoft_teams_config_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type MicrosoftTeamsConfigDto struct { - Type_ string `json:"type,omitempty"` - MicrosoftTeamsWebhookUrl string `json:"microsoftTeamsWebhookUrl"` -} diff --git a/harness/nextgen/model_name_part.go b/harness/nextgen/model_name_part.go deleted file mode 100644 index 3dc35d10..00000000 --- a/harness/nextgen/model_name_part.go +++ /dev/null @@ -1,25 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NamePart struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - ParserForType *ParserNamePart `json:"parserForType,omitempty"` - DefaultInstanceForType *NamePart `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - IsExtension bool `json:"isExtension,omitempty"` - NamePart string `json:"namePart,omitempty"` - NamePartBytes *ByteString `json:"namePartBytes,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_name_part_or_builder.go b/harness/nextgen/model_name_part_or_builder.go deleted file mode 100644 index ff20a1bb..00000000 --- a/harness/nextgen/model_name_part_or_builder.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NamePartOrBuilder struct { - IsExtension bool `json:"isExtension,omitempty"` - NamePart string `json:"namePart,omitempty"` - NamePartBytes *ByteString `json:"namePartBytes,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_native_events.go b/harness/nextgen/model_native_events.go deleted file mode 100644 index dae71226..00000000 --- a/harness/nextgen/model_native_events.go +++ /dev/null @@ -1,31 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NativeEvents struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - GithubOrBuilder *GithubWebhookEventsOrBuilder `json:"githubOrBuilder,omitempty"` - Gitlab *GitlabWebhookEvents `json:"gitlab,omitempty"` - GitlabOrBuilder *GitlabWebhookEventsOrBuilder `json:"gitlabOrBuilder,omitempty"` - BitbucketCloud *BitbucketCloudWebhookEvents `json:"bitbucketCloud,omitempty"` - BitbucketCloudOrBuilder *BitbucketCloudWebhookEventsOrBuilder `json:"bitbucketCloudOrBuilder,omitempty"` - BitbucketServer *BitbucketServerWebhookEvents `json:"bitbucketServer,omitempty"` - BitbucketServerOrBuilder *BitbucketServerWebhookEventsOrBuilder `json:"bitbucketServerOrBuilder,omitempty"` - ParserForType *ParserNativeEvents `json:"parserForType,omitempty"` - DefaultInstanceForType *NativeEvents `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - Github *GithubWebhookEvents `json:"github,omitempty"` - NativeEventsCase string `json:"nativeEventsCase,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_native_events_or_builder.go b/harness/nextgen/model_native_events_or_builder.go deleted file mode 100644 index 5ea59d71..00000000 --- a/harness/nextgen/model_native_events_or_builder.go +++ /dev/null @@ -1,28 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NativeEventsOrBuilder struct { - GithubOrBuilder *GithubWebhookEventsOrBuilder `json:"githubOrBuilder,omitempty"` - Gitlab *GitlabWebhookEvents `json:"gitlab,omitempty"` - GitlabOrBuilder *GitlabWebhookEventsOrBuilder `json:"gitlabOrBuilder,omitempty"` - BitbucketCloud *BitbucketCloudWebhookEvents `json:"bitbucketCloud,omitempty"` - BitbucketCloudOrBuilder *BitbucketCloudWebhookEventsOrBuilder `json:"bitbucketCloudOrBuilder,omitempty"` - BitbucketServer *BitbucketServerWebhookEvents `json:"bitbucketServer,omitempty"` - BitbucketServerOrBuilder *BitbucketServerWebhookEventsOrBuilder `json:"bitbucketServerOrBuilder,omitempty"` - Github *GithubWebhookEvents `json:"github,omitempty"` - NativeEventsCase string `json:"nativeEventsCase,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_nexus_auth_credentials.go b/harness/nextgen/model_nexus_auth_credentials.go new file mode 100644 index 00000000..d6be68a2 --- /dev/null +++ b/harness/nextgen/model_nexus_auth_credentials.go @@ -0,0 +1,14 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of credentials for Nexus Authentication +type NexusAuthCredentials struct { +} diff --git a/harness/nextgen/model_nexus_auth_credentials_dto.go b/harness/nextgen/model_nexus_auth_credentials_dto.go deleted file mode 100644 index 4292ec78..00000000 --- a/harness/nextgen/model_nexus_auth_credentials_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NexusAuthCredentialsDto struct { -} diff --git a/harness/nextgen/model_docker_authentication_dto.go b/harness/nextgen/model_nexus_authentication.go similarity index 65% rename from harness/nextgen/model_docker_authentication_dto.go rename to harness/nextgen/model_nexus_authentication.go index 025ff258..96911854 100644 --- a/harness/nextgen/model_docker_authentication_dto.go +++ b/harness/nextgen/model_nexus_authentication.go @@ -9,12 +9,11 @@ */ package nextgen -import ( - "encoding/json" -) +import "encoding/json" -type DockerAuthenticationDto struct { - Type_ string `json:"type"` - UsernamePassword *DockerUserNamePasswordDto `json:"-"` +// This contains details of Nexus Authentication +type NexusAuthentication struct { + Type_ NexusAuthType `json:"type"` + UsernamePassword *NexusUsernamePasswordAuth `json:"-"` Spec json.RawMessage `json:"spec,omitempty"` } diff --git a/harness/nextgen/model_nexus_authentication_dto.go b/harness/nextgen/model_nexus_authentication_dto.go deleted file mode 100644 index 7a397dd0..00000000 --- a/harness/nextgen/model_nexus_authentication_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -import ( - "encoding/json" -) - -type NexusAuthenticationDto struct { - Type_ string `json:"type"` - UsernamePassword *NexusUsernamePasswordAuthDto `json:"-"` - Spec json.RawMessage `json:"spec,omitempty"` -} diff --git a/harness/nextgen/model_nexus_authentication_serializer.go b/harness/nextgen/model_nexus_authentication_serializer.go index 0c07b938..da7fc5fd 100644 --- a/harness/nextgen/model_nexus_authentication_serializer.go +++ b/harness/nextgen/model_nexus_authentication_serializer.go @@ -5,9 +5,9 @@ import ( "fmt" ) -func (a *NexusAuthenticationDto) UnmarshalJSON(data []byte) error { +func (a *NexusAuthentication) UnmarshalJSON(data []byte) error { - type Alias NexusAuthenticationDto + type Alias NexusAuthentication aux := &struct { *Alias @@ -21,9 +21,9 @@ func (a *NexusAuthenticationDto) UnmarshalJSON(data []byte) error { } switch a.Type_ { - case NexusAuthTypes.UsernamePassword.String(): + case NexusAuthTypes.UsernamePassword: err = json.Unmarshal(aux.Spec, &a.UsernamePassword) - case NexusAuthTypes.Anonymous.String(): + case NexusAuthTypes.Anonymous: // nothing to do default: panic(fmt.Sprintf("unknown nexus auth method type %s", a.Type_)) @@ -32,16 +32,16 @@ func (a *NexusAuthenticationDto) UnmarshalJSON(data []byte) error { return err } -func (a *NexusAuthenticationDto) MarshalJSON() ([]byte, error) { - type Alias NexusAuthenticationDto +func (a *NexusAuthentication) MarshalJSON() ([]byte, error) { + type Alias NexusAuthentication var spec []byte var err error switch a.Type_ { - case NexusAuthTypes.UsernamePassword.String(): + case NexusAuthTypes.UsernamePassword: spec, err = json.Marshal(a.UsernamePassword) - case NexusAuthTypes.Anonymous.String(): + case NexusAuthTypes.Anonymous: // nothing to do default: panic(fmt.Sprintf("unknown nexus auth method type %s", a.Type_)) diff --git a/harness/nextgen/model_rest_response.go b/harness/nextgen/model_nexus_connector.go similarity index 53% rename from harness/nextgen/model_rest_response.go rename to harness/nextgen/model_nexus_connector.go index 20cb86bc..059138fa 100644 --- a/harness/nextgen/model_rest_response.go +++ b/harness/nextgen/model_nexus_connector.go @@ -9,8 +9,10 @@ */ package nextgen -type RestResponse struct { - MetaData map[string]interface{} `json:"metaData,omitempty"` - Resource *interface{} `json:"resource,omitempty"` - ResponseMessages []ResponseMessage `json:"responseMessages,omitempty"` +// This contains details of Nexus Connector +type NexusConnector struct { + NexusServerUrl string `json:"nexusServerUrl"` + Version string `json:"version"` + Auth *NexusAuthentication `json:"auth,omitempty"` + DelegateSelectors []string `json:"delegateSelectors,omitempty"` } diff --git a/harness/nextgen/model_docker_user_name_password_dto.go b/harness/nextgen/model_nexus_username_password_auth.go similarity index 83% rename from harness/nextgen/model_docker_user_name_password_dto.go rename to harness/nextgen/model_nexus_username_password_auth.go index e911dd91..685ba452 100644 --- a/harness/nextgen/model_docker_user_name_password_dto.go +++ b/harness/nextgen/model_nexus_username_password_auth.go @@ -9,7 +9,8 @@ */ package nextgen -type DockerUserNamePasswordDto struct { +// This contains details of Nexus Username and Password +type NexusUsernamePasswordAuth struct { Username string `json:"username,omitempty"` UsernameRef string `json:"usernameRef,omitempty"` PasswordRef string `json:"passwordRef"` diff --git a/harness/nextgen/model_nexus_username_password_auth_dto.go b/harness/nextgen/model_nexus_username_password_auth_dto.go deleted file mode 100644 index 35b47999..00000000 --- a/harness/nextgen/model_nexus_username_password_auth_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NexusUsernamePasswordAuthDto struct { - Username string `json:"username,omitempty"` - UsernameRef string `json:"usernameRef,omitempty"` - PasswordRef string `json:"passwordRef"` -} diff --git a/harness/nextgen/model_ng_access.go b/harness/nextgen/model_ng_access.go deleted file mode 100644 index effca4a9..00000000 --- a/harness/nextgen/model_ng_access.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NgAccess struct { - Identifier string `json:"identifier,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` -} diff --git a/harness/nextgen/model_ng_activity_dto.go b/harness/nextgen/model_ng_activity_dto.go deleted file mode 100644 index ad5c6c3b..00000000 --- a/harness/nextgen/model_ng_activity_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NgActivityDto struct { - AccountIdentifier string `json:"accountIdentifier,omitempty"` - ReferredEntity *EntityDetail `json:"referredEntity,omitempty"` - Type_ string `json:"type"` - ActivityStatus string `json:"activityStatus"` - Detail *ActivityDetail `json:"detail,omitempty"` - ActivityTime int64 `json:"activityTime"` - Description string `json:"description,omitempty"` -} diff --git a/harness/nextgen/model_ng_activity_summary_dto.go b/harness/nextgen/model_ng_activity_summary_dto.go deleted file mode 100644 index ad487a96..00000000 --- a/harness/nextgen/model_ng_activity_summary_dto.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NgActivitySummaryDto struct { - GetId int64 `json:"get_id,omitempty"` - StartTime int64 `json:"startTime,omitempty"` - EndTime int64 `json:"endTime,omitempty"` - HeartBeatFailuresCount int64 `json:"heartBeatFailuresCount,omitempty"` - SuccessfulActivitiesCount int64 `json:"successfulActivitiesCount,omitempty"` - FailedActivitiesCount int64 `json:"failedActivitiesCount,omitempty"` -} diff --git a/harness/nextgen/model_ng_properties.go b/harness/nextgen/model_ng_properties.go deleted file mode 100644 index f9e32b3f..00000000 --- a/harness/nextgen/model_ng_properties.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NgProperties struct { - Ci *JsonNode `json:"ci,omitempty"` -} diff --git a/harness/nextgen/model_ng_tag.go b/harness/nextgen/model_ng_tag.go deleted file mode 100644 index 763054dd..00000000 --- a/harness/nextgen/model_ng_tag.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NgTag struct { - Key string `json:"key"` - Value string `json:"value"` -} diff --git a/harness/nextgen/model_ng_variable.go b/harness/nextgen/model_ng_variable.go deleted file mode 100644 index 245ca937..00000000 --- a/harness/nextgen/model_ng_variable.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NgVariable struct { - Description string `json:"description,omitempty"` - CurrentValue *ParameterFieldObject `json:"currentValue,omitempty"` - Required bool `json:"required,omitempty"` - Name string `json:"name,omitempty"` - Type_ string `json:"type,omitempty"` - Metadata string `json:"metadata,omitempty"` -} diff --git a/harness/nextgen/model_notification_channel_wrapper.go b/harness/nextgen/model_notification_channel_wrapper.go deleted file mode 100644 index 6a3f9263..00000000 --- a/harness/nextgen/model_notification_channel_wrapper.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NotificationChannelWrapper struct { - Type_ string `json:"type,omitempty"` - Spec *PmsNotificationChannel `json:"spec,omitempty"` -} diff --git a/harness/nextgen/model_notification_rules.go b/harness/nextgen/model_notification_rules.go deleted file mode 100644 index 954ac543..00000000 --- a/harness/nextgen/model_notification_rules.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NotificationRules struct { - Name string `json:"name,omitempty"` - Enabled bool `json:"enabled,omitempty"` - PipelineEvents []PipelineEvent `json:"pipelineEvents,omitempty"` - NotificationMethod *ParameterFieldNotificationChannelWrapper `json:"notificationMethod,omitempty"` -} diff --git a/harness/nextgen/model_notification_setting_config.go b/harness/nextgen/model_notification_setting_config.go deleted file mode 100644 index 4d0a183f..00000000 --- a/harness/nextgen/model_notification_setting_config.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NotificationSettingConfig struct { - Type_ string `json:"type"` -} diff --git a/harness/nextgen/model_notification_setting_config_dto.go b/harness/nextgen/model_notification_setting_config_dto.go deleted file mode 100644 index 645a9457..00000000 --- a/harness/nextgen/model_notification_setting_config_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NotificationSettingConfigDto struct { - Type_ string `json:"type,omitempty"` -} diff --git a/harness/nextgen/model_number_ng_variable.go b/harness/nextgen/model_number_ng_variable.go deleted file mode 100644 index d58082d0..00000000 --- a/harness/nextgen/model_number_ng_variable.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type NumberNgVariable struct { - Description string `json:"description,omitempty"` - CurrentValue *ParameterFieldObject `json:"currentValue,omitempty"` - Required bool `json:"required,omitempty"` - Name string `json:"name,omitempty"` - Type_ string `json:"type,omitempty"` - Metadata string `json:"metadata,omitempty"` - Value *ParameterFieldDouble `json:"value"` - Default_ float64 `json:"default,omitempty"` -} diff --git a/harness/nextgen/model_o_auth_signup_dto.go b/harness/nextgen/model_o_auth_signup_dto.go deleted file mode 100644 index 14aee124..00000000 --- a/harness/nextgen/model_o_auth_signup_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type OAuthSignupDto struct { - Email string `json:"email,omitempty"` - Name string `json:"name,omitempty"` - UtmInfo *UtmInfo `json:"utmInfo,omitempty"` -} diff --git a/harness/nextgen/model_oneof_descriptor.go b/harness/nextgen/model_oneof_descriptor.go deleted file mode 100644 index 5ee6eef4..00000000 --- a/harness/nextgen/model_oneof_descriptor.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type OneofDescriptor struct { - Index int32 `json:"index,omitempty"` - Proto *OneofDescriptorProto `json:"proto,omitempty"` - FullName string `json:"fullName,omitempty"` - File *FileDescriptor `json:"file,omitempty"` - ContainingType *Descriptor `json:"containingType,omitempty"` - FieldCount int32 `json:"fieldCount,omitempty"` - Fields []FieldDescriptor `json:"fields,omitempty"` - Options *OneofOptions `json:"options,omitempty"` - Name string `json:"name,omitempty"` -} diff --git a/harness/nextgen/model_oneof_descriptor_proto.go b/harness/nextgen/model_oneof_descriptor_proto.go deleted file mode 100644 index d68a1f04..00000000 --- a/harness/nextgen/model_oneof_descriptor_proto.go +++ /dev/null @@ -1,26 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type OneofDescriptorProto struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Options *OneofOptions `json:"options,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - ParserForType *ParserOneofDescriptorProto `json:"parserForType,omitempty"` - DefaultInstanceForType *OneofDescriptorProto `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - OptionsOrBuilder *OneofOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - Name string `json:"name,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_oneof_descriptor_proto_or_builder.go b/harness/nextgen/model_oneof_descriptor_proto_or_builder.go deleted file mode 100644 index be65ba39..00000000 --- a/harness/nextgen/model_oneof_descriptor_proto_or_builder.go +++ /dev/null @@ -1,23 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type OneofDescriptorProtoOrBuilder struct { - Options *OneofOptions `json:"options,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - OptionsOrBuilder *OneofOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - Name string `json:"name,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_oneof_options.go b/harness/nextgen/model_oneof_options.go deleted file mode 100644 index 05ebda71..00000000 --- a/harness/nextgen/model_oneof_options.go +++ /dev/null @@ -1,26 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type OneofOptions struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - ParserForType *ParserOneofOptions `json:"parserForType,omitempty"` - DefaultInstanceForType *OneofOptions `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - AllFieldsRaw map[string]interface{} `json:"allFieldsRaw,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_oneof_options_or_builder.go b/harness/nextgen/model_oneof_options_or_builder.go deleted file mode 100644 index 1f946cd6..00000000 --- a/harness/nextgen/model_oneof_options_or_builder.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type OneofOptionsOrBuilder struct { - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_org_project_identifier.go b/harness/nextgen/model_org_project_identifier.go deleted file mode 100644 index 28c2062d..00000000 --- a/harness/nextgen/model_org_project_identifier.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type OrgProjectIdentifier struct { - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` -} diff --git a/harness/nextgen/model_organization_aggregate_dto.go b/harness/nextgen/model_organization_aggregate_dto.go deleted file mode 100644 index f22b97e7..00000000 --- a/harness/nextgen/model_organization_aggregate_dto.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type OrganizationAggregateDto struct { - OrganizationResponse *OrganizationResponse `json:"organizationResponse"` - ProjectsCount int32 `json:"projectsCount,omitempty"` - ConnectorsCount int64 `json:"connectorsCount,omitempty"` - SecretsCount int64 `json:"secretsCount,omitempty"` - DelegatesCount int64 `json:"delegatesCount,omitempty"` - TemplatesCount int64 `json:"templatesCount,omitempty"` - Admins []UserMetadataDto `json:"admins,omitempty"` - Collaborators []UserMetadataDto `json:"collaborators,omitempty"` -} diff --git a/harness/nextgen/model_page_entity_setup_usage_dto.go b/harness/nextgen/model_page_entity_setup_usage_dto.go deleted file mode 100644 index 8f0c2704..00000000 --- a/harness/nextgen/model_page_entity_setup_usage_dto.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageEntitySetupUsageDto struct { - TotalPages int32 `json:"totalPages,omitempty"` - TotalElements int64 `json:"totalElements,omitempty"` - Sort *Sort `json:"sort,omitempty"` - First bool `json:"first,omitempty"` - Last bool `json:"last,omitempty"` - Pageable *Pageable `json:"pageable,omitempty"` - NumberOfElements int32 `json:"numberOfElements,omitempty"` - Size int32 `json:"size,omitempty"` - Content []EntitySetupUsageDto `json:"content,omitempty"` - Number int32 `json:"number,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_ng_activity_dto.go b/harness/nextgen/model_page_ng_activity_dto.go deleted file mode 100644 index 7d1e081f..00000000 --- a/harness/nextgen/model_page_ng_activity_dto.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageNgActivityDto struct { - TotalPages int32 `json:"totalPages,omitempty"` - TotalElements int64 `json:"totalElements,omitempty"` - Sort *Sort `json:"sort,omitempty"` - First bool `json:"first,omitempty"` - Last bool `json:"last,omitempty"` - Pageable *Pageable `json:"pageable,omitempty"` - NumberOfElements int32 `json:"numberOfElements,omitempty"` - Size int32 `json:"size,omitempty"` - Content []NgActivityDto `json:"content,omitempty"` - Number int32 `json:"number,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_ng_activity_summary_dto.go b/harness/nextgen/model_page_ng_activity_summary_dto.go deleted file mode 100644 index 1f56e95d..00000000 --- a/harness/nextgen/model_page_ng_activity_summary_dto.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageNgActivitySummaryDto struct { - TotalPages int32 `json:"totalPages,omitempty"` - TotalElements int64 `json:"totalElements,omitempty"` - Sort *Sort `json:"sort,omitempty"` - First bool `json:"first,omitempty"` - Last bool `json:"last,omitempty"` - Pageable *Pageable `json:"pageable,omitempty"` - NumberOfElements int32 `json:"numberOfElements,omitempty"` - Size int32 `json:"size,omitempty"` - Content []NgActivitySummaryDto `json:"content,omitempty"` - Number int32 `json:"number,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_api_key_aggregate_dto.go b/harness/nextgen/model_page_response_api_key_aggregate_dto.go deleted file mode 100644 index d524ab33..00000000 --- a/harness/nextgen/model_page_response_api_key_aggregate_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseApiKeyAggregateDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []ApiKeyAggregateDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_environment_response_dto.go b/harness/nextgen/model_page_response_environment_response_dto.go deleted file mode 100644 index 7807236e..00000000 --- a/harness/nextgen/model_page_response_environment_response_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseEnvironmentResponseDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []EnvironmentResponseDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_filter.go b/harness/nextgen/model_page_response_filter.go new file mode 100644 index 00000000..89d6a9c8 --- /dev/null +++ b/harness/nextgen/model_page_response_filter.go @@ -0,0 +1,20 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +type PageResponseFilter struct { + TotalPages int64 `json:"totalPages,omitempty"` + TotalItems int64 `json:"totalItems,omitempty"` + PageItemCount int64 `json:"pageItemCount,omitempty"` + PageSize int64 `json:"pageSize,omitempty"` + Content []Filter `json:"content,omitempty"` + PageIndex int64 `json:"pageIndex,omitempty"` + Empty bool `json:"empty,omitempty"` +} diff --git a/harness/nextgen/model_page_response_filter_dto.go b/harness/nextgen/model_page_response_git_branch.go similarity index 88% rename from harness/nextgen/model_page_response_filter_dto.go rename to harness/nextgen/model_page_response_git_branch.go index 9afb0fcb..c7d55251 100644 --- a/harness/nextgen/model_page_response_filter_dto.go +++ b/harness/nextgen/model_page_response_git_branch.go @@ -9,12 +9,12 @@ */ package nextgen -type PageResponseFilterDto struct { +type PageResponseGitBranch struct { TotalPages int64 `json:"totalPages,omitempty"` TotalItems int64 `json:"totalItems,omitempty"` PageItemCount int64 `json:"pageItemCount,omitempty"` PageSize int64 `json:"pageSize,omitempty"` - Content []FilterDto `json:"content,omitempty"` + Content []GitBranch `json:"content,omitempty"` PageIndex int64 `json:"pageIndex,omitempty"` Empty bool `json:"empty,omitempty"` } diff --git a/harness/nextgen/model_page_response_git_ops_provider_response_dto.go b/harness/nextgen/model_page_response_git_ops_provider_response_dto.go deleted file mode 100644 index 3519d0f7..00000000 --- a/harness/nextgen/model_page_response_git_ops_provider_response_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseGitOpsProviderResponseDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []GitOpsProviderResponseDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_token_aggregate_dto.go b/harness/nextgen/model_page_response_git_sync_entity_list.go similarity index 87% rename from harness/nextgen/model_page_response_token_aggregate_dto.go rename to harness/nextgen/model_page_response_git_sync_entity_list.go index e7c87b24..96129a39 100644 --- a/harness/nextgen/model_page_response_token_aggregate_dto.go +++ b/harness/nextgen/model_page_response_git_sync_entity_list.go @@ -9,12 +9,12 @@ */ package nextgen -type PageResponseTokenAggregateDto struct { +type PageResponseGitSyncEntityList struct { TotalPages int64 `json:"totalPages,omitempty"` TotalItems int64 `json:"totalItems,omitempty"` PageItemCount int64 `json:"pageItemCount,omitempty"` PageSize int64 `json:"pageSize,omitempty"` - Content []TokenAggregateDto `json:"content,omitempty"` + Content []GitSyncEntityList `json:"content,omitempty"` PageIndex int64 `json:"pageIndex,omitempty"` Empty bool `json:"empty,omitempty"` } diff --git a/harness/nextgen/model_page_response_git_sync_entity_list_dto.go b/harness/nextgen/model_page_response_git_sync_entity_list_dto.go deleted file mode 100644 index a13697c3..00000000 --- a/harness/nextgen/model_page_response_git_sync_entity_list_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseGitSyncEntityListDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []GitSyncEntityListDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_git_branch_dto.go b/harness/nextgen/model_page_response_git_sync_error.go similarity index 88% rename from harness/nextgen/model_page_response_git_branch_dto.go rename to harness/nextgen/model_page_response_git_sync_error.go index d3a69a35..20b6b35f 100644 --- a/harness/nextgen/model_page_response_git_branch_dto.go +++ b/harness/nextgen/model_page_response_git_sync_error.go @@ -9,12 +9,12 @@ */ package nextgen -type PageResponseGitBranchDto struct { +type PageResponseGitSyncError struct { TotalPages int64 `json:"totalPages,omitempty"` TotalItems int64 `json:"totalItems,omitempty"` PageItemCount int64 `json:"pageItemCount,omitempty"` PageSize int64 `json:"pageSize,omitempty"` - Content []GitBranchDto `json:"content,omitempty"` + Content []GitSyncError `json:"content,omitempty"` PageIndex int64 `json:"pageIndex,omitempty"` Empty bool `json:"empty,omitempty"` } diff --git a/harness/nextgen/model_page_response_git_sync_error_aggregate_by_commit.go b/harness/nextgen/model_page_response_git_sync_error_aggregate_by_commit.go new file mode 100644 index 00000000..71e00476 --- /dev/null +++ b/harness/nextgen/model_page_response_git_sync_error_aggregate_by_commit.go @@ -0,0 +1,20 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +type PageResponseGitSyncErrorAggregateByCommit struct { + TotalPages int64 `json:"totalPages,omitempty"` + TotalItems int64 `json:"totalItems,omitempty"` + PageItemCount int64 `json:"pageItemCount,omitempty"` + PageSize int64 `json:"pageSize,omitempty"` + Content []GitSyncErrorAggregateByCommit `json:"content,omitempty"` + PageIndex int64 `json:"pageIndex,omitempty"` + Empty bool `json:"empty,omitempty"` +} diff --git a/harness/nextgen/model_page_response_git_sync_error_aggregate_by_commit_dto.go b/harness/nextgen/model_page_response_git_sync_error_aggregate_by_commit_dto.go deleted file mode 100644 index dff32c8e..00000000 --- a/harness/nextgen/model_page_response_git_sync_error_aggregate_by_commit_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseGitSyncErrorAggregateByCommitDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []GitSyncErrorAggregateByCommitDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_git_sync_error_dto.go b/harness/nextgen/model_page_response_git_sync_error_dto.go deleted file mode 100644 index 4a92e2c5..00000000 --- a/harness/nextgen/model_page_response_git_sync_error_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseGitSyncErrorDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []GitSyncErrorDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_invite.go b/harness/nextgen/model_page_response_invite.go new file mode 100644 index 00000000..d92bb968 --- /dev/null +++ b/harness/nextgen/model_page_response_invite.go @@ -0,0 +1,20 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +type PageResponseInvite struct { + TotalPages int64 `json:"totalPages,omitempty"` + TotalItems int64 `json:"totalItems,omitempty"` + PageItemCount int64 `json:"pageItemCount,omitempty"` + PageSize int64 `json:"pageSize,omitempty"` + Content []Invite `json:"content,omitempty"` + PageIndex int64 `json:"pageIndex,omitempty"` + Empty bool `json:"empty,omitempty"` +} diff --git a/harness/nextgen/model_page_response_invite_dto.go b/harness/nextgen/model_page_response_invite_dto.go deleted file mode 100644 index 27768703..00000000 --- a/harness/nextgen/model_page_response_invite_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseInviteDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []InviteDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_organization_aggregate_dto.go b/harness/nextgen/model_page_response_organization_aggregate_dto.go deleted file mode 100644 index c79b7f95..00000000 --- a/harness/nextgen/model_page_response_organization_aggregate_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseOrganizationAggregateDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []OrganizationAggregateDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_project.go b/harness/nextgen/model_page_response_project.go deleted file mode 100644 index c445b6c2..00000000 --- a/harness/nextgen/model_page_response_project.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseProject struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []Project `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_project_aggregate_dto.go b/harness/nextgen/model_page_response_project_aggregate_dto.go deleted file mode 100644 index db54a340..00000000 --- a/harness/nextgen/model_page_response_project_aggregate_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseProjectAggregateDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []ProjectAggregateDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_role_assignment_response.go b/harness/nextgen/model_page_response_role_assignment_response.go deleted file mode 100644 index 2dfcdaae..00000000 --- a/harness/nextgen/model_page_response_role_assignment_response.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseRoleAssignmentResponse struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []RoleAssignmentResponse `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_secret_response_wrapper.go b/harness/nextgen/model_page_response_secret_response_wrapper.go deleted file mode 100644 index 5e48d163..00000000 --- a/harness/nextgen/model_page_response_secret_response_wrapper.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseSecretResponseWrapper struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []SecretResponseWrapper `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_service_account_aggregate_dto.go b/harness/nextgen/model_page_response_service_account_aggregate_dto.go deleted file mode 100644 index 1a3270e9..00000000 --- a/harness/nextgen/model_page_response_service_account_aggregate_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseServiceAccountAggregateDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []ServiceAccountAggregateDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_service_response_dto.go b/harness/nextgen/model_page_response_service_response_dto.go deleted file mode 100644 index 71b80f30..00000000 --- a/harness/nextgen/model_page_response_service_response_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseServiceResponseDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []ServiceResponseDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_user_aggregate_dto.go b/harness/nextgen/model_page_response_user_aggregate_dto.go deleted file mode 100644 index 95c5a4a6..00000000 --- a/harness/nextgen/model_page_response_user_aggregate_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseUserAggregateDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []UserAggregateDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_user_group_aggregate_dto.go b/harness/nextgen/model_page_response_user_group_aggregate_dto.go deleted file mode 100644 index 0cc2396d..00000000 --- a/harness/nextgen/model_page_response_user_group_aggregate_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseUserGroupAggregateDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []UserGroupAggregateDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_user_group_dto.go b/harness/nextgen/model_page_response_user_group_dto.go deleted file mode 100644 index 182d8871..00000000 --- a/harness/nextgen/model_page_response_user_group_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseUserGroupDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []UserGroupDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_page_response_user_metadata_dto.go b/harness/nextgen/model_page_response_user_metadata_dto.go deleted file mode 100644 index d381b142..00000000 --- a/harness/nextgen/model_page_response_user_metadata_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PageResponseUserMetadataDto struct { - TotalPages int64 `json:"totalPages,omitempty"` - TotalItems int64 `json:"totalItems,omitempty"` - PageItemCount int64 `json:"pageItemCount,omitempty"` - PageSize int64 `json:"pageSize,omitempty"` - Content []UserMetadataDto `json:"content,omitempty"` - PageIndex int64 `json:"pageIndex,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_pageable.go b/harness/nextgen/model_pageable.go deleted file mode 100644 index 625a9e7e..00000000 --- a/harness/nextgen/model_pageable.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type Pageable struct { - Sort *Sort `json:"sort,omitempty"` - Unpaged bool `json:"unpaged,omitempty"` - PageNumber int32 `json:"pageNumber,omitempty"` - PageSize int32 `json:"pageSize,omitempty"` - Paged bool `json:"paged,omitempty"` - Offset int64 `json:"offset,omitempty"` -} diff --git a/harness/nextgen/model_pager_duty_config_dto.go b/harness/nextgen/model_pager_duty_config_dto.go deleted file mode 100644 index 52ac6c6d..00000000 --- a/harness/nextgen/model_pager_duty_config_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PagerDutyConfigDto struct { - Type_ string `json:"type,omitempty"` - PagerDutyKey string `json:"pagerDutyKey"` -} diff --git a/harness/nextgen/model_parameter_field_double.go b/harness/nextgen/model_parameter_field_double.go deleted file mode 100644 index 31379928..00000000 --- a/harness/nextgen/model_parameter_field_double.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParameterFieldDouble struct { - ExpressionValue string `json:"expressionValue,omitempty"` - Expression bool `json:"expression,omitempty"` - Value float64 `json:"value,omitempty"` - TypeString bool `json:"typeString,omitempty"` - InputSetValidator *InputSetValidator `json:"inputSetValidator,omitempty"` - JsonResponseField bool `json:"jsonResponseField,omitempty"` - ResponseField string `json:"responseField,omitempty"` -} diff --git a/harness/nextgen/model_parameter_field_notification_channel_wrapper.go b/harness/nextgen/model_parameter_field_notification_channel_wrapper.go deleted file mode 100644 index c2aa6e24..00000000 --- a/harness/nextgen/model_parameter_field_notification_channel_wrapper.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParameterFieldNotificationChannelWrapper struct { - ExpressionValue string `json:"expressionValue,omitempty"` - Expression bool `json:"expression,omitempty"` - Value *NotificationChannelWrapper `json:"value,omitempty"` - TypeString bool `json:"typeString,omitempty"` - InputSetValidator *InputSetValidator `json:"inputSetValidator,omitempty"` - JsonResponseField bool `json:"jsonResponseField,omitempty"` - ResponseField string `json:"responseField,omitempty"` -} diff --git a/harness/nextgen/model_parameter_field_object.go b/harness/nextgen/model_parameter_field_object.go deleted file mode 100644 index d1dca8a7..00000000 --- a/harness/nextgen/model_parameter_field_object.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParameterFieldObject struct { - ExpressionValue string `json:"expressionValue,omitempty"` - Expression bool `json:"expression,omitempty"` - Value *interface{} `json:"value,omitempty"` - TypeString bool `json:"typeString,omitempty"` - InputSetValidator *InputSetValidator `json:"inputSetValidator,omitempty"` - JsonResponseField bool `json:"jsonResponseField,omitempty"` - ResponseField string `json:"responseField,omitempty"` -} diff --git a/harness/nextgen/model_parameter_field_secret_ref_data.go b/harness/nextgen/model_parameter_field_secret_ref_data.go deleted file mode 100644 index a4755754..00000000 --- a/harness/nextgen/model_parameter_field_secret_ref_data.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParameterFieldSecretRefData struct { - ExpressionValue string `json:"expressionValue,omitempty"` - Expression bool `json:"expression,omitempty"` - Value string `json:"value,omitempty"` - TypeString bool `json:"typeString,omitempty"` - InputSetValidator *InputSetValidator `json:"inputSetValidator,omitempty"` - JsonResponseField bool `json:"jsonResponseField,omitempty"` - ResponseField string `json:"responseField,omitempty"` -} diff --git a/harness/nextgen/model_parameter_field_string.go b/harness/nextgen/model_parameter_field_string.go deleted file mode 100644 index 92b2b1f7..00000000 --- a/harness/nextgen/model_parameter_field_string.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParameterFieldString struct { - ExpressionValue string `json:"expressionValue,omitempty"` - Expression bool `json:"expression,omitempty"` - Value string `json:"value,omitempty"` - TypeString bool `json:"typeString,omitempty"` - InputSetValidator *InputSetValidator `json:"inputSetValidator,omitempty"` - JsonResponseField bool `json:"jsonResponseField,omitempty"` - ResponseField string `json:"responseField,omitempty"` -} diff --git a/harness/nextgen/model_parameter_field_timeout.go b/harness/nextgen/model_parameter_field_timeout.go deleted file mode 100644 index 8f8be5eb..00000000 --- a/harness/nextgen/model_parameter_field_timeout.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParameterFieldTimeout struct { - ExpressionValue string `json:"expressionValue,omitempty"` - Expression bool `json:"expression,omitempty"` - Value string `json:"value,omitempty"` - TypeString bool `json:"typeString,omitempty"` - InputSetValidator *InputSetValidator `json:"inputSetValidator,omitempty"` - JsonResponseField bool `json:"jsonResponseField,omitempty"` - ResponseField string `json:"responseField,omitempty"` -} diff --git a/harness/nextgen/model_parser.go b/harness/nextgen/model_parser.go deleted file mode 100644 index 0c6bda28..00000000 --- a/harness/nextgen/model_parser.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type Parser struct { -} diff --git a/harness/nextgen/model_parser_bitbucket_cloud_webhook_events.go b/harness/nextgen/model_parser_bitbucket_cloud_webhook_events.go deleted file mode 100644 index 97e1d01b..00000000 --- a/harness/nextgen/model_parser_bitbucket_cloud_webhook_events.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserBitbucketCloudWebhookEvents struct { -} diff --git a/harness/nextgen/model_parser_bitbucket_server_webhook_events.go b/harness/nextgen/model_parser_bitbucket_server_webhook_events.go deleted file mode 100644 index 1e9d4366..00000000 --- a/harness/nextgen/model_parser_bitbucket_server_webhook_events.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserBitbucketServerWebhookEvents struct { -} diff --git a/harness/nextgen/model_parser_descriptor_proto.go b/harness/nextgen/model_parser_descriptor_proto.go deleted file mode 100644 index 77210ed3..00000000 --- a/harness/nextgen/model_parser_descriptor_proto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserDescriptorProto struct { -} diff --git a/harness/nextgen/model_parser_enum_descriptor_proto.go b/harness/nextgen/model_parser_enum_descriptor_proto.go deleted file mode 100644 index a61749ce..00000000 --- a/harness/nextgen/model_parser_enum_descriptor_proto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserEnumDescriptorProto struct { -} diff --git a/harness/nextgen/model_parser_enum_options.go b/harness/nextgen/model_parser_enum_options.go deleted file mode 100644 index a676e06e..00000000 --- a/harness/nextgen/model_parser_enum_options.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserEnumOptions struct { -} diff --git a/harness/nextgen/model_parser_enum_reserved_range.go b/harness/nextgen/model_parser_enum_reserved_range.go deleted file mode 100644 index 70c706a3..00000000 --- a/harness/nextgen/model_parser_enum_reserved_range.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserEnumReservedRange struct { -} diff --git a/harness/nextgen/model_parser_enum_value_descriptor_proto.go b/harness/nextgen/model_parser_enum_value_descriptor_proto.go deleted file mode 100644 index 65a6834e..00000000 --- a/harness/nextgen/model_parser_enum_value_descriptor_proto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserEnumValueDescriptorProto struct { -} diff --git a/harness/nextgen/model_parser_enum_value_options.go b/harness/nextgen/model_parser_enum_value_options.go deleted file mode 100644 index f80c5ac3..00000000 --- a/harness/nextgen/model_parser_enum_value_options.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserEnumValueOptions struct { -} diff --git a/harness/nextgen/model_parser_extension_range.go b/harness/nextgen/model_parser_extension_range.go deleted file mode 100644 index ec075dd1..00000000 --- a/harness/nextgen/model_parser_extension_range.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserExtensionRange struct { -} diff --git a/harness/nextgen/model_parser_extension_range_options.go b/harness/nextgen/model_parser_extension_range_options.go deleted file mode 100644 index cfa77ff1..00000000 --- a/harness/nextgen/model_parser_extension_range_options.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserExtensionRangeOptions struct { -} diff --git a/harness/nextgen/model_parser_field_descriptor_proto.go b/harness/nextgen/model_parser_field_descriptor_proto.go deleted file mode 100644 index 4bf117e2..00000000 --- a/harness/nextgen/model_parser_field_descriptor_proto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserFieldDescriptorProto struct { -} diff --git a/harness/nextgen/model_parser_field_options.go b/harness/nextgen/model_parser_field_options.go deleted file mode 100644 index 52956e54..00000000 --- a/harness/nextgen/model_parser_field_options.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserFieldOptions struct { -} diff --git a/harness/nextgen/model_parser_file_descriptor_proto.go b/harness/nextgen/model_parser_file_descriptor_proto.go deleted file mode 100644 index d31eca77..00000000 --- a/harness/nextgen/model_parser_file_descriptor_proto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserFileDescriptorProto struct { -} diff --git a/harness/nextgen/model_parser_file_options.go b/harness/nextgen/model_parser_file_options.go deleted file mode 100644 index d0fe3c5a..00000000 --- a/harness/nextgen/model_parser_file_options.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserFileOptions struct { -} diff --git a/harness/nextgen/model_parser_github_webhook_events.go b/harness/nextgen/model_parser_github_webhook_events.go deleted file mode 100644 index 9a79dac9..00000000 --- a/harness/nextgen/model_parser_github_webhook_events.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserGithubWebhookEvents struct { -} diff --git a/harness/nextgen/model_parser_gitlab_webhook_events.go b/harness/nextgen/model_parser_gitlab_webhook_events.go deleted file mode 100644 index 95488fc0..00000000 --- a/harness/nextgen/model_parser_gitlab_webhook_events.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserGitlabWebhookEvents struct { -} diff --git a/harness/nextgen/model_parser_location.go b/harness/nextgen/model_parser_location.go deleted file mode 100644 index fd9635dc..00000000 --- a/harness/nextgen/model_parser_location.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserLocation struct { -} diff --git a/harness/nextgen/model_parser_message.go b/harness/nextgen/model_parser_message.go deleted file mode 100644 index 858bf08c..00000000 --- a/harness/nextgen/model_parser_message.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserMessage struct { -} diff --git a/harness/nextgen/model_parser_message_lite.go b/harness/nextgen/model_parser_message_lite.go deleted file mode 100644 index 1de5ef7a..00000000 --- a/harness/nextgen/model_parser_message_lite.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserMessageLite struct { -} diff --git a/harness/nextgen/model_parser_message_options.go b/harness/nextgen/model_parser_message_options.go deleted file mode 100644 index b173ed2f..00000000 --- a/harness/nextgen/model_parser_message_options.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserMessageOptions struct { -} diff --git a/harness/nextgen/model_parser_method_descriptor_proto.go b/harness/nextgen/model_parser_method_descriptor_proto.go deleted file mode 100644 index 30b0190f..00000000 --- a/harness/nextgen/model_parser_method_descriptor_proto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserMethodDescriptorProto struct { -} diff --git a/harness/nextgen/model_parser_method_options.go b/harness/nextgen/model_parser_method_options.go deleted file mode 100644 index 2d5e9010..00000000 --- a/harness/nextgen/model_parser_method_options.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserMethodOptions struct { -} diff --git a/harness/nextgen/model_parser_name_part.go b/harness/nextgen/model_parser_name_part.go deleted file mode 100644 index 07bac297..00000000 --- a/harness/nextgen/model_parser_name_part.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserNamePart struct { -} diff --git a/harness/nextgen/model_parser_native_events.go b/harness/nextgen/model_parser_native_events.go deleted file mode 100644 index 82d290c3..00000000 --- a/harness/nextgen/model_parser_native_events.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserNativeEvents struct { -} diff --git a/harness/nextgen/model_parser_oneof_descriptor_proto.go b/harness/nextgen/model_parser_oneof_descriptor_proto.go deleted file mode 100644 index d0284555..00000000 --- a/harness/nextgen/model_parser_oneof_descriptor_proto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserOneofDescriptorProto struct { -} diff --git a/harness/nextgen/model_parser_oneof_options.go b/harness/nextgen/model_parser_oneof_options.go deleted file mode 100644 index 239367b7..00000000 --- a/harness/nextgen/model_parser_oneof_options.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserOneofOptions struct { -} diff --git a/harness/nextgen/model_parser_reserved_range.go b/harness/nextgen/model_parser_reserved_range.go deleted file mode 100644 index fedd6c84..00000000 --- a/harness/nextgen/model_parser_reserved_range.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserReservedRange struct { -} diff --git a/harness/nextgen/model_parser_service_descriptor_proto.go b/harness/nextgen/model_parser_service_descriptor_proto.go deleted file mode 100644 index 7b4adc04..00000000 --- a/harness/nextgen/model_parser_service_descriptor_proto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserServiceDescriptorProto struct { -} diff --git a/harness/nextgen/model_parser_service_options.go b/harness/nextgen/model_parser_service_options.go deleted file mode 100644 index d1d3e576..00000000 --- a/harness/nextgen/model_parser_service_options.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserServiceOptions struct { -} diff --git a/harness/nextgen/model_parser_source_code_info.go b/harness/nextgen/model_parser_source_code_info.go deleted file mode 100644 index 2cfe2b94..00000000 --- a/harness/nextgen/model_parser_source_code_info.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserSourceCodeInfo struct { -} diff --git a/harness/nextgen/model_parser_uninterpreted_option.go b/harness/nextgen/model_parser_uninterpreted_option.go deleted file mode 100644 index 58ef3d88..00000000 --- a/harness/nextgen/model_parser_uninterpreted_option.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserUninterpretedOption struct { -} diff --git a/harness/nextgen/model_parser_webhook_response.go b/harness/nextgen/model_parser_webhook_response.go deleted file mode 100644 index 077a1ca0..00000000 --- a/harness/nextgen/model_parser_webhook_response.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ParserWebhookResponse struct { -} diff --git a/harness/nextgen/model_partial_schema_dto.go b/harness/nextgen/model_partial_schema_dto.go deleted file mode 100644 index 768798f3..00000000 --- a/harness/nextgen/model_partial_schema_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PartialSchemaDto struct { - Schema *JsonNode `json:"schema,omitempty"` - NodeType string `json:"nodeType,omitempty"` - NodeName string `json:"nodeName,omitempty"` - Namespace string `json:"namespace,omitempty"` - ModuleType string `json:"moduleType,omitempty"` -} diff --git a/harness/nextgen/model_password_change_dto.go b/harness/nextgen/model_password_change_dto.go deleted file mode 100644 index 7f7b9385..00000000 --- a/harness/nextgen/model_password_change_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PasswordChangeDto struct { - CurrentPassword string `json:"currentPassword,omitempty"` - NewPassword string `json:"newPassword,omitempty"` -} diff --git a/harness/nextgen/model_pipeline_config.go b/harness/nextgen/model_pipeline_config.go deleted file mode 100644 index 8aed783b..00000000 --- a/harness/nextgen/model_pipeline_config.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PipelineConfig struct { - Pipeline *PipelineInfoConfig `json:"pipeline,omitempty"` -} diff --git a/harness/nextgen/model_pipeline_event.go b/harness/nextgen/model_pipeline_event.go deleted file mode 100644 index f44c1999..00000000 --- a/harness/nextgen/model_pipeline_event.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PipelineEvent struct { - Type_ string `json:"type,omitempty"` - ForStages []string `json:"forStages,omitempty"` -} diff --git a/harness/nextgen/model_pipeline_execution_dashboard_info.go b/harness/nextgen/model_pipeline_execution_dashboard_info.go deleted file mode 100644 index fcc0d894..00000000 --- a/harness/nextgen/model_pipeline_execution_dashboard_info.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PipelineExecutionDashboardInfo struct { - Name string `json:"name,omitempty"` - Identifier string `json:"identifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - PlanExecutionId string `json:"planExecutionId,omitempty"` - StartTs int64 `json:"startTs,omitempty"` -} diff --git a/harness/nextgen/model_pipeline_info_config.go b/harness/nextgen/model_pipeline_info_config.go deleted file mode 100644 index 894ee86f..00000000 --- a/harness/nextgen/model_pipeline_info_config.go +++ /dev/null @@ -1,26 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PipelineInfoConfig struct { - Uuid string `json:"__uuid,omitempty"` - Name string `json:"name"` - Identifier string `json:"identifier"` - FlowControl *FlowControlConfig `json:"flowControl,omitempty"` - Description *ParameterFieldString `json:"description,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Variables []NgVariable `json:"variables,omitempty"` - Properties *NgProperties `json:"properties,omitempty"` - Stages []StageElementWrapperConfig `json:"stages,omitempty"` - NotificationRules []NotificationRules `json:"notificationRules,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Timeout *ParameterFieldTimeout `json:"timeout,omitempty"` -} diff --git a/harness/nextgen/model_pipelines_execution_dashboard_info.go b/harness/nextgen/model_pipelines_execution_dashboard_info.go deleted file mode 100644 index 6a9a1ec4..00000000 --- a/harness/nextgen/model_pipelines_execution_dashboard_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PipelinesExecutionDashboardInfo struct { - RunningExecutions []PipelineExecutionDashboardInfo `json:"runningExecutions,omitempty"` - PendingApprovalExecutions []PipelineExecutionDashboardInfo `json:"pendingApprovalExecutions,omitempty"` - PendingManualInterventionExecutions []PipelineExecutionDashboardInfo `json:"pendingManualInterventionExecutions,omitempty"` - Failed24HrsExecutions []PipelineExecutionDashboardInfo `json:"failed24HrsExecutions,omitempty"` -} diff --git a/harness/nextgen/model_pms_email_channel.go b/harness/nextgen/model_pms_email_channel.go deleted file mode 100644 index e6139769..00000000 --- a/harness/nextgen/model_pms_email_channel.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PmsEmailChannel struct { - Type_ string `json:"type"` - UserGroups []string `json:"userGroups,omitempty"` - Recipients []string `json:"recipients,omitempty"` -} diff --git a/harness/nextgen/model_pms_ms_team_channel.go b/harness/nextgen/model_pms_ms_team_channel.go deleted file mode 100644 index c65db9c1..00000000 --- a/harness/nextgen/model_pms_ms_team_channel.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PmsMsTeamChannel struct { - Type_ string `json:"type"` - MsTeamKeys []string `json:"msTeamKeys,omitempty"` - UserGroups []string `json:"userGroups,omitempty"` -} diff --git a/harness/nextgen/model_pms_notification_channel.go b/harness/nextgen/model_pms_notification_channel.go deleted file mode 100644 index 24ec5f69..00000000 --- a/harness/nextgen/model_pms_notification_channel.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PmsNotificationChannel struct { - Type_ string `json:"type"` -} diff --git a/harness/nextgen/model_pms_pager_duty_channel.go b/harness/nextgen/model_pms_pager_duty_channel.go deleted file mode 100644 index 5748d92a..00000000 --- a/harness/nextgen/model_pms_pager_duty_channel.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PmsPagerDutyChannel struct { - Type_ string `json:"type"` - UserGroups []string `json:"userGroups,omitempty"` - IntegrationKey string `json:"integrationKey,omitempty"` -} diff --git a/harness/nextgen/model_pms_slack_channel.go b/harness/nextgen/model_pms_slack_channel.go deleted file mode 100644 index dcfa1a53..00000000 --- a/harness/nextgen/model_pms_slack_channel.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PmsSlackChannel struct { - Type_ string `json:"type"` - UserGroups []string `json:"userGroups,omitempty"` - WebhookUrl *ParameterFieldString `json:"webhookUrl,omitempty"` -} diff --git a/harness/nextgen/model_polling_response_dto.go b/harness/nextgen/model_polling_response_dto.go deleted file mode 100644 index 20c01c57..00000000 --- a/harness/nextgen/model_polling_response_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type PollingResponseDto struct { - PollingResponse []string `json:"pollingResponse,omitempty"` -} diff --git a/harness/nextgen/model_principal.go b/harness/nextgen/model_principal.go deleted file mode 100644 index 1aba0a28..00000000 --- a/harness/nextgen/model_principal.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type Principal struct { - Identifier string `json:"identifier,omitempty"` - Type_ string `json:"type,omitempty"` -} diff --git a/harness/nextgen/model_project_aggregate_dto.go b/harness/nextgen/model_project_aggregate_dto.go deleted file mode 100644 index b81a9e2a..00000000 --- a/harness/nextgen/model_project_aggregate_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ProjectAggregateDto struct { - ProjectResponse *ProjectResponse `json:"projectResponse"` - Organization *Organization `json:"organization,omitempty"` - HarnessManagedOrg bool `json:"harnessManagedOrg,omitempty"` - Admins []UserMetadataDto `json:"admins,omitempty"` - Collaborators []UserMetadataDto `json:"collaborators,omitempty"` -} diff --git a/harness/nextgen/model_project_dash_board_info.go b/harness/nextgen/model_project_dash_board_info.go deleted file mode 100644 index d434a1d1..00000000 --- a/harness/nextgen/model_project_dash_board_info.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ProjectDashBoardInfo struct { - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - AccountId string `json:"accountId,omitempty"` - DeploymentsCount int64 `json:"deploymentsCount,omitempty"` - DeploymentsCountChangeRate float64 `json:"deploymentsCountChangeRate,omitempty"` - SuccessDeploymentsCount int64 `json:"successDeploymentsCount,omitempty"` - FailedDeploymentsCount int64 `json:"failedDeploymentsCount,omitempty"` -} diff --git a/harness/nextgen/model_projects_dashboard_info.go b/harness/nextgen/model_projects_dashboard_info.go deleted file mode 100644 index 8b770df1..00000000 --- a/harness/nextgen/model_projects_dashboard_info.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ProjectsDashboardInfo struct { - ProjectDashBoardInfoList []ProjectDashBoardInfo `json:"projectDashBoardInfoList,omitempty"` -} diff --git a/harness/nextgen/model_rate_limit_protection.go b/harness/nextgen/model_rate_limit_protection.go new file mode 100644 index 00000000..d89d9b15 --- /dev/null +++ b/harness/nextgen/model_rate_limit_protection.go @@ -0,0 +1,17 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +type RateLimitProtection struct { + IncorrectAttemptTimestamps []int64 `json:"incorrectAttemptTimestamps,omitempty"` + LastNotificationSentToUserAt int64 `json:"lastNotificationSentToUserAt,omitempty"` + LastNotificationSentToSecOpsAt int64 `json:"lastNotificationSentToSecOpsAt,omitempty"` + TotalIncorrectAttempts int32 `json:"totalIncorrectAttempts,omitempty"` +} diff --git a/harness/nextgen/model_rate_limit_restriction.go b/harness/nextgen/model_rate_limit_restriction.go new file mode 100644 index 00000000..a1345e07 --- /dev/null +++ b/harness/nextgen/model_rate_limit_restriction.go @@ -0,0 +1,18 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the Rate Limit Restriction in Harness +type RateLimitRestriction struct { + RestrictionType string `json:"restrictionType"` + Limit int64 `json:"limit,omitempty"` + Count int64 `json:"count,omitempty"` + TimeUnit *TimeUnit `json:"timeUnit,omitempty"` +} diff --git a/harness/nextgen/model_rate_limit_restriction_dto.go b/harness/nextgen/model_rate_limit_restriction_dto.go deleted file mode 100644 index afa55456..00000000 --- a/harness/nextgen/model_rate_limit_restriction_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RateLimitRestrictionDto struct { - Limit int64 `json:"limit,omitempty"` - Count int64 `json:"count,omitempty"` - TimeUnit *TimeUnit `json:"timeUnit,omitempty"` -} diff --git a/harness/nextgen/model_rate_limit_restriction_metadata_dto.go b/harness/nextgen/model_rate_limit_restriction_metadata.go similarity index 84% rename from harness/nextgen/model_rate_limit_restriction_metadata_dto.go rename to harness/nextgen/model_rate_limit_restriction_metadata.go index 2acab306..a83f9725 100644 --- a/harness/nextgen/model_rate_limit_restriction_metadata_dto.go +++ b/harness/nextgen/model_rate_limit_restriction_metadata.go @@ -9,7 +9,8 @@ */ package nextgen -type RateLimitRestrictionMetadataDto struct { +// This contains metadata of the Rate Limit Restriction in Harness +type RateLimitRestrictionMetadata struct { RestrictionType string `json:"restrictionType,omitempty"` Limit int64 `json:"limit,omitempty"` TimeUnit *TimeUnit `json:"timeUnit,omitempty"` diff --git a/harness/nextgen/model_reserved_range.go b/harness/nextgen/model_reserved_range.go deleted file mode 100644 index e1f9d01e..00000000 --- a/harness/nextgen/model_reserved_range.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ReservedRange struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - End int32 `json:"end,omitempty"` - Start int32 `json:"start,omitempty"` - ParserForType *ParserReservedRange `json:"parserForType,omitempty"` - DefaultInstanceForType *ReservedRange `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_reserved_range_or_builder.go b/harness/nextgen/model_reserved_range_or_builder.go deleted file mode 100644 index 9b82b2ef..00000000 --- a/harness/nextgen/model_reserved_range_or_builder.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ReservedRangeOrBuilder struct { - End int32 `json:"end,omitempty"` - Start int32 `json:"start,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_resource_group.go b/harness/nextgen/model_resource_group.go deleted file mode 100644 index 26b7e6ea..00000000 --- a/harness/nextgen/model_resource_group.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResourceGroup struct { - Identifier string `json:"identifier,omitempty"` - Name string `json:"name,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_account_resources_dto.go b/harness/nextgen/model_response_dto_account_resources_dto.go deleted file mode 100644 index 56f20439..00000000 --- a/harness/nextgen/model_response_dto_account_resources_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoAccountResourcesDto struct { - Status string `json:"status,omitempty"` - Data *AccountResourcesDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_active_projects_count_dto.go b/harness/nextgen/model_response_dto_active_projects_count_dto.go deleted file mode 100644 index f12589d7..00000000 --- a/harness/nextgen/model_response_dto_active_projects_count_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoActiveProjectsCountDto struct { - Status string `json:"status,omitempty"` - Data *ActiveProjectsCountDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_active_service_instance_summary.go b/harness/nextgen/model_response_dto_active_service_instance_summary.go deleted file mode 100644 index 04ce21c4..00000000 --- a/harness/nextgen/model_response_dto_active_service_instance_summary.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoActiveServiceInstanceSummary struct { - Status string `json:"status,omitempty"` - Data *ActiveServiceInstanceSummary `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_add_users_response.go b/harness/nextgen/model_response_dto_add_users_response.go deleted file mode 100644 index 44f3c93b..00000000 --- a/harness/nextgen/model_response_dto_add_users_response.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoAddUsersResponse struct { - Status string `json:"status,omitempty"` - Data *AddUsersResponse `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_check_expiry_result_dto.go b/harness/nextgen/model_response_dto_check_expiry_result_dto.go deleted file mode 100644 index 18338333..00000000 --- a/harness/nextgen/model_response_dto_check_expiry_result_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoCheckExpiryResultDto struct { - Status string `json:"status,omitempty"` - Data *CheckExpiryResultDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_connectivity_check_summary_dto.go b/harness/nextgen/model_response_dto_connectivity_check_summary_dto.go deleted file mode 100644 index b0edbe47..00000000 --- a/harness/nextgen/model_response_dto_connectivity_check_summary_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoConnectivityCheckSummaryDto struct { - Status string `json:"status,omitempty"` - Data *ConnectivityCheckSummaryDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_json_node.go b/harness/nextgen/model_response_dto_create_pr.go similarity index 85% rename from harness/nextgen/model_response_dto_json_node.go rename to harness/nextgen/model_response_dto_create_pr.go index a4e7c4ce..ccaa9d17 100644 --- a/harness/nextgen/model_response_dto_json_node.go +++ b/harness/nextgen/model_response_dto_create_pr.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoJsonNode struct { +type ResponseDtoCreatePr struct { Status string `json:"status,omitempty"` - Data *JsonNode `json:"data,omitempty"` + Data *CreatePr `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_create_prdto.go b/harness/nextgen/model_response_dto_create_prdto.go deleted file mode 100644 index 86187afb..00000000 --- a/harness/nextgen/model_response_dto_create_prdto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoCreatePrdto struct { - Status string `json:"status,omitempty"` - Data *CreatePrdto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_dashboard_execution_status_info.go b/harness/nextgen/model_response_dto_dashboard_execution_status_info.go deleted file mode 100644 index 5c64b736..00000000 --- a/harness/nextgen/model_response_dto_dashboard_execution_status_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoDashboardExecutionStatusInfo struct { - Status string `json:"status,omitempty"` - Data *DashboardExecutionStatusInfo `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_dashboard_workload_deployment.go b/harness/nextgen/model_response_dto_dashboard_workload_deployment.go deleted file mode 100644 index 6eb5a602..00000000 --- a/harness/nextgen/model_response_dto_dashboard_workload_deployment.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoDashboardWorkloadDeployment struct { - Status string `json:"status,omitempty"` - Data *DashboardWorkloadDeployment `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_decryptable_entity.go b/harness/nextgen/model_response_dto_decryptable_entity.go deleted file mode 100644 index 25ddc1db..00000000 --- a/harness/nextgen/model_response_dto_decryptable_entity.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoDecryptableEntity struct { - Status string `json:"status,omitempty"` - Data *DecryptableEntity `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_deployment_stats_summary.go b/harness/nextgen/model_response_dto_deployment_stats_summary.go deleted file mode 100644 index d41d01fe..00000000 --- a/harness/nextgen/model_response_dto_deployment_stats_summary.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoDeploymentStatsSummary struct { - Status string `json:"status,omitempty"` - Data *DeploymentStatsSummary `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_docker_build_details_dto.go b/harness/nextgen/model_response_dto_docker_build_details_dto.go deleted file mode 100644 index cd9db056..00000000 --- a/harness/nextgen/model_response_dto_docker_build_details_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoDockerBuildDetailsDto struct { - Status string `json:"status,omitempty"` - Data *DockerBuildDetailsDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_docker_response_dto.go b/harness/nextgen/model_response_dto_docker_response_dto.go deleted file mode 100644 index 2b648286..00000000 --- a/harness/nextgen/model_response_dto_docker_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoDockerResponseDto struct { - Status string `json:"status,omitempty"` - Data *DockerResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_ecr_list_images_dto.go b/harness/nextgen/model_response_dto_ecr_list_images_dto.go deleted file mode 100644 index b4611f02..00000000 --- a/harness/nextgen/model_response_dto_ecr_list_images_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoEcrListImagesDto struct { - Status string `json:"status,omitempty"` - Data *EcrListImagesDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_ecr_response_dto.go b/harness/nextgen/model_response_dto_ecr_response_dto.go deleted file mode 100644 index a6fb5ba4..00000000 --- a/harness/nextgen/model_response_dto_ecr_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoEcrResponseDto struct { - Status string `json:"status,omitempty"` - Data *EcrResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_entity_references_dto.go b/harness/nextgen/model_response_dto_entity_references_dto.go deleted file mode 100644 index 9242297d..00000000 --- a/harness/nextgen/model_response_dto_entity_references_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoEntityReferencesDto struct { - Status string `json:"status,omitempty"` - Data *EntityReferencesDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_entity_setup_usage_dto.go b/harness/nextgen/model_response_dto_entity_setup_usage_dto.go deleted file mode 100644 index c7697347..00000000 --- a/harness/nextgen/model_response_dto_entity_setup_usage_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoEntitySetupUsageDto struct { - Status string `json:"status,omitempty"` - Data *EntitySetupUsageDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_env_build_id_and_instance_count_info_list.go b/harness/nextgen/model_response_dto_env_build_id_and_instance_count_info_list.go deleted file mode 100644 index 4fdea11f..00000000 --- a/harness/nextgen/model_response_dto_env_build_id_and_instance_count_info_list.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoEnvBuildIdAndInstanceCountInfoList struct { - Status string `json:"status,omitempty"` - Data *EnvBuildIdAndInstanceCountInfoList `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_environment_response_dto.go b/harness/nextgen/model_response_dto_environment_response_dto.go deleted file mode 100644 index 7b25fef5..00000000 --- a/harness/nextgen/model_response_dto_environment_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoEnvironmentResponseDto struct { - Status string `json:"status,omitempty"` - Data *EnvironmentResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_feature_restriction_metadata.go b/harness/nextgen/model_response_dto_feature_restriction_metadata.go deleted file mode 100644 index 4a74d912..00000000 --- a/harness/nextgen/model_response_dto_feature_restriction_metadata.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoFeatureRestrictionMetadata struct { - Status string `json:"status,omitempty"` - Data *FeatureRestrictionMetadata `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_feature_restriction_usage_dto.go b/harness/nextgen/model_response_dto_feature_restriction_usage_dto.go deleted file mode 100644 index 45d82264..00000000 --- a/harness/nextgen/model_response_dto_feature_restriction_usage_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoFeatureRestrictionUsageDto struct { - Status string `json:"status,omitempty"` - Data *FeatureRestrictionUsageDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_token_dto.go b/harness/nextgen/model_response_dto_filter.go similarity index 85% rename from harness/nextgen/model_response_dto_token_dto.go rename to harness/nextgen/model_response_dto_filter.go index 5bce5a7d..a18713c3 100644 --- a/harness/nextgen/model_response_dto_token_dto.go +++ b/harness/nextgen/model_response_dto_filter.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoTokenDto struct { +type ResponseDtoFilter struct { Status string `json:"status,omitempty"` - Data *TokenDto `json:"data,omitempty"` + Data *Filter `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_filter_dto.go b/harness/nextgen/model_response_dto_filter_dto.go deleted file mode 100644 index febe106e..00000000 --- a/harness/nextgen/model_response_dto_filter_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoFilterDto struct { - Status string `json:"status,omitempty"` - Data *FilterDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_gcr_response_dto.go b/harness/nextgen/model_response_dto_gcr_response_dto.go deleted file mode 100644 index 30f981b4..00000000 --- a/harness/nextgen/model_response_dto_gcr_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoGcrResponseDto struct { - Status string `json:"status,omitempty"` - Data *GcrResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_services_count.go b/harness/nextgen/model_response_dto_git_branch_list.go similarity index 85% rename from harness/nextgen/model_response_dto_services_count.go rename to harness/nextgen/model_response_dto_git_branch_list.go index 24ccea5b..b14f8cd9 100644 --- a/harness/nextgen/model_response_dto_services_count.go +++ b/harness/nextgen/model_response_dto_git_branch_list.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoServicesCount struct { +type ResponseDtoGitBranchList struct { Status string `json:"status,omitempty"` - Data *ServicesCount `json:"data,omitempty"` + Data *GitBranchList `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_git_branch_list_dto.go b/harness/nextgen/model_response_dto_git_branch_list_dto.go deleted file mode 100644 index cd42ee0d..00000000 --- a/harness/nextgen/model_response_dto_git_branch_list_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoGitBranchListDto struct { - Status string `json:"status,omitempty"` - Data *GitBranchListDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_git_ops_provider_response_dto.go b/harness/nextgen/model_response_dto_git_ops_provider_response_dto.go deleted file mode 100644 index 5a2db3ab..00000000 --- a/harness/nextgen/model_response_dto_git_ops_provider_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoGitOpsProviderResponseDto struct { - Status string `json:"status,omitempty"` - Data *GitOpsProviderResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_ng_activity_dto.go b/harness/nextgen/model_response_dto_git_sync_error_count.go similarity index 84% rename from harness/nextgen/model_response_dto_page_ng_activity_dto.go rename to harness/nextgen/model_response_dto_git_sync_error_count.go index 0c31509a..0bb6b2c7 100644 --- a/harness/nextgen/model_response_dto_page_ng_activity_dto.go +++ b/harness/nextgen/model_response_dto_git_sync_error_count.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoPageNgActivityDto struct { +type ResponseDtoGitSyncErrorCount struct { Status string `json:"status,omitempty"` - Data *PageNgActivityDto `json:"data,omitempty"` + Data *GitSyncErrorCount `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_git_sync_error_count_dto.go b/harness/nextgen/model_response_dto_git_sync_error_count_dto.go deleted file mode 100644 index e9d7f3d7..00000000 --- a/harness/nextgen/model_response_dto_git_sync_error_count_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoGitSyncErrorCountDto struct { - Status string `json:"status,omitempty"` - Data *GitSyncErrorCountDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_source_code_manager_dto.go b/harness/nextgen/model_response_dto_git_sync_repo_files_list.go similarity index 83% rename from harness/nextgen/model_response_dto_source_code_manager_dto.go rename to harness/nextgen/model_response_dto_git_sync_repo_files_list.go index 0cc3c037..a92b018b 100644 --- a/harness/nextgen/model_response_dto_source_code_manager_dto.go +++ b/harness/nextgen/model_response_dto_git_sync_repo_files_list.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoSourceCodeManagerDto struct { +type ResponseDtoGitSyncRepoFilesList struct { Status string `json:"status,omitempty"` - Data *SourceCodeManagerDto `json:"data,omitempty"` + Data *GitSyncRepoFilesList `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_git_sync_repo_files_list_dto.go b/harness/nextgen/model_response_dto_git_sync_repo_files_list_dto.go deleted file mode 100644 index ee6ed50b..00000000 --- a/harness/nextgen/model_response_dto_git_sync_repo_files_list_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoGitSyncRepoFilesListDto struct { - Status string `json:"status,omitempty"` - Data *GitSyncRepoFilesListDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_deployments_info.go b/harness/nextgen/model_response_dto_git_sync_settings.go similarity index 84% rename from harness/nextgen/model_response_dto_deployments_info.go rename to harness/nextgen/model_response_dto_git_sync_settings.go index 38dc2694..1b6ef13a 100644 --- a/harness/nextgen/model_response_dto_deployments_info.go +++ b/harness/nextgen/model_response_dto_git_sync_settings.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoDeploymentsInfo struct { +type ResponseDtoGitSyncSettings struct { Status string `json:"status,omitempty"` - Data *DeploymentsInfo `json:"data,omitempty"` + Data *GitSyncSettings `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_health_deployment_dashboard.go b/harness/nextgen/model_response_dto_health_deployment_dashboard.go deleted file mode 100644 index f16bdc0b..00000000 --- a/harness/nextgen/model_response_dto_health_deployment_dashboard.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoHealthDeploymentDashboard struct { - Status string `json:"status,omitempty"` - Data *HealthDeploymentDashboard `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_instances_by_build_id_list.go b/harness/nextgen/model_response_dto_instances_by_build_id_list.go deleted file mode 100644 index 22530c6f..00000000 --- a/harness/nextgen/model_response_dto_instances_by_build_id_list.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoInstancesByBuildIdList struct { - Status string `json:"status,omitempty"` - Data *InstancesByBuildIdList `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_env_count.go b/harness/nextgen/model_response_dto_invite.go similarity index 85% rename from harness/nextgen/model_response_dto_env_count.go rename to harness/nextgen/model_response_dto_invite.go index 5673d5df..619d81b1 100644 --- a/harness/nextgen/model_response_dto_env_count.go +++ b/harness/nextgen/model_response_dto_invite.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoEnvCount struct { +type ResponseDtoInvite struct { Status string `json:"status,omitempty"` - Data *EnvCount `json:"data,omitempty"` + Data *Invite `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_invite_dto.go b/harness/nextgen/model_response_dto_invite_dto.go deleted file mode 100644 index e2185368..00000000 --- a/harness/nextgen/model_response_dto_invite_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoInviteDto struct { - Status string `json:"status,omitempty"` - Data *InviteDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_jira_issue_create_metadata_ng.go b/harness/nextgen/model_response_dto_jira_issue_create_metadata_ng.go deleted file mode 100644 index 919ab771..00000000 --- a/harness/nextgen/model_response_dto_jira_issue_create_metadata_ng.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoJiraIssueCreateMetadataNg struct { - Status string `json:"status,omitempty"` - Data *JiraIssueCreateMetadataNg `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_api_key_dto.go b/harness/nextgen/model_response_dto_list_api_key_dto.go deleted file mode 100644 index e67d3a1e..00000000 --- a/harness/nextgen/model_response_dto_list_api_key_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListApiKeyDto struct { - Status string `json:"status,omitempty"` - Data []ApiKeyDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_encrypted_data_detail.go b/harness/nextgen/model_response_dto_list_encrypted_data_detail.go deleted file mode 100644 index 4ccbdaea..00000000 --- a/harness/nextgen/model_response_dto_list_encrypted_data_detail.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListEncryptedDataDetail struct { - Status string `json:"status,omitempty"` - Data []EncryptedDataDetail `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_entity_setup_usage_dto.go b/harness/nextgen/model_response_dto_list_entity_setup_usage_dto.go deleted file mode 100644 index 7805e9f2..00000000 --- a/harness/nextgen/model_response_dto_list_entity_setup_usage_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListEntitySetupUsageDto struct { - Status string `json:"status,omitempty"` - Data []EntitySetupUsageDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_execution_status.go b/harness/nextgen/model_response_dto_list_execution_status.go deleted file mode 100644 index 76ca01c2..00000000 --- a/harness/nextgen/model_response_dto_list_execution_status.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListExecutionStatus struct { - Status string `json:"status,omitempty"` - Data []string `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_gcr_build_details_dto.go b/harness/nextgen/model_response_dto_list_git_sync_entity_list.go similarity index 83% rename from harness/nextgen/model_response_dto_gcr_build_details_dto.go rename to harness/nextgen/model_response_dto_list_git_sync_entity_list.go index f21070a3..c649cf5e 100644 --- a/harness/nextgen/model_response_dto_gcr_build_details_dto.go +++ b/harness/nextgen/model_response_dto_list_git_sync_entity_list.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoGcrBuildDetailsDto struct { +type ResponseDtoListGitSyncEntityList struct { Status string `json:"status,omitempty"` - Data *GcrBuildDetailsDto `json:"data,omitempty"` + Data []GitSyncEntityList `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_list_git_sync_entity_list_dto.go b/harness/nextgen/model_response_dto_list_git_sync_entity_list_dto.go deleted file mode 100644 index 29967937..00000000 --- a/harness/nextgen/model_response_dto_list_git_sync_entity_list_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListGitSyncEntityListDto struct { - Status string `json:"status,omitempty"` - Data []GitSyncEntityListDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_jira_project_basic_ng.go b/harness/nextgen/model_response_dto_list_jira_project_basic_ng.go deleted file mode 100644 index 374e5c21..00000000 --- a/harness/nextgen/model_response_dto_list_jira_project_basic_ng.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListJiraProjectBasicNg struct { - Status string `json:"status,omitempty"` - Data []JiraProjectBasicNg `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_jira_status_ng.go b/harness/nextgen/model_response_dto_list_jira_status_ng.go deleted file mode 100644 index e98914dd..00000000 --- a/harness/nextgen/model_response_dto_list_jira_status_ng.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListJiraStatusNg struct { - Status string `json:"status,omitempty"` - Data []JiraStatusNg `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_project.go b/harness/nextgen/model_response_dto_list_project.go deleted file mode 100644 index 05df271f..00000000 --- a/harness/nextgen/model_response_dto_list_project.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListProject struct { - Status string `json:"status,omitempty"` - Data []Project `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_role_assignment_response.go b/harness/nextgen/model_response_dto_list_role_assignment_response.go deleted file mode 100644 index 13f1d09e..00000000 --- a/harness/nextgen/model_response_dto_list_role_assignment_response.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListRoleAssignmentResponse struct { - Status string `json:"status,omitempty"` - Data []RoleAssignmentResponse `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_service_account_dto.go b/harness/nextgen/model_response_dto_list_service_account_dto.go deleted file mode 100644 index c3b461a2..00000000 --- a/harness/nextgen/model_response_dto_list_service_account_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListServiceAccountDto struct { - Status string `json:"status,omitempty"` - Data []ServiceAccountDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_service_definition_type.go b/harness/nextgen/model_response_dto_list_service_definition_type.go deleted file mode 100644 index 6752aa40..00000000 --- a/harness/nextgen/model_response_dto_list_service_definition_type.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListServiceDefinitionType struct { - Status string `json:"status,omitempty"` - Data []string `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_git_sync_settings_dto.go b/harness/nextgen/model_response_dto_list_source_code_manager.go similarity index 83% rename from harness/nextgen/model_response_dto_git_sync_settings_dto.go rename to harness/nextgen/model_response_dto_list_source_code_manager.go index e3370ffb..4cbae63b 100644 --- a/harness/nextgen/model_response_dto_git_sync_settings_dto.go +++ b/harness/nextgen/model_response_dto_list_source_code_manager.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoGitSyncSettingsDto struct { +type ResponseDtoListSourceCodeManager struct { Status string `json:"status,omitempty"` - Data *GitSyncSettingsDto `json:"data,omitempty"` + Data []SourceCodeManager `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_list_source_code_manager_dto.go b/harness/nextgen/model_response_dto_list_source_code_manager_dto.go deleted file mode 100644 index 719f5f94..00000000 --- a/harness/nextgen/model_response_dto_list_source_code_manager_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListSourceCodeManagerDto struct { - Status string `json:"status,omitempty"` - Data []SourceCodeManagerDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_user_group_aggregate_dto.go b/harness/nextgen/model_response_dto_list_user_group_aggregate_dto.go deleted file mode 100644 index f0fe4614..00000000 --- a/harness/nextgen/model_response_dto_list_user_group_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListUserGroupAggregateDto struct { - Status string `json:"status,omitempty"` - Data []UserGroupAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_list_user_group_dto.go b/harness/nextgen/model_response_dto_list_user_group_dto.go deleted file mode 100644 index b80f524a..00000000 --- a/harness/nextgen/model_response_dto_list_user_group_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoListUserGroupDto struct { - Status string `json:"status,omitempty"` - Data []UserGroupDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_jira_issue_update_metadata_ng.go b/harness/nextgen/model_response_dto_map_edition_set_edition_action.go similarity index 83% rename from harness/nextgen/model_response_dto_jira_issue_update_metadata_ng.go rename to harness/nextgen/model_response_dto_map_edition_set_edition_action.go index 830ba1ac..6d62913d 100644 --- a/harness/nextgen/model_response_dto_jira_issue_update_metadata_ng.go +++ b/harness/nextgen/model_response_dto_map_edition_set_edition_action.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoJiraIssueUpdateMetadataNg struct { +type ResponseDtoMapEditionSetEditionAction struct { Status string `json:"status,omitempty"` - Data *JiraIssueUpdateMetadataNg `json:"data,omitempty"` + Data map[string][]EditionAction `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_map_edition_set_edition_action_dto.go b/harness/nextgen/model_response_dto_map_edition_set_edition_action_dto.go deleted file mode 100644 index cb487f90..00000000 --- a/harness/nextgen/model_response_dto_map_edition_set_edition_action_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoMapEditionSetEditionActionDto struct { - Status string `json:"status,omitempty"` - Data map[string][]EditionActionDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_yaml_snippets_dto.go b/harness/nextgen/model_response_dto_map_module_type_long.go similarity index 84% rename from harness/nextgen/model_response_dto_yaml_snippets_dto.go rename to harness/nextgen/model_response_dto_map_module_type_long.go index bcc94311..1d896de6 100644 --- a/harness/nextgen/model_response_dto_yaml_snippets_dto.go +++ b/harness/nextgen/model_response_dto_map_module_type_long.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoYamlSnippetsDto struct { +type ResponseDtoMapModuleTypeLong struct { Status string `json:"status,omitempty"` - Data *YamlSnippetsDto `json:"data,omitempty"` + Data map[string]int64 `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_map_service_definition_type_list_execution_strategy_type.go b/harness/nextgen/model_response_dto_map_service_definition_type_list_execution_strategy_type.go deleted file mode 100644 index b0fa1a7d..00000000 --- a/harness/nextgen/model_response_dto_map_service_definition_type_list_execution_strategy_type.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoMapServiceDefinitionTypeListExecutionStrategyType struct { - Status string `json:"status,omitempty"` - Data map[string][]string `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_map_string_string.go b/harness/nextgen/model_response_dto_map_string_string.go deleted file mode 100644 index d9b014ce..00000000 --- a/harness/nextgen/model_response_dto_map_string_string.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoMapStringString struct { - Status string `json:"status,omitempty"` - Data map[string]string `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_optional_harness_service_info_ng.go b/harness/nextgen/model_response_dto_optional_harness_service_info_ng.go deleted file mode 100644 index c055094d..00000000 --- a/harness/nextgen/model_response_dto_optional_harness_service_info_ng.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoOptionalHarnessServiceInfoNg struct { - Status string `json:"status,omitempty"` - Data *HarnessServiceInfoNg `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_api_key_dto.go b/harness/nextgen/model_response_dto_optional_invite.go similarity index 85% rename from harness/nextgen/model_response_dto_api_key_dto.go rename to harness/nextgen/model_response_dto_optional_invite.go index 04c499b1..ddacf778 100644 --- a/harness/nextgen/model_response_dto_api_key_dto.go +++ b/harness/nextgen/model_response_dto_optional_invite.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoApiKeyDto struct { +type ResponseDtoOptionalInvite struct { Status string `json:"status,omitempty"` - Data *ApiKeyDto `json:"data,omitempty"` + Data *Invite `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_optional_invite_dto.go b/harness/nextgen/model_response_dto_optional_invite_dto.go deleted file mode 100644 index a1706b1d..00000000 --- a/harness/nextgen/model_response_dto_optional_invite_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoOptionalInviteDto struct { - Status string `json:"status,omitempty"` - Data *InviteDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_entity_setup_usage_dto.go b/harness/nextgen/model_response_dto_page_entity_setup_usage_dto.go deleted file mode 100644 index 83d2bd49..00000000 --- a/harness/nextgen/model_response_dto_page_entity_setup_usage_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageEntitySetupUsageDto struct { - Status string `json:"status,omitempty"` - Data *PageEntitySetupUsageDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_ng_activity_summary_dto.go b/harness/nextgen/model_response_dto_page_ng_activity_summary_dto.go deleted file mode 100644 index ff8f4c1e..00000000 --- a/harness/nextgen/model_response_dto_page_ng_activity_summary_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageNgActivitySummaryDto struct { - Status string `json:"status,omitempty"` - Data *PageNgActivitySummaryDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_api_key_aggregate_dto.go b/harness/nextgen/model_response_dto_page_response_api_key_aggregate_dto.go deleted file mode 100644 index 49066e62..00000000 --- a/harness/nextgen/model_response_dto_page_response_api_key_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseApiKeyAggregateDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseApiKeyAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_environment_response_dto.go b/harness/nextgen/model_response_dto_page_response_environment_response_dto.go deleted file mode 100644 index bbd5b16d..00000000 --- a/harness/nextgen/model_response_dto_page_response_environment_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseEnvironmentResponseDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseEnvironmentResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_api_key_aggregate_dto.go b/harness/nextgen/model_response_dto_page_response_filter.go similarity index 84% rename from harness/nextgen/model_response_dto_api_key_aggregate_dto.go rename to harness/nextgen/model_response_dto_page_response_filter.go index a346599f..66dc82ac 100644 --- a/harness/nextgen/model_response_dto_api_key_aggregate_dto.go +++ b/harness/nextgen/model_response_dto_page_response_filter.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoApiKeyAggregateDto struct { +type ResponseDtoPageResponseFilter struct { Status string `json:"status,omitempty"` - Data *ApiKeyAggregateDto `json:"data,omitempty"` + Data *PageResponseFilter `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_page_response_filter_dto.go b/harness/nextgen/model_response_dto_page_response_filter_dto.go deleted file mode 100644 index f6116de3..00000000 --- a/harness/nextgen/model_response_dto_page_response_filter_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseFilterDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseFilterDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_git_ops_provider_response_dto.go b/harness/nextgen/model_response_dto_page_response_git_ops_provider_response_dto.go deleted file mode 100644 index 4c750e79..00000000 --- a/harness/nextgen/model_response_dto_page_response_git_ops_provider_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseGitOpsProviderResponseDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseGitOpsProviderResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_token_aggregate_dto.go b/harness/nextgen/model_response_dto_page_response_git_sync_entity_list.go similarity index 83% rename from harness/nextgen/model_response_dto_page_response_token_aggregate_dto.go rename to harness/nextgen/model_response_dto_page_response_git_sync_entity_list.go index aef57ff9..69876ad9 100644 --- a/harness/nextgen/model_response_dto_page_response_token_aggregate_dto.go +++ b/harness/nextgen/model_response_dto_page_response_git_sync_entity_list.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoPageResponseTokenAggregateDto struct { +type ResponseDtoPageResponseGitSyncEntityList struct { Status string `json:"status,omitempty"` - Data *PageResponseTokenAggregateDto `json:"data,omitempty"` + Data *PageResponseGitSyncEntityList `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_page_response_git_sync_entity_list_dto.go b/harness/nextgen/model_response_dto_page_response_git_sync_entity_list_dto.go deleted file mode 100644 index a3499d5d..00000000 --- a/harness/nextgen/model_response_dto_page_response_git_sync_entity_list_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseGitSyncEntityListDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseGitSyncEntityListDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_secret_manager_metadata_dto.go b/harness/nextgen/model_response_dto_page_response_git_sync_error.go similarity index 83% rename from harness/nextgen/model_response_dto_secret_manager_metadata_dto.go rename to harness/nextgen/model_response_dto_page_response_git_sync_error.go index 09920f1f..e92f6028 100644 --- a/harness/nextgen/model_response_dto_secret_manager_metadata_dto.go +++ b/harness/nextgen/model_response_dto_page_response_git_sync_error.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoSecretManagerMetadataDto struct { +type ResponseDtoPageResponseGitSyncError struct { Status string `json:"status,omitempty"` - Data *SecretManagerMetadataDto `json:"data,omitempty"` + Data *PageResponseGitSyncError `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_instance_count_details_by_env_type_and_service_id.go b/harness/nextgen/model_response_dto_page_response_git_sync_error_aggregate_by_commit.go similarity index 83% rename from harness/nextgen/model_response_dto_instance_count_details_by_env_type_and_service_id.go rename to harness/nextgen/model_response_dto_page_response_git_sync_error_aggregate_by_commit.go index 3db2e3ad..145a42e5 100644 --- a/harness/nextgen/model_response_dto_instance_count_details_by_env_type_and_service_id.go +++ b/harness/nextgen/model_response_dto_page_response_git_sync_error_aggregate_by_commit.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoInstanceCountDetailsByEnvTypeAndServiceId struct { +type ResponseDtoPageResponseGitSyncErrorAggregateByCommit struct { Status string `json:"status,omitempty"` - Data *InstanceCountDetailsByEnvTypeAndServiceId `json:"data,omitempty"` + Data *PageResponseGitSyncErrorAggregateByCommit `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_page_response_git_sync_error_aggregate_by_commit_dto.go b/harness/nextgen/model_response_dto_page_response_git_sync_error_aggregate_by_commit_dto.go deleted file mode 100644 index eafb2fc3..00000000 --- a/harness/nextgen/model_response_dto_page_response_git_sync_error_aggregate_by_commit_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseGitSyncErrorAggregateByCommitDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseGitSyncErrorAggregateByCommitDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_git_sync_error_dto.go b/harness/nextgen/model_response_dto_page_response_git_sync_error_dto.go deleted file mode 100644 index b7b04e48..00000000 --- a/harness/nextgen/model_response_dto_page_response_git_sync_error_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseGitSyncErrorDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseGitSyncErrorDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_ecr_build_details_dto.go b/harness/nextgen/model_response_dto_page_response_invite.go similarity index 84% rename from harness/nextgen/model_response_dto_ecr_build_details_dto.go rename to harness/nextgen/model_response_dto_page_response_invite.go index b22d2173..e6390c8c 100644 --- a/harness/nextgen/model_response_dto_ecr_build_details_dto.go +++ b/harness/nextgen/model_response_dto_page_response_invite.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoEcrBuildDetailsDto struct { +type ResponseDtoPageResponseInvite struct { Status string `json:"status,omitempty"` - Data *EcrBuildDetailsDto `json:"data,omitempty"` + Data *PageResponseInvite `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_page_response_invite_dto.go b/harness/nextgen/model_response_dto_page_response_invite_dto.go deleted file mode 100644 index 922b5866..00000000 --- a/harness/nextgen/model_response_dto_page_response_invite_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseInviteDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseInviteDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_organization_aggregate_dto.go b/harness/nextgen/model_response_dto_page_response_organization_aggregate_dto.go deleted file mode 100644 index abe5943c..00000000 --- a/harness/nextgen/model_response_dto_page_response_organization_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseOrganizationAggregateDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseOrganizationAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_project.go b/harness/nextgen/model_response_dto_page_response_project.go deleted file mode 100644 index a5c1bb69..00000000 --- a/harness/nextgen/model_response_dto_page_response_project.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseProject struct { - Status string `json:"status,omitempty"` - Data *PageResponseProject `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_project_aggregate_dto.go b/harness/nextgen/model_response_dto_page_response_project_aggregate_dto.go deleted file mode 100644 index 09366173..00000000 --- a/harness/nextgen/model_response_dto_page_response_project_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseProjectAggregateDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseProjectAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_role_assignment_response.go b/harness/nextgen/model_response_dto_page_response_role_assignment_response.go deleted file mode 100644 index 388bab67..00000000 --- a/harness/nextgen/model_response_dto_page_response_role_assignment_response.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseRoleAssignmentResponse struct { - Status string `json:"status,omitempty"` - Data *PageResponseRoleAssignmentResponse `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_secret_response_wrapper.go b/harness/nextgen/model_response_dto_page_response_secret_response_wrapper.go deleted file mode 100644 index 4604ae21..00000000 --- a/harness/nextgen/model_response_dto_page_response_secret_response_wrapper.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseSecretResponseWrapper struct { - Status string `json:"status,omitempty"` - Data *PageResponseSecretResponseWrapper `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_service_account_aggregate_dto.go b/harness/nextgen/model_response_dto_page_response_service_account_aggregate_dto.go deleted file mode 100644 index 1a061088..00000000 --- a/harness/nextgen/model_response_dto_page_response_service_account_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseServiceAccountAggregateDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseServiceAccountAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_service_response_dto.go b/harness/nextgen/model_response_dto_page_response_service_response_dto.go deleted file mode 100644 index 35dfd5b5..00000000 --- a/harness/nextgen/model_response_dto_page_response_service_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseServiceResponseDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseServiceResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_user_aggregate_dto.go b/harness/nextgen/model_response_dto_page_response_user_aggregate_dto.go deleted file mode 100644 index ff504088..00000000 --- a/harness/nextgen/model_response_dto_page_response_user_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseUserAggregateDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseUserAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_user_group_aggregate_dto.go b/harness/nextgen/model_response_dto_page_response_user_group_aggregate_dto.go deleted file mode 100644 index c6d0b77e..00000000 --- a/harness/nextgen/model_response_dto_page_response_user_group_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseUserGroupAggregateDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseUserGroupAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_user_group_dto.go b/harness/nextgen/model_response_dto_page_response_user_group_dto.go deleted file mode 100644 index f076cca4..00000000 --- a/harness/nextgen/model_response_dto_page_response_user_group_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseUserGroupDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseUserGroupDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_page_response_user_metadata_dto.go b/harness/nextgen/model_response_dto_page_response_user_metadata_dto.go deleted file mode 100644 index 28b51a55..00000000 --- a/harness/nextgen/model_response_dto_page_response_user_metadata_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPageResponseUserMetadataDto struct { - Status string `json:"status,omitempty"` - Data *PageResponseUserMetadataDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_partial_schema_dto.go b/harness/nextgen/model_response_dto_partial_schema_dto.go deleted file mode 100644 index 7416bed5..00000000 --- a/harness/nextgen/model_response_dto_partial_schema_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPartialSchemaDto struct { - Status string `json:"status,omitempty"` - Data *PartialSchemaDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_password_change_response.go b/harness/nextgen/model_response_dto_password_change_response.go deleted file mode 100644 index b6d95e8f..00000000 --- a/harness/nextgen/model_response_dto_password_change_response.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPasswordChangeResponse struct { - Status string `json:"status,omitempty"` - Data string `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_pipeline_config.go b/harness/nextgen/model_response_dto_pipeline_config.go deleted file mode 100644 index 58e374ff..00000000 --- a/harness/nextgen/model_response_dto_pipeline_config.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPipelineConfig struct { - Status string `json:"status,omitempty"` - Data *PipelineConfig `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_pipelines_execution_dashboard_info.go b/harness/nextgen/model_response_dto_pipelines_execution_dashboard_info.go deleted file mode 100644 index d8ec1602..00000000 --- a/harness/nextgen/model_response_dto_pipelines_execution_dashboard_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPipelinesExecutionDashboardInfo struct { - Status string `json:"status,omitempty"` - Data *PipelinesExecutionDashboardInfo `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_polling_response_dto.go b/harness/nextgen/model_response_dto_polling_response_dto.go deleted file mode 100644 index b493659e..00000000 --- a/harness/nextgen/model_response_dto_polling_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoPollingResponseDto struct { - Status string `json:"status,omitempty"` - Data *PollingResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_project_aggregate_dto.go b/harness/nextgen/model_response_dto_project_aggregate_dto.go deleted file mode 100644 index caab6af9..00000000 --- a/harness/nextgen/model_response_dto_project_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoProjectAggregateDto struct { - Status string `json:"status,omitempty"` - Data *ProjectAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_projects_dashboard_info.go b/harness/nextgen/model_response_dto_projects_dashboard_info.go deleted file mode 100644 index 3aadc811..00000000 --- a/harness/nextgen/model_response_dto_projects_dashboard_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoProjectsDashboardInfo struct { - Status string `json:"status,omitempty"` - Data *ProjectsDashboardInfo `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_restriction_metadata_map_response_dto.go b/harness/nextgen/model_response_dto_restriction_metadata_map_response_dto.go deleted file mode 100644 index 8964236d..00000000 --- a/harness/nextgen/model_response_dto_restriction_metadata_map_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoRestrictionMetadataMapResponseDto struct { - Status string `json:"status,omitempty"` - Data *RestrictionMetadataMapResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_role_assignment_aggregate_response.go b/harness/nextgen/model_response_dto_role_assignment_aggregate_response.go deleted file mode 100644 index b0c91f65..00000000 --- a/harness/nextgen/model_response_dto_role_assignment_aggregate_response.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoRoleAssignmentAggregateResponse struct { - Status string `json:"status,omitempty"` - Data *RoleAssignmentAggregateResponse `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_role_assignment_response.go b/harness/nextgen/model_response_dto_role_assignment_response.go deleted file mode 100644 index 91825f59..00000000 --- a/harness/nextgen/model_response_dto_role_assignment_response.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoRoleAssignmentResponse struct { - Status string `json:"status,omitempty"` - Data *RoleAssignmentResponse `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_secret_manager_config_dto.go b/harness/nextgen/model_response_dto_secret_manager_config_dto.go deleted file mode 100644 index 5a6841fa..00000000 --- a/harness/nextgen/model_response_dto_secret_manager_config_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoSecretManagerConfigDto struct { - Status string `json:"status,omitempty"` - Data *SecretManagerConfigDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_secret_response_wrapper.go b/harness/nextgen/model_response_dto_secret_response_wrapper.go deleted file mode 100644 index 516cd316..00000000 --- a/harness/nextgen/model_response_dto_secret_response_wrapper.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoSecretResponseWrapper struct { - Status string `json:"status,omitempty"` - Data *SecretResponseWrapper `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_secret_validation_result_dto.go b/harness/nextgen/model_response_dto_secret_validation_result_dto.go deleted file mode 100644 index c2298d01..00000000 --- a/harness/nextgen/model_response_dto_secret_validation_result_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoSecretValidationResultDto struct { - Status string `json:"status,omitempty"` - Data *SecretValidationResultDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_service_account_aggregate_dto.go b/harness/nextgen/model_response_dto_service_account_aggregate_dto.go deleted file mode 100644 index 6e3bc90b..00000000 --- a/harness/nextgen/model_response_dto_service_account_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoServiceAccountAggregateDto struct { - Status string `json:"status,omitempty"` - Data *ServiceAccountAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_service_deployment_info_dto.go b/harness/nextgen/model_response_dto_service_deployment_info_dto.go deleted file mode 100644 index 54e3d558..00000000 --- a/harness/nextgen/model_response_dto_service_deployment_info_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoServiceDeploymentInfoDto struct { - Status string `json:"status,omitempty"` - Data *ServiceDeploymentInfoDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_service_deployment_list_info.go b/harness/nextgen/model_response_dto_service_deployment_list_info.go deleted file mode 100644 index 95ece708..00000000 --- a/harness/nextgen/model_response_dto_service_deployment_list_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoServiceDeploymentListInfo struct { - Status string `json:"status,omitempty"` - Data *ServiceDeploymentListInfo `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_service_details_info_dto.go b/harness/nextgen/model_response_dto_service_details_info_dto.go deleted file mode 100644 index 0badb10c..00000000 --- a/harness/nextgen/model_response_dto_service_details_info_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoServiceDetailsInfoDto struct { - Status string `json:"status,omitempty"` - Data *ServiceDetailsInfoDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_service_header_info.go b/harness/nextgen/model_response_dto_service_header_info.go deleted file mode 100644 index 2729ee16..00000000 --- a/harness/nextgen/model_response_dto_service_header_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoServiceHeaderInfo struct { - Status string `json:"status,omitempty"` - Data *ServiceHeaderInfo `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_service_response_dto.go b/harness/nextgen/model_response_dto_service_response_dto.go deleted file mode 100644 index f5b3bd19..00000000 --- a/harness/nextgen/model_response_dto_service_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoServiceResponseDto struct { - Status string `json:"status,omitempty"` - Data *ServiceResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_services_dashboard_info.go b/harness/nextgen/model_response_dto_services_dashboard_info.go deleted file mode 100644 index 858cb930..00000000 --- a/harness/nextgen/model_response_dto_services_dashboard_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoServicesDashboardInfo struct { - Status string `json:"status,omitempty"` - Data *ServicesDashboardInfo `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_service_account_dto.go b/harness/nextgen/model_response_dto_source_code_manager.go similarity index 84% rename from harness/nextgen/model_response_dto_service_account_dto.go rename to harness/nextgen/model_response_dto_source_code_manager.go index 34014258..c963cf7e 100644 --- a/harness/nextgen/model_response_dto_service_account_dto.go +++ b/harness/nextgen/model_response_dto_source_code_manager.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoServiceAccountDto struct { +type ResponseDtoSourceCodeManager struct { Status string `json:"status,omitempty"` - Data *ServiceAccountDto `json:"data,omitempty"` + Data *SourceCodeManager `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_step_category.go b/harness/nextgen/model_response_dto_step_category.go deleted file mode 100644 index 797d74a5..00000000 --- a/harness/nextgen/model_response_dto_step_category.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoStepCategory struct { - Status string `json:"status,omitempty"` - Data *StepCategory `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_time_value_pair_list_dto_env_id_count_pair.go b/harness/nextgen/model_response_dto_time_value_pair_list_dto_env_id_count_pair.go deleted file mode 100644 index 16a68a68..00000000 --- a/harness/nextgen/model_response_dto_time_value_pair_list_dto_env_id_count_pair.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoTimeValuePairListDtoEnvIdCountPair struct { - Status string `json:"status,omitempty"` - Data *TimeValuePairListDtoEnvIdCountPair `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_time_value_pair_list_dto_integer.go b/harness/nextgen/model_response_dto_time_value_pair_list_dto_integer.go deleted file mode 100644 index 748b2019..00000000 --- a/harness/nextgen/model_response_dto_time_value_pair_list_dto_integer.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoTimeValuePairListDtoInteger struct { - Status string `json:"status,omitempty"` - Data *TimeValuePairListDtoInteger `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_execution_deployment_info.go b/harness/nextgen/model_response_dto_trigger_full_sync_response.go similarity index 83% rename from harness/nextgen/model_response_dto_execution_deployment_info.go rename to harness/nextgen/model_response_dto_trigger_full_sync_response.go index 8e935778..c1e15d41 100644 --- a/harness/nextgen/model_response_dto_execution_deployment_info.go +++ b/harness/nextgen/model_response_dto_trigger_full_sync_response.go @@ -9,9 +9,9 @@ */ package nextgen -type ResponseDtoExecutionDeploymentInfo struct { +type ResponseDtoTriggerFullSyncResponse struct { Status string `json:"status,omitempty"` - Data *ExecutionDeploymentInfo `json:"data,omitempty"` + Data *TriggerFullSyncResponse `json:"data,omitempty"` MetaData *interface{} `json:"metaData,omitempty"` CorrelationId string `json:"correlationId,omitempty"` } diff --git a/harness/nextgen/model_response_dto_two_factor_auth_settings_info.go b/harness/nextgen/model_response_dto_two_factor_auth_settings_info.go deleted file mode 100644 index 31ab9297..00000000 --- a/harness/nextgen/model_response_dto_two_factor_auth_settings_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoTwoFactorAuthSettingsInfo struct { - Status string `json:"status,omitempty"` - Data *TwoFactorAuthSettingsInfo `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_upsert_webhook_response_dto.go b/harness/nextgen/model_response_dto_upsert_webhook_response_dto.go deleted file mode 100644 index 5974ab82..00000000 --- a/harness/nextgen/model_response_dto_upsert_webhook_response_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoUpsertWebhookResponseDto struct { - Status string `json:"status,omitempty"` - Data *UpsertWebhookResponseDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_user_aggregate_dto.go b/harness/nextgen/model_response_dto_user_aggregate_dto.go deleted file mode 100644 index 360e0000..00000000 --- a/harness/nextgen/model_response_dto_user_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoUserAggregateDto struct { - Status string `json:"status,omitempty"` - Data *UserAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_user_group_aggregate_dto.go b/harness/nextgen/model_response_dto_user_group_aggregate_dto.go deleted file mode 100644 index a729151b..00000000 --- a/harness/nextgen/model_response_dto_user_group_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoUserGroupAggregateDto struct { - Status string `json:"status,omitempty"` - Data *UserGroupAggregateDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dto_user_group_dto.go b/harness/nextgen/model_response_dto_user_group_dto.go deleted file mode 100644 index 83eace56..00000000 --- a/harness/nextgen/model_response_dto_user_group_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtoUserGroupDto struct { - Status string `json:"status,omitempty"` - Data *UserGroupDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dtocd_pipeline_module_info.go b/harness/nextgen/model_response_dtocd_pipeline_module_info.go deleted file mode 100644 index 80039561..00000000 --- a/harness/nextgen/model_response_dtocd_pipeline_module_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtocdPipelineModuleInfo struct { - Status string `json:"status,omitempty"` - Data *CdPipelineModuleInfo `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dtocd_stage_module_info.go b/harness/nextgen/model_response_dtocd_stage_module_info.go deleted file mode 100644 index 8d8ba488..00000000 --- a/harness/nextgen/model_response_dtocd_stage_module_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtocdStageModuleInfo struct { - Status string `json:"status,omitempty"` - Data *CdStageModuleInfo `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_response_dtong_activity_dto.go b/harness/nextgen/model_response_dtong_activity_dto.go deleted file mode 100644 index 5ba3955b..00000000 --- a/harness/nextgen/model_response_dtong_activity_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ResponseDtongActivityDto struct { - Status string `json:"status,omitempty"` - Data *NgActivityDto `json:"data,omitempty"` - MetaData *interface{} `json:"metaData,omitempty"` - CorrelationId string `json:"correlationId,omitempty"` -} diff --git a/harness/nextgen/model_rest_response_user_group.go b/harness/nextgen/model_rest_response_user_group.go deleted file mode 100644 index ed03988b..00000000 --- a/harness/nextgen/model_rest_response_user_group.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RestResponseUserGroup struct { - MetaData map[string]interface{} `json:"metaData,omitempty"` - Resource *UserGroup `json:"resource,omitempty"` - ResponseMessages []ResponseMessage `json:"responseMessages,omitempty"` -} diff --git a/harness/nextgen/model_rest_response_user_info.go b/harness/nextgen/model_rest_response_user_info.go deleted file mode 100644 index 395c9023..00000000 --- a/harness/nextgen/model_rest_response_user_info.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RestResponseUserInfo struct { - MetaData map[string]interface{} `json:"metaData,omitempty"` - Resource *UserInfo `json:"resource,omitempty"` - ResponseMessages []ResponseMessage `json:"responseMessages,omitempty"` -} diff --git a/harness/nextgen/model_restriction.go b/harness/nextgen/model_restriction.go new file mode 100644 index 00000000..3d2a320d --- /dev/null +++ b/harness/nextgen/model_restriction.go @@ -0,0 +1,15 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the Restriction in Harness +type Restriction struct { + RestrictionType string `json:"restrictionType"` +} diff --git a/harness/nextgen/model_restriction_dto.go b/harness/nextgen/model_restriction_dto.go deleted file mode 100644 index 3cb685d0..00000000 --- a/harness/nextgen/model_restriction_dto.go +++ /dev/null @@ -1,13 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RestrictionDto struct { -} diff --git a/harness/nextgen/model_custom_restriction_metadata_dto.go b/harness/nextgen/model_restriction_metadata.go similarity index 82% rename from harness/nextgen/model_custom_restriction_metadata_dto.go rename to harness/nextgen/model_restriction_metadata.go index c01d91f9..800fee48 100644 --- a/harness/nextgen/model_custom_restriction_metadata_dto.go +++ b/harness/nextgen/model_restriction_metadata.go @@ -9,6 +9,7 @@ */ package nextgen -type CustomRestrictionMetadataDto struct { +// This contains metadata of the Restriction in Harness +type RestrictionMetadata struct { RestrictionType string `json:"restrictionType,omitempty"` } diff --git a/harness/nextgen/model_restriction_metadata_map_request_dto.go b/harness/nextgen/model_restriction_metadata_map_request_dto.go deleted file mode 100644 index 5040ab9f..00000000 --- a/harness/nextgen/model_restriction_metadata_map_request_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RestrictionMetadataMapRequestDto struct { - Names []string `json:"names,omitempty"` -} diff --git a/harness/nextgen/model_restriction_metadata_map_response_dto.go b/harness/nextgen/model_restriction_metadata_map_response_dto.go deleted file mode 100644 index 4b07d366..00000000 --- a/harness/nextgen/model_restriction_metadata_map_response_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RestrictionMetadataMapResponseDto struct { - MetadataMap map[string]FeatureRestrictionMetadata `json:"metadataMap,omitempty"` -} diff --git a/harness/nextgen/model_role.go b/harness/nextgen/model_role.go deleted file mode 100644 index 930e9199..00000000 --- a/harness/nextgen/model_role.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type Role struct { - Identifier string `json:"identifier,omitempty"` - Name string `json:"name,omitempty"` - Permissions []string `json:"permissions,omitempty"` - AllowedScopeLevels []string `json:"allowedScopeLevels,omitempty"` - Description string `json:"description,omitempty"` - Tags map[string]string `json:"tags,omitempty"` -} diff --git a/harness/nextgen/model_role_assignment.go b/harness/nextgen/model_role_assignment.go deleted file mode 100644 index 64ceed1f..00000000 --- a/harness/nextgen/model_role_assignment.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RoleAssignment struct { - Identifier string `json:"identifier,omitempty"` - ResourceGroupIdentifier string `json:"resourceGroupIdentifier,omitempty"` - RoleIdentifier string `json:"roleIdentifier,omitempty"` - Principal *Principal `json:"principal,omitempty"` - Disabled bool `json:"disabled,omitempty"` - Managed bool `json:"managed,omitempty"` -} diff --git a/harness/nextgen/model_role_assignment_aggregate_response.go b/harness/nextgen/model_role_assignment_aggregate_response.go deleted file mode 100644 index c5b05863..00000000 --- a/harness/nextgen/model_role_assignment_aggregate_response.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RoleAssignmentAggregateResponse struct { - RoleAssignments []RoleAssignment `json:"roleAssignments,omitempty"` - Scope *Scope `json:"scope,omitempty"` - Roles []RoleResponse `json:"roles,omitempty"` - ResourceGroups []ResourceGroup `json:"resourceGroups,omitempty"` -} diff --git a/harness/nextgen/model_role_assignment_create_request.go b/harness/nextgen/model_role_assignment_create_request.go deleted file mode 100644 index 229a8ec0..00000000 --- a/harness/nextgen/model_role_assignment_create_request.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RoleAssignmentCreateRequest struct { - RoleAssignments []RoleAssignment `json:"roleAssignments,omitempty"` -} diff --git a/harness/nextgen/model_role_assignment_filter.go b/harness/nextgen/model_role_assignment_filter.go deleted file mode 100644 index 4cc5d4eb..00000000 --- a/harness/nextgen/model_role_assignment_filter.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RoleAssignmentFilter struct { - ResourceGroupFilter []string `json:"resourceGroupFilter,omitempty"` - RoleFilter []string `json:"roleFilter,omitempty"` - PrincipalTypeFilter []string `json:"principalTypeFilter,omitempty"` - PrincipalFilter []Principal `json:"principalFilter,omitempty"` - HarnessManagedFilter []bool `json:"harnessManagedFilter,omitempty"` - DisabledFilter []bool `json:"disabledFilter,omitempty"` -} diff --git a/harness/nextgen/model_role_assignment_metadata_dto.go b/harness/nextgen/model_role_assignment_metadata_dto.go deleted file mode 100644 index ae0d8cd2..00000000 --- a/harness/nextgen/model_role_assignment_metadata_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RoleAssignmentMetadataDto struct { - Identifier string `json:"identifier,omitempty"` - RoleIdentifier string `json:"roleIdentifier,omitempty"` - RoleName string `json:"roleName,omitempty"` - ResourceGroupIdentifier string `json:"resourceGroupIdentifier,omitempty"` - ResourceGroupName string `json:"resourceGroupName,omitempty"` - ManagedRole bool `json:"managedRole,omitempty"` - ManagedRoleAssignment bool `json:"managedRoleAssignment,omitempty"` -} diff --git a/harness/nextgen/model_role_assignment_response.go b/harness/nextgen/model_role_assignment_response.go deleted file mode 100644 index 47eaf911..00000000 --- a/harness/nextgen/model_role_assignment_response.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RoleAssignmentResponse struct { - RoleAssignment *RoleAssignment `json:"roleAssignment,omitempty"` - Scope *Scope `json:"scope,omitempty"` - CreatedAt int64 `json:"createdAt,omitempty"` - LastModifiedAt int64 `json:"lastModifiedAt,omitempty"` - HarnessManaged bool `json:"harnessManaged,omitempty"` -} diff --git a/harness/nextgen/model_role_response.go b/harness/nextgen/model_role_response.go deleted file mode 100644 index cb2d0bb4..00000000 --- a/harness/nextgen/model_role_response.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type RoleResponse struct { - Role *Role `json:"role,omitempty"` - Scope *Scope `json:"scope,omitempty"` - HarnessManaged bool `json:"harnessManaged,omitempty"` - CreatedAt int64 `json:"createdAt,omitempty"` - LastModifiedAt int64 `json:"lastModifiedAt,omitempty"` -} diff --git a/harness/nextgen/model_saml_link_group_request.go b/harness/nextgen/model_saml_link_group_request.go deleted file mode 100644 index 2748ac81..00000000 --- a/harness/nextgen/model_saml_link_group_request.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SamlLinkGroupRequest struct { - SamlGroupName string `json:"samlGroupName,omitempty"` -} diff --git a/harness/nextgen/model_scope.go b/harness/nextgen/model_scope.go deleted file mode 100644 index 48187985..00000000 --- a/harness/nextgen/model_scope.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type Scope struct { - AccountIdentifier string `json:"accountIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` -} diff --git a/harness/nextgen/model_secret_dtov2.go b/harness/nextgen/model_secret_dtov2.go deleted file mode 100644 index 5957cff5..00000000 --- a/harness/nextgen/model_secret_dtov2.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretDtov2 struct { - Type_ string `json:"type"` - Name string `json:"name"` - Identifier string `json:"identifier"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Description string `json:"description,omitempty"` - Spec *SecretSpecDto `json:"spec"` -} diff --git a/harness/nextgen/model_secret_file_spec_dto.go b/harness/nextgen/model_secret_file_spec_dto.go deleted file mode 100644 index 0fd0f3ab..00000000 --- a/harness/nextgen/model_secret_file_spec_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretFileSpecDto struct { - ErrorMessageForInvalidYaml string `json:"errorMessageForInvalidYaml,omitempty"` - Type_ string `json:"type"` - SecretManagerIdentifier string `json:"secretManagerIdentifier"` -} diff --git a/harness/nextgen/model_secret_manager_config_dto.go b/harness/nextgen/model_secret_manager_config_dto.go deleted file mode 100644 index e6717ce8..00000000 --- a/harness/nextgen/model_secret_manager_config_dto.go +++ /dev/null @@ -1,23 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretManagerConfigDto struct { - Name string `json:"name,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Identifier string `json:"identifier,omitempty"` - Description string `json:"description,omitempty"` - EncryptionType string `json:"encryptionType,omitempty"` - HarnessManaged bool `json:"harnessManaged,omitempty"` - Default_ bool `json:"default,omitempty"` -} diff --git a/harness/nextgen/model_secret_manager_metadata_dto.go b/harness/nextgen/model_secret_manager_metadata_dto.go deleted file mode 100644 index 2f269a2c..00000000 --- a/harness/nextgen/model_secret_manager_metadata_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretManagerMetadataDto struct { - EncryptionType string `json:"encryptionType,omitempty"` - Spec *SecretManagerMetadataSpecDto `json:"spec,omitempty"` -} diff --git a/harness/nextgen/model_secret_manager_metadata_request_dto.go b/harness/nextgen/model_secret_manager_metadata_request_dto.go deleted file mode 100644 index 013edf46..00000000 --- a/harness/nextgen/model_secret_manager_metadata_request_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretManagerMetadataRequestDto struct { - EncryptionType string `json:"encryptionType"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Identifier string `json:"identifier"` - Spec *SecretManagerMetadataRequestSpecDto `json:"spec"` -} diff --git a/harness/nextgen/model_secret_manager_metadata_request_spec_dto.go b/harness/nextgen/model_secret_manager_metadata_request_spec_dto.go deleted file mode 100644 index 0f6fd0c2..00000000 --- a/harness/nextgen/model_secret_manager_metadata_request_spec_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretManagerMetadataRequestSpecDto struct { - EncryptionType string `json:"encryptionType"` -} diff --git a/harness/nextgen/model_secret_manager_metadata_spec_dto.go b/harness/nextgen/model_secret_manager_metadata_spec_dto.go deleted file mode 100644 index 458837d9..00000000 --- a/harness/nextgen/model_secret_manager_metadata_spec_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretManagerMetadataSpecDto struct { - EncryptionType string `json:"encryptionType"` -} diff --git a/harness/nextgen/model_secret_ng_variable.go b/harness/nextgen/model_secret_ng_variable.go deleted file mode 100644 index 4565989f..00000000 --- a/harness/nextgen/model_secret_ng_variable.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretNgVariable struct { - Description string `json:"description,omitempty"` - CurrentValue *ParameterFieldObject `json:"currentValue,omitempty"` - Required bool `json:"required,omitempty"` - Name string `json:"name,omitempty"` - Type_ string `json:"type,omitempty"` - Metadata string `json:"metadata,omitempty"` - Value *ParameterFieldSecretRefData `json:"value"` - Default_ string `json:"default,omitempty"` -} diff --git a/harness/nextgen/model_secret_referred_by_connector_setup_usage_detail.go b/harness/nextgen/model_secret_referred_by_connector_setup_usage_detail.go deleted file mode 100644 index 3b73a75e..00000000 --- a/harness/nextgen/model_secret_referred_by_connector_setup_usage_detail.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretReferredByConnectorSetupUsageDetail struct { - Type_ string `json:"type"` - FieldName string `json:"fieldName,omitempty"` -} diff --git a/harness/nextgen/model_secret_request_wrapper.go b/harness/nextgen/model_secret_request_wrapper.go deleted file mode 100644 index ca951db1..00000000 --- a/harness/nextgen/model_secret_request_wrapper.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretRequestWrapper struct { - Secret *SecretDtov2 `json:"secret"` -} diff --git a/harness/nextgen/model_secret_resource_filter_dto.go b/harness/nextgen/model_secret_resource_filter_dto.go deleted file mode 100644 index 997150b5..00000000 --- a/harness/nextgen/model_secret_resource_filter_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretResourceFilterDto struct { - Identifiers []string `json:"identifiers,omitempty"` - SearchTerm string `json:"searchTerm,omitempty"` - SecretTypes []string `json:"secretTypes,omitempty"` - SourceCategory string `json:"sourceCategory,omitempty"` - IncludeSecretsFromEverySubScope bool `json:"includeSecretsFromEverySubScope,omitempty"` -} diff --git a/harness/nextgen/model_secret_response_wrapper.go b/harness/nextgen/model_secret_response_wrapper.go deleted file mode 100644 index d8b80489..00000000 --- a/harness/nextgen/model_secret_response_wrapper.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretResponseWrapper struct { - Secret *SecretDtov2 `json:"secret"` - CreatedAt int64 `json:"createdAt,omitempty"` - UpdatedAt int64 `json:"updatedAt,omitempty"` - Draft bool `json:"draft,omitempty"` -} diff --git a/harness/nextgen/model_secret_spec_dto.go b/harness/nextgen/model_secret_spec_dto.go deleted file mode 100644 index a36caa39..00000000 --- a/harness/nextgen/model_secret_spec_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretSpecDto struct { - ErrorMessageForInvalidYaml string `json:"errorMessageForInvalidYaml,omitempty"` - Type_ string `json:"type"` -} diff --git a/harness/nextgen/model_secret_text_spec_dto.go b/harness/nextgen/model_secret_text_spec_dto.go deleted file mode 100644 index 6abe33e9..00000000 --- a/harness/nextgen/model_secret_text_spec_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretTextSpecDto struct { - ErrorMessageForInvalidYaml string `json:"errorMessageForInvalidYaml,omitempty"` - Type_ string `json:"type"` - SecretManagerIdentifier string `json:"secretManagerIdentifier"` - ValueType string `json:"valueType"` - Value string `json:"value,omitempty"` -} diff --git a/harness/nextgen/model_secret_unique_identifier.go b/harness/nextgen/model_secret_unique_identifier.go deleted file mode 100644 index 76f84d5d..00000000 --- a/harness/nextgen/model_secret_unique_identifier.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretUniqueIdentifier struct { - KmsId string `json:"kmsId,omitempty"` -} diff --git a/harness/nextgen/model_secret_validation_meta_data.go b/harness/nextgen/model_secret_validation_meta_data.go deleted file mode 100644 index 820855b5..00000000 --- a/harness/nextgen/model_secret_validation_meta_data.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretValidationMetaData struct { - Type_ string `json:"type"` -} diff --git a/harness/nextgen/model_secret_validation_result_dto.go b/harness/nextgen/model_secret_validation_result_dto.go deleted file mode 100644 index 9a2196be..00000000 --- a/harness/nextgen/model_secret_validation_result_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretValidationResultDto struct { - Success bool `json:"success,omitempty"` - Message string `json:"message,omitempty"` -} diff --git a/harness/nextgen/model_secrets_files_body.go b/harness/nextgen/model_secrets_files_body.go deleted file mode 100644 index d0c5bfac..00000000 --- a/harness/nextgen/model_secrets_files_body.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SecretsFilesBody struct { - File *interface{} `json:"file"` - Spec string `json:"spec,omitempty"` -} diff --git a/harness/nextgen/model_service_account_aggregate_dto.go b/harness/nextgen/model_service_account_aggregate_dto.go deleted file mode 100644 index 66770a34..00000000 --- a/harness/nextgen/model_service_account_aggregate_dto.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceAccountAggregateDto struct { - ServiceAccount *ServiceAccountDto `json:"serviceAccount"` - CreatedAt int64 `json:"createdAt"` - LastModifiedAt int64 `json:"lastModifiedAt"` - TokensCount int32 `json:"tokensCount,omitempty"` - RoleAssignmentsMetadataDTO []RoleAssignmentMetadataDto `json:"roleAssignmentsMetadataDTO,omitempty"` -} diff --git a/harness/nextgen/model_service_account_dto.go b/harness/nextgen/model_service_account_dto.go deleted file mode 100644 index e9670010..00000000 --- a/harness/nextgen/model_service_account_dto.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceAccountDto struct { - Identifier string `json:"identifier,omitempty"` - Name string `json:"name,omitempty"` - Email string `json:"email,omitempty"` - Description string `json:"description,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` -} diff --git a/harness/nextgen/model_service_dashboard_info.go b/harness/nextgen/model_service_dashboard_info.go deleted file mode 100644 index bacfdb71..00000000 --- a/harness/nextgen/model_service_dashboard_info.go +++ /dev/null @@ -1,24 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceDashboardInfo struct { - Name string `json:"name,omitempty"` - Identifier string `json:"identifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - TotalDeploymentsCount int64 `json:"totalDeploymentsCount,omitempty"` - SuccessDeploymentsCount int64 `json:"successDeploymentsCount,omitempty"` - FailureDeploymentsCount int64 `json:"failureDeploymentsCount,omitempty"` - TotalDeploymentsChangeRate float64 `json:"totalDeploymentsChangeRate,omitempty"` - InstancesCount int64 `json:"instancesCount,omitempty"` - InstancesCountChangeRate float64 `json:"instancesCountChangeRate,omitempty"` -} diff --git a/harness/nextgen/model_service_deployment.go b/harness/nextgen/model_service_deployment.go deleted file mode 100644 index 802fb664..00000000 --- a/harness/nextgen/model_service_deployment.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceDeployment struct { - Time int64 `json:"time,omitempty"` - Deployments *DeploymentCount `json:"deployments,omitempty"` - Rate *DeploymentChangeRates `json:"rate,omitempty"` -} diff --git a/harness/nextgen/model_service_deployment_info.go b/harness/nextgen/model_service_deployment_info.go deleted file mode 100644 index f0eaf451..00000000 --- a/harness/nextgen/model_service_deployment_info.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceDeploymentInfo struct { - ServiceName string `json:"serviceName,omitempty"` - ServiceTag string `json:"serviceTag,omitempty"` -} diff --git a/harness/nextgen/model_service_deployment_info_dto.go b/harness/nextgen/model_service_deployment_info_dto.go deleted file mode 100644 index 04044ba1..00000000 --- a/harness/nextgen/model_service_deployment_info_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceDeploymentInfoDto struct { - ServiceDeploymentList []ServiceDeployment `json:"serviceDeploymentList,omitempty"` -} diff --git a/harness/nextgen/model_service_deployment_list_info.go b/harness/nextgen/model_service_deployment_list_info.go deleted file mode 100644 index 4efc9329..00000000 --- a/harness/nextgen/model_service_deployment_list_info.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceDeploymentListInfo struct { - StartTime int64 `json:"startTime,omitempty"` - EndTime int64 `json:"endTime,omitempty"` - TotalDeployments int64 `json:"totalDeployments,omitempty"` - FailureRate float64 `json:"failureRate,omitempty"` - Frequency float64 `json:"frequency,omitempty"` - FailureRateChangeRate float64 `json:"failureRateChangeRate,omitempty"` - TotalDeploymentsChangeRate float64 `json:"totalDeploymentsChangeRate,omitempty"` - FrequencyChangeRate float64 `json:"frequencyChangeRate,omitempty"` - ServiceDeploymentList []ServiceDeployment `json:"serviceDeploymentList,omitempty"` -} diff --git a/harness/nextgen/model_service_descriptor.go b/harness/nextgen/model_service_descriptor.go deleted file mode 100644 index e8ac6693..00000000 --- a/harness/nextgen/model_service_descriptor.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceDescriptor struct { - Index int32 `json:"index,omitempty"` - Proto *ServiceDescriptorProto `json:"proto,omitempty"` - FullName string `json:"fullName,omitempty"` - File *FileDescriptor `json:"file,omitempty"` - Methods []MethodDescriptor `json:"methods,omitempty"` - Options *ServiceOptions `json:"options,omitempty"` - Name string `json:"name,omitempty"` -} diff --git a/harness/nextgen/model_service_descriptor_proto.go b/harness/nextgen/model_service_descriptor_proto.go deleted file mode 100644 index 878f98b9..00000000 --- a/harness/nextgen/model_service_descriptor_proto.go +++ /dev/null @@ -1,29 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceDescriptorProto struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Options *ServiceOptions `json:"options,omitempty"` - MethodList []MethodDescriptorProto `json:"methodList,omitempty"` - MethodCount int32 `json:"methodCount,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - ParserForType *ParserServiceDescriptorProto `json:"parserForType,omitempty"` - DefaultInstanceForType *ServiceDescriptorProto `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - OptionsOrBuilder *ServiceOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - MethodOrBuilderList []MethodDescriptorProtoOrBuilder `json:"methodOrBuilderList,omitempty"` - Name string `json:"name,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_service_descriptor_proto_or_builder.go b/harness/nextgen/model_service_descriptor_proto_or_builder.go deleted file mode 100644 index 1cf7f893..00000000 --- a/harness/nextgen/model_service_descriptor_proto_or_builder.go +++ /dev/null @@ -1,26 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceDescriptorProtoOrBuilder struct { - Options *ServiceOptions `json:"options,omitempty"` - MethodList []MethodDescriptorProto `json:"methodList,omitempty"` - MethodCount int32 `json:"methodCount,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - OptionsOrBuilder *ServiceOptionsOrBuilder `json:"optionsOrBuilder,omitempty"` - MethodOrBuilderList []MethodDescriptorProtoOrBuilder `json:"methodOrBuilderList,omitempty"` - Name string `json:"name,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_service_details_dto.go b/harness/nextgen/model_service_details_dto.go deleted file mode 100644 index f4a2ffe6..00000000 --- a/harness/nextgen/model_service_details_dto.go +++ /dev/null @@ -1,26 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceDetailsDto struct { - ServiceName string `json:"serviceName,omitempty"` - ServiceIdentifier string `json:"serviceIdentifier,omitempty"` - DeploymentTypeList []string `json:"deploymentTypeList,omitempty"` - TotalDeployments int64 `json:"totalDeployments,omitempty"` - TotalDeploymentChangeRate float64 `json:"totalDeploymentChangeRate,omitempty"` - SuccessRate float64 `json:"successRate,omitempty"` - SuccessRateChangeRate float64 `json:"successRateChangeRate,omitempty"` - FailureRate float64 `json:"failureRate,omitempty"` - FailureRateChangeRate float64 `json:"failureRateChangeRate,omitempty"` - Frequency float64 `json:"frequency,omitempty"` - FrequencyChangeRate float64 `json:"frequencyChangeRate,omitempty"` - InstanceCountDetails *InstanceCountDetailsByEnvTypeBase `json:"instanceCountDetails,omitempty"` - LastPipelineExecuted *ServicePipelineInfo `json:"lastPipelineExecuted,omitempty"` -} diff --git a/harness/nextgen/model_service_details_info_dto.go b/harness/nextgen/model_service_details_info_dto.go deleted file mode 100644 index 884b8d2b..00000000 --- a/harness/nextgen/model_service_details_info_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceDetailsInfoDto struct { - ServiceDeploymentDetailsList []ServiceDetailsDto `json:"serviceDeploymentDetailsList,omitempty"` -} diff --git a/harness/nextgen/model_service_execution_summary.go b/harness/nextgen/model_service_execution_summary.go deleted file mode 100644 index 1856a699..00000000 --- a/harness/nextgen/model_service_execution_summary.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceExecutionSummary struct { - Identifier string `json:"identifier,omitempty"` - DisplayName string `json:"displayName,omitempty"` - DeploymentType string `json:"deploymentType,omitempty"` - Artifacts *ArtifactsSummary `json:"artifacts,omitempty"` -} diff --git a/harness/nextgen/model_service_header_info.go b/harness/nextgen/model_service_header_info.go deleted file mode 100644 index 1bd9824d..00000000 --- a/harness/nextgen/model_service_header_info.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceHeaderInfo struct { - Name string `json:"name,omitempty"` - Identifier string `json:"identifier,omitempty"` - Description string `json:"description,omitempty"` - DeploymentTypes []string `json:"deploymentTypes,omitempty"` - CreatedAt int64 `json:"createdAt,omitempty"` - LastModifiedAt int64 `json:"lastModifiedAt,omitempty"` -} diff --git a/harness/nextgen/model_service_options.go b/harness/nextgen/model_service_options.go deleted file mode 100644 index 7cd78a47..00000000 --- a/harness/nextgen/model_service_options.go +++ /dev/null @@ -1,27 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceOptions struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - ParserForType *ParserServiceOptions `json:"parserForType,omitempty"` - DefaultInstanceForType *ServiceOptions `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - AllFieldsRaw map[string]interface{} `json:"allFieldsRaw,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_service_options_or_builder.go b/harness/nextgen/model_service_options_or_builder.go deleted file mode 100644 index b4a8a718..00000000 --- a/harness/nextgen/model_service_options_or_builder.go +++ /dev/null @@ -1,23 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceOptionsOrBuilder struct { - Deprecated bool `json:"deprecated,omitempty"` - UninterpretedOptionCount int32 `json:"uninterpretedOptionCount,omitempty"` - UninterpretedOptionOrBuilderList []UninterpretedOptionOrBuilder `json:"uninterpretedOptionOrBuilderList,omitempty"` - UninterpretedOptionList []UninterpretedOption `json:"uninterpretedOptionList,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_service_pipeline_info.go b/harness/nextgen/model_service_pipeline_info.go deleted file mode 100644 index e710ad4e..00000000 --- a/harness/nextgen/model_service_pipeline_info.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServicePipelineInfo struct { - PipelineExecutionId string `json:"pipelineExecutionId,omitempty"` - Identifier string `json:"identifier,omitempty"` - Name string `json:"name,omitempty"` - Status string `json:"status,omitempty"` - LastExecutedAt int64 `json:"lastExecutedAt,omitempty"` -} diff --git a/harness/nextgen/model_service_request_dto.go b/harness/nextgen/model_service_request.go similarity index 90% rename from harness/nextgen/model_service_request_dto.go rename to harness/nextgen/model_service_request.go index 63bfcc71..83e77395 100644 --- a/harness/nextgen/model_service_request_dto.go +++ b/harness/nextgen/model_service_request.go @@ -9,7 +9,8 @@ */ package nextgen -type ServiceRequestDto struct { +// This is the ServiceRequest entity defined in Harness +type ServiceRequest struct { Identifier string `json:"identifier,omitempty"` OrgIdentifier string `json:"orgIdentifier,omitempty"` ProjectIdentifier string `json:"projectIdentifier,omitempty"` diff --git a/harness/nextgen/model_service_response.go b/harness/nextgen/model_service_response.go index 5de2b3e0..57d3fbe7 100644 --- a/harness/nextgen/model_service_response.go +++ b/harness/nextgen/model_service_response.go @@ -10,7 +10,7 @@ package nextgen type ServiceResponse struct { - Service *ServiceResponseDto `json:"service,omitempty"` - CreatedAt int64 `json:"createdAt,omitempty"` - LastModifiedAt int64 `json:"lastModifiedAt,omitempty"` + Service *ServiceResponse `json:"service,omitempty"` + CreatedAt int64 `json:"createdAt,omitempty"` + LastModifiedAt int64 `json:"lastModifiedAt,omitempty"` } diff --git a/harness/nextgen/model_service_response_dto.go b/harness/nextgen/model_service_response_dto.go deleted file mode 100644 index 22fb5ef9..00000000 --- a/harness/nextgen/model_service_response_dto.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServiceResponseDto struct { - AccountId string `json:"accountId,omitempty"` - Identifier string `json:"identifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Name string `json:"name,omitempty"` - Description string `json:"description,omitempty"` - Deleted bool `json:"deleted,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Version int64 `json:"version,omitempty"` -} diff --git a/harness/nextgen/model_services_count.go b/harness/nextgen/model_services_count.go deleted file mode 100644 index 8b314916..00000000 --- a/harness/nextgen/model_services_count.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServicesCount struct { - TotalCount int64 `json:"totalCount,omitempty"` - NewCount int64 `json:"newCount,omitempty"` -} diff --git a/harness/nextgen/model_services_dashboard_info.go b/harness/nextgen/model_services_dashboard_info.go deleted file mode 100644 index 5a4b53d0..00000000 --- a/harness/nextgen/model_services_dashboard_info.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type ServicesDashboardInfo struct { - ServiceDashboardInfoList []ServiceDashboardInfo `json:"serviceDashboardInfoList,omitempty"` -} diff --git a/harness/nextgen/model_setup_usage_detail.go b/harness/nextgen/model_setup_usage_detail.go deleted file mode 100644 index 8f7d9e38..00000000 --- a/harness/nextgen/model_setup_usage_detail.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SetupUsageDetail struct { - Type_ string `json:"type"` -} diff --git a/harness/nextgen/model_signup_dto.go b/harness/nextgen/model_signup_dto.go deleted file mode 100644 index 05d58eb8..00000000 --- a/harness/nextgen/model_signup_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SignupDto struct { - Email string `json:"email,omitempty"` - Password string `json:"password,omitempty"` - UtmInfo *UtmInfo `json:"utmInfo,omitempty"` - Intent string `json:"intent,omitempty"` - SignupAction string `json:"signupAction,omitempty"` - Edition string `json:"edition,omitempty"` - BillingFrequency string `json:"billingFrequency,omitempty"` -} diff --git a/harness/nextgen/model_slack_config_dto.go b/harness/nextgen/model_slack_config_dto.go deleted file mode 100644 index c8da5406..00000000 --- a/harness/nextgen/model_slack_config_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SlackConfigDto struct { - Type_ string `json:"type,omitempty"` - SlackWebhookUrl string `json:"slackWebhookUrl"` -} diff --git a/harness/nextgen/model_sort.go b/harness/nextgen/model_sort.go deleted file mode 100644 index 4ee03462..00000000 --- a/harness/nextgen/model_sort.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type Sort struct { - Sorted bool `json:"sorted,omitempty"` - Unsorted bool `json:"unsorted,omitempty"` - Empty bool `json:"empty,omitempty"` -} diff --git a/harness/nextgen/model_source_code_info.go b/harness/nextgen/model_source_code_info.go deleted file mode 100644 index bbd2d17b..00000000 --- a/harness/nextgen/model_source_code_info.go +++ /dev/null @@ -1,25 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SourceCodeInfo struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - LocationCount int32 `json:"locationCount,omitempty"` - LocationOrBuilderList []LocationOrBuilder `json:"locationOrBuilderList,omitempty"` - ParserForType *ParserSourceCodeInfo `json:"parserForType,omitempty"` - DefaultInstanceForType *SourceCodeInfo `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - LocationList []Location `json:"locationList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_source_code_info_or_builder.go b/harness/nextgen/model_source_code_info_or_builder.go deleted file mode 100644 index 6d9bf367..00000000 --- a/harness/nextgen/model_source_code_info_or_builder.go +++ /dev/null @@ -1,22 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SourceCodeInfoOrBuilder struct { - LocationCount int32 `json:"locationCount,omitempty"` - LocationOrBuilderList []LocationOrBuilder `json:"locationOrBuilderList,omitempty"` - LocationList []Location `json:"locationList,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_source_code_manager_dto.go b/harness/nextgen/model_source_code_manager.go similarity index 92% rename from harness/nextgen/model_source_code_manager_dto.go rename to harness/nextgen/model_source_code_manager.go index 307056ab..89a042d3 100644 --- a/harness/nextgen/model_source_code_manager_dto.go +++ b/harness/nextgen/model_source_code_manager.go @@ -9,7 +9,8 @@ */ package nextgen -type SourceCodeManagerDto struct { +// This contains details of Source Code Manager +type SourceCodeManager struct { Id string `json:"id,omitempty"` UserIdentifier string `json:"userIdentifier,omitempty"` AccountIdentifier string `json:"accountIdentifier,omitempty"` diff --git a/harness/nextgen/model_ssh_auth_dto.go b/harness/nextgen/model_ssh_auth_dto.go deleted file mode 100644 index b47def10..00000000 --- a/harness/nextgen/model_ssh_auth_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SshAuthDto struct { - Spec *BaseSshSpecDto `json:"spec"` - Type_ string `json:"type"` -} diff --git a/harness/nextgen/model_ssh_config_dto.go b/harness/nextgen/model_ssh_config_dto.go deleted file mode 100644 index 3104d27b..00000000 --- a/harness/nextgen/model_ssh_config_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SshConfigDto struct { - Type_ string `json:"type"` - CredentialType string `json:"credentialType"` - Spec *SshCredentialSpecDto `json:"spec"` -} diff --git a/harness/nextgen/model_ssh_credential_spec_dto.go b/harness/nextgen/model_ssh_credential_spec_dto.go deleted file mode 100644 index 79f0c632..00000000 --- a/harness/nextgen/model_ssh_credential_spec_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SshCredentialSpecDto struct { - CredentialType string `json:"credentialType"` -} diff --git a/harness/nextgen/model_ssh_key_path_credential_dto.go b/harness/nextgen/model_ssh_key_path_credential_dto.go deleted file mode 100644 index 8292f582..00000000 --- a/harness/nextgen/model_ssh_key_path_credential_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SshKeyPathCredentialDto struct { - CredentialType string `json:"credentialType"` - UserName string `json:"userName"` - KeyPath string `json:"keyPath"` - EncryptedPassphrase string `json:"encryptedPassphrase,omitempty"` -} diff --git a/harness/nextgen/model_ssh_key_reference_credential_dto.go b/harness/nextgen/model_ssh_key_reference_credential_dto.go deleted file mode 100644 index 0824ea94..00000000 --- a/harness/nextgen/model_ssh_key_reference_credential_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SshKeyReferenceCredentialDto struct { - CredentialType string `json:"credentialType"` - UserName string `json:"userName"` - Key string `json:"key,omitempty"` - EncryptedPassphrase string `json:"encryptedPassphrase,omitempty"` -} diff --git a/harness/nextgen/model_ssh_key_spec_dto.go b/harness/nextgen/model_ssh_key_spec_dto.go deleted file mode 100644 index 88e2e179..00000000 --- a/harness/nextgen/model_ssh_key_spec_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SshKeySpecDto struct { - ErrorMessageForInvalidYaml string `json:"errorMessageForInvalidYaml,omitempty"` - Type_ string `json:"type"` - Port int32 `json:"port,omitempty"` - Auth *SshAuthDto `json:"auth"` -} diff --git a/harness/nextgen/model_ssh_password_credential_dto.go b/harness/nextgen/model_ssh_password_credential_dto.go deleted file mode 100644 index eb886249..00000000 --- a/harness/nextgen/model_ssh_password_credential_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type SshPasswordCredentialDto struct { - CredentialType string `json:"credentialType"` - UserName string `json:"userName"` - Password string `json:"password"` -} diff --git a/harness/nextgen/model_stage_element_wrapper_config.go b/harness/nextgen/model_stage_element_wrapper_config.go deleted file mode 100644 index ab0b76b2..00000000 --- a/harness/nextgen/model_stage_element_wrapper_config.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type StageElementWrapperConfig struct { - Stage *JsonNode `json:"stage,omitempty"` - Parallel *JsonNode `json:"parallel,omitempty"` -} diff --git a/harness/nextgen/model_start_trial.go b/harness/nextgen/model_start_trial.go index 148d5866..0ba48fd9 100644 --- a/harness/nextgen/model_start_trial.go +++ b/harness/nextgen/model_start_trial.go @@ -9,7 +9,7 @@ */ package nextgen -// This is the view of a Start Trial object defined in Harness +// This contains details of the Start Trial object defined in Harness type StartTrial struct { ModuleType string `json:"moduleType"` Edition string `json:"edition"` diff --git a/harness/nextgen/model_static_limit_restriction.go b/harness/nextgen/model_static_limit_restriction.go new file mode 100644 index 00000000..66ae5495 --- /dev/null +++ b/harness/nextgen/model_static_limit_restriction.go @@ -0,0 +1,17 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// This contains details of the Static Limit Restriction in Harness +type StaticLimitRestriction struct { + RestrictionType string `json:"restrictionType"` + Limit int64 `json:"limit,omitempty"` + Count int64 `json:"count,omitempty"` +} diff --git a/harness/nextgen/model_static_limit_restriction_dto.go b/harness/nextgen/model_static_limit_restriction_dto.go deleted file mode 100644 index 0c7fbc77..00000000 --- a/harness/nextgen/model_static_limit_restriction_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type StaticLimitRestrictionDto struct { - Limit int64 `json:"limit,omitempty"` - Count int64 `json:"count,omitempty"` -} diff --git a/harness/nextgen/model_static_limit_restriction_metadata_dto.go b/harness/nextgen/model_static_limit_restriction_metadata.go similarity index 82% rename from harness/nextgen/model_static_limit_restriction_metadata_dto.go rename to harness/nextgen/model_static_limit_restriction_metadata.go index 1afdc1fe..19f85052 100644 --- a/harness/nextgen/model_static_limit_restriction_metadata_dto.go +++ b/harness/nextgen/model_static_limit_restriction_metadata.go @@ -9,7 +9,8 @@ */ package nextgen -type StaticLimitRestrictionMetadataDto struct { +// This contains metadata of the Static Limit Restriction in Harness +type StaticLimitRestrictionMetadata struct { RestrictionType string `json:"restrictionType,omitempty"` Limit int64 `json:"limit,omitempty"` AllowedIfEqual bool `json:"allowedIfEqual,omitempty"` diff --git a/harness/nextgen/model_step_category.go b/harness/nextgen/model_step_category.go deleted file mode 100644 index 29a9956a..00000000 --- a/harness/nextgen/model_step_category.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type StepCategory struct { - Name string `json:"name,omitempty"` - StepsData []StepData `json:"stepsData,omitempty"` - StepCategories []StepCategory `json:"stepCategories,omitempty"` -} diff --git a/harness/nextgen/model_step_data.go b/harness/nextgen/model_step_data.go deleted file mode 100644 index f440a6fe..00000000 --- a/harness/nextgen/model_step_data.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type StepData struct { - Type_ string `json:"type,omitempty"` - Name string `json:"name,omitempty"` -} diff --git a/harness/nextgen/model_string_ng_variable.go b/harness/nextgen/model_string_ng_variable.go deleted file mode 100644 index 0ea7b1f7..00000000 --- a/harness/nextgen/model_string_ng_variable.go +++ /dev/null @@ -1,21 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type StringNgVariable struct { - Description string `json:"description,omitempty"` - CurrentValue *ParameterFieldObject `json:"currentValue,omitempty"` - Required bool `json:"required,omitempty"` - Name string `json:"name,omitempty"` - Type_ string `json:"type,omitempty"` - Metadata string `json:"metadata,omitempty"` - Value *ParameterFieldString `json:"value"` - Default_ string `json:"default,omitempty"` -} diff --git a/harness/nextgen/model_tgt_generation_spec_dto.go b/harness/nextgen/model_tgt_generation_spec_dto.go deleted file mode 100644 index 147da3ee..00000000 --- a/harness/nextgen/model_tgt_generation_spec_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TgtGenerationSpecDto struct { - TgtGenerationMethod string `json:"tgtGenerationMethod"` -} diff --git a/harness/nextgen/model_tgt_key_tab_file_path_spec_dto.go b/harness/nextgen/model_tgt_key_tab_file_path_spec_dto.go deleted file mode 100644 index 8c85e914..00000000 --- a/harness/nextgen/model_tgt_key_tab_file_path_spec_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TgtKeyTabFilePathSpecDto struct { - TgtGenerationMethod string `json:"tgtGenerationMethod"` - KeyPath string `json:"keyPath,omitempty"` -} diff --git a/harness/nextgen/model_tgt_password_spec_dto.go b/harness/nextgen/model_tgt_password_spec_dto.go deleted file mode 100644 index a45406ce..00000000 --- a/harness/nextgen/model_tgt_password_spec_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TgtPasswordSpecDto struct { - TgtGenerationMethod string `json:"tgtGenerationMethod"` - Password string `json:"password,omitempty"` -} diff --git a/harness/nextgen/model_time_based_deployment_info.go b/harness/nextgen/model_time_based_deployment_info.go deleted file mode 100644 index 21d334ce..00000000 --- a/harness/nextgen/model_time_based_deployment_info.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TimeBasedDeploymentInfo struct { - EpochTime int64 `json:"epochTime,omitempty"` - TotalCount int64 `json:"totalCount,omitempty"` - SuccessCount int64 `json:"successCount,omitempty"` - FailedCount int64 `json:"failedCount,omitempty"` - FailureRate float64 `json:"failureRate,omitempty"` -} diff --git a/harness/nextgen/model_time_value_pair_env_id_count_pair.go b/harness/nextgen/model_time_value_pair_env_id_count_pair.go deleted file mode 100644 index 6ffc5e83..00000000 --- a/harness/nextgen/model_time_value_pair_env_id_count_pair.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TimeValuePairEnvIdCountPair struct { - Timestamp int64 `json:"timestamp,omitempty"` - Value *EnvIdCountPair `json:"value,omitempty"` -} diff --git a/harness/nextgen/model_time_value_pair_integer.go b/harness/nextgen/model_time_value_pair_integer.go deleted file mode 100644 index 596fc579..00000000 --- a/harness/nextgen/model_time_value_pair_integer.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TimeValuePairInteger struct { - Timestamp int64 `json:"timestamp,omitempty"` - Value int32 `json:"value,omitempty"` -} diff --git a/harness/nextgen/model_time_value_pair_list_dto_env_id_count_pair.go b/harness/nextgen/model_time_value_pair_list_dto_env_id_count_pair.go deleted file mode 100644 index 22cd9849..00000000 --- a/harness/nextgen/model_time_value_pair_list_dto_env_id_count_pair.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TimeValuePairListDtoEnvIdCountPair struct { - TimeValuePairList []TimeValuePairEnvIdCountPair `json:"timeValuePairList,omitempty"` -} diff --git a/harness/nextgen/model_time_value_pair_list_dto_integer.go b/harness/nextgen/model_time_value_pair_list_dto_integer.go deleted file mode 100644 index 7025a1d6..00000000 --- a/harness/nextgen/model_time_value_pair_list_dto_integer.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TimeValuePairListDtoInteger struct { - TimeValuePairList []TimeValuePairInteger `json:"timeValuePairList,omitempty"` -} diff --git a/harness/nextgen/model_token_aggregate_dto.go b/harness/nextgen/model_token_aggregate_dto.go deleted file mode 100644 index 793d4083..00000000 --- a/harness/nextgen/model_token_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TokenAggregateDto struct { - Token *TokenDto `json:"token"` - ExpiryAt int64 `json:"expiryAt"` - CreatedAt int64 `json:"createdAt"` - LastModifiedAt int64 `json:"lastModifiedAt"` -} diff --git a/harness/nextgen/model_token_dto.go b/harness/nextgen/model_token_dto.go deleted file mode 100644 index 6e9dccd1..00000000 --- a/harness/nextgen/model_token_dto.go +++ /dev/null @@ -1,30 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TokenDto struct { - Identifier string `json:"identifier,omitempty"` - Name string `json:"name,omitempty"` - ValidFrom int64 `json:"validFrom,omitempty"` - ValidTo int64 `json:"validTo,omitempty"` - ScheduledExpireTime int64 `json:"scheduledExpireTime,omitempty"` - Valid bool `json:"valid,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ApiKeyIdentifier string `json:"apiKeyIdentifier,omitempty"` - ParentIdentifier string `json:"parentIdentifier,omitempty"` - ApiKeyType string `json:"apiKeyType,omitempty"` - Description string `json:"description,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Email string `json:"email,omitempty"` - Username string `json:"username,omitempty"` - EncodedPassword string `json:"encodedPassword,omitempty"` -} diff --git a/harness/nextgen/model_total_deployment_info.go b/harness/nextgen/model_total_deployment_info.go deleted file mode 100644 index 38ce2986..00000000 --- a/harness/nextgen/model_total_deployment_info.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TotalDeploymentInfo struct { - Count int64 `json:"count,omitempty"` - Production int64 `json:"production,omitempty"` - NonProduction int64 `json:"nonProduction,omitempty"` - CountList []DeploymentDateAndCount `json:"countList,omitempty"` -} diff --git a/harness/nextgen/model_trigger_full_sync_response.go b/harness/nextgen/model_trigger_full_sync_response.go new file mode 100644 index 00000000..3cca748b --- /dev/null +++ b/harness/nextgen/model_trigger_full_sync_response.go @@ -0,0 +1,15 @@ +/* + * CD NextGen API Reference + * + * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub + * + * API version: 3.0 + * Contact: contact@harness.io + * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) + */ +package nextgen + +// The trigger full sync response +type TriggerFullSyncResponse struct { + IsFullSyncTriggered bool `json:"isFullSyncTriggered,omitempty"` +} diff --git a/harness/nextgen/model_two_factor_auth_settings_info.go b/harness/nextgen/model_two_factor_auth_settings_info.go deleted file mode 100644 index 42a8c8d3..00000000 --- a/harness/nextgen/model_two_factor_auth_settings_info.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type TwoFactorAuthSettingsInfo struct { - UserId string `json:"userId,omitempty"` - Email string `json:"email,omitempty"` - TwoFactorAuthenticationEnabled bool `json:"twoFactorAuthenticationEnabled,omitempty"` - Mechanism string `json:"mechanism,omitempty"` - TotpSecretKey string `json:"totpSecretKey,omitempty"` - Totpqrurl string `json:"totpqrurl,omitempty"` -} diff --git a/harness/nextgen/model_uninterpreted_option.go b/harness/nextgen/model_uninterpreted_option.go deleted file mode 100644 index ef1dceb6..00000000 --- a/harness/nextgen/model_uninterpreted_option.go +++ /dev/null @@ -1,33 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type UninterpretedOption struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - StringValue *ByteString `json:"stringValue,omitempty"` - NameList []NamePart `json:"nameList,omitempty"` - DoubleValue float64 `json:"doubleValue,omitempty"` - ParserForType *ParserUninterpretedOption `json:"parserForType,omitempty"` - DefaultInstanceForType *UninterpretedOption `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - NameOrBuilderList []NamePartOrBuilder `json:"nameOrBuilderList,omitempty"` - IdentifierValue string `json:"identifierValue,omitempty"` - IdentifierValueBytes *ByteString `json:"identifierValueBytes,omitempty"` - PositiveIntValue int64 `json:"positiveIntValue,omitempty"` - NegativeIntValue int64 `json:"negativeIntValue,omitempty"` - AggregateValue string `json:"aggregateValue,omitempty"` - AggregateValueBytes *ByteString `json:"aggregateValueBytes,omitempty"` - NameCount int32 `json:"nameCount,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_uninterpreted_option_or_builder.go b/harness/nextgen/model_uninterpreted_option_or_builder.go deleted file mode 100644 index ba747920..00000000 --- a/harness/nextgen/model_uninterpreted_option_or_builder.go +++ /dev/null @@ -1,30 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type UninterpretedOptionOrBuilder struct { - StringValue *ByteString `json:"stringValue,omitempty"` - NameList []NamePart `json:"nameList,omitempty"` - DoubleValue float64 `json:"doubleValue,omitempty"` - NameOrBuilderList []NamePartOrBuilder `json:"nameOrBuilderList,omitempty"` - IdentifierValue string `json:"identifierValue,omitempty"` - IdentifierValueBytes *ByteString `json:"identifierValueBytes,omitempty"` - PositiveIntValue int64 `json:"positiveIntValue,omitempty"` - NegativeIntValue int64 `json:"negativeIntValue,omitempty"` - AggregateValue string `json:"aggregateValue,omitempty"` - AggregateValueBytes *ByteString `json:"aggregateValueBytes,omitempty"` - NameCount int32 `json:"nameCount,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - DefaultInstanceForType *Message `json:"defaultInstanceForType,omitempty"` - Initialized bool `json:"initialized,omitempty"` -} diff --git a/harness/nextgen/model_unknown_field_set.go b/harness/nextgen/model_unknown_field_set.go deleted file mode 100644 index b913a4df..00000000 --- a/harness/nextgen/model_unknown_field_set.go +++ /dev/null @@ -1,18 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type UnknownFieldSet struct { - Initialized bool `json:"initialized,omitempty"` - SerializedSizeAsMessageSet int32 `json:"serializedSizeAsMessageSet,omitempty"` - ParserForType *Parser `json:"parserForType,omitempty"` - DefaultInstanceForType *UnknownFieldSet `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` -} diff --git a/harness/nextgen/model_upsert_webhook_request_dto.go b/harness/nextgen/model_upsert_webhook_request_dto.go deleted file mode 100644 index f7bff012..00000000 --- a/harness/nextgen/model_upsert_webhook_request_dto.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type UpsertWebhookRequestDto struct { - AccountIdentifier string `json:"accountIdentifier"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - ConnectorIdentifierRef string `json:"connectorIdentifierRef"` - HookEventType string `json:"hookEventType"` - RepoURL string `json:"repoURL,omitempty"` -} diff --git a/harness/nextgen/model_upsert_webhook_response_dto.go b/harness/nextgen/model_upsert_webhook_response_dto.go deleted file mode 100644 index 0278a753..00000000 --- a/harness/nextgen/model_upsert_webhook_response_dto.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type UpsertWebhookResponseDto struct { - WebhookResponse *WebhookResponse `json:"webhookResponse,omitempty"` - Status int32 `json:"status,omitempty"` - Error_ string `json:"error,omitempty"` -} diff --git a/harness/nextgen/model_user.go b/harness/nextgen/model_user.go index db658cf6..169c7d35 100644 --- a/harness/nextgen/model_user.go +++ b/harness/nextgen/model_user.go @@ -10,42 +10,43 @@ package nextgen type User struct { - Uuid string `json:"uuid"` - AppId string `json:"appId"` - CreatedBy *EmbeddedUser `json:"createdBy,omitempty"` - CreatedAt int64 `json:"createdAt,omitempty"` - LastUpdatedBy *EmbeddedUser `json:"lastUpdatedBy,omitempty"` - LastUpdatedAt int64 `json:"lastUpdatedAt"` - Name string `json:"name,omitempty"` - ExternalUserId string `json:"externalUserId,omitempty"` - GivenName string `json:"givenName,omitempty"` - FamilyName string `json:"familyName,omitempty"` - Email string `json:"email,omitempty"` - CompanyName string `json:"companyName,omitempty"` - AccountName string `json:"accountName,omitempty"` - UserGroups []UserGroup `json:"userGroups,omitempty"` - Accounts []Account `json:"accounts,omitempty"` - PendingAccounts []Account `json:"pendingAccounts,omitempty"` - SupportAccounts []Account `json:"supportAccounts,omitempty"` - LastLogin int64 `json:"lastLogin,omitempty"` - FirstLogin bool `json:"firstLogin,omitempty"` - Password []string `json:"password,omitempty"` - Token string `json:"token,omitempty"` - TwoFactorJwtToken string `json:"twoFactorJwtToken,omitempty"` - EmailVerified bool `json:"emailVerified,omitempty"` - PasswordExpired bool `json:"passwordExpired,omitempty"` - UserLocked bool `json:"userLocked,omitempty"` - StatsFetchedOn int64 `json:"statsFetchedOn,omitempty"` - LastAccountId string `json:"lastAccountId,omitempty"` - DefaultAccountId string `json:"defaultAccountId,omitempty"` - LastAppId string `json:"lastAppId,omitempty"` - Disabled bool `json:"disabled,omitempty"` - Imported bool `json:"imported,omitempty"` - UserLockoutInfo *UserLockoutInfo `json:"userLockoutInfo,omitempty"` - TwoFactorAuthenticationEnabled bool `json:"twoFactorAuthenticationEnabled,omitempty"` - TwoFactorAuthenticationMechanism string `json:"twoFactorAuthenticationMechanism,omitempty"` - OauthProvider string `json:"oauthProvider,omitempty"` - ReportedSegmentTracks []string `json:"reportedSegmentTracks,omitempty"` - UtmInfo *UtmInfo `json:"utmInfo,omitempty"` - AccountIds []string `json:"accountIds,omitempty"` + Uuid string `json:"uuid"` + AppId string `json:"appId"` + CreatedBy *EmbeddedUser `json:"createdBy,omitempty"` + CreatedAt int64 `json:"createdAt,omitempty"` + LastUpdatedBy *EmbeddedUser `json:"lastUpdatedBy,omitempty"` + LastUpdatedAt int64 `json:"lastUpdatedAt"` + Name string `json:"name,omitempty"` + ExternalUserId string `json:"externalUserId,omitempty"` + GivenName string `json:"givenName,omitempty"` + FamilyName string `json:"familyName,omitempty"` + Email string `json:"email,omitempty"` + CompanyName string `json:"companyName,omitempty"` + AccountName string `json:"accountName,omitempty"` + UserGroups []UserGroup `json:"userGroups,omitempty"` + Accounts []Account `json:"accounts,omitempty"` + PendingAccounts []Account `json:"pendingAccounts,omitempty"` + SupportAccounts []Account `json:"supportAccounts,omitempty"` + LastLogin int64 `json:"lastLogin,omitempty"` + FirstLogin bool `json:"firstLogin,omitempty"` + Password []string `json:"password,omitempty"` + Token string `json:"token,omitempty"` + TwoFactorJwtToken string `json:"twoFactorJwtToken,omitempty"` + EmailVerified bool `json:"emailVerified,omitempty"` + PasswordExpired bool `json:"passwordExpired,omitempty"` + UserLocked bool `json:"userLocked,omitempty"` + StatsFetchedOn int64 `json:"statsFetchedOn,omitempty"` + LastAccountId string `json:"lastAccountId,omitempty"` + DefaultAccountId string `json:"defaultAccountId,omitempty"` + LastAppId string `json:"lastAppId,omitempty"` + Disabled bool `json:"disabled,omitempty"` + Imported bool `json:"imported,omitempty"` + UserLockoutInfo *UserLockoutInfo `json:"userLockoutInfo,omitempty"` + RateLimitProtection *RateLimitProtection `json:"rateLimitProtection,omitempty"` + TwoFactorAuthenticationEnabled bool `json:"twoFactorAuthenticationEnabled,omitempty"` + TwoFactorAuthenticationMechanism string `json:"twoFactorAuthenticationMechanism,omitempty"` + OauthProvider string `json:"oauthProvider,omitempty"` + ReportedSegmentTracks []string `json:"reportedSegmentTracks,omitempty"` + UtmInfo *UtmInfo `json:"utmInfo,omitempty"` + AccountIds []string `json:"accountIds,omitempty"` } diff --git a/harness/nextgen/model_user_aggregate_dto.go b/harness/nextgen/model_user_aggregate_dto.go deleted file mode 100644 index 5a045959..00000000 --- a/harness/nextgen/model_user_aggregate_dto.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type UserAggregateDto struct { - User *UserMetadataDto `json:"user,omitempty"` - RoleAssignmentMetadata []RoleAssignmentMetadataDto `json:"roleAssignmentMetadata,omitempty"` -} diff --git a/harness/nextgen/model_user_filter.go b/harness/nextgen/model_user_filter.go deleted file mode 100644 index 7a453208..00000000 --- a/harness/nextgen/model_user_filter.go +++ /dev/null @@ -1,16 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type UserFilter struct { - SearchTerm string `json:"searchTerm,omitempty"` - Identifiers []string `json:"identifiers,omitempty"` - ParentFilter string `json:"parentFilter,omitempty"` -} diff --git a/harness/nextgen/model_user_group.go b/harness/nextgen/model_user_group.go index 31488c3d..0a2b72aa 100644 --- a/harness/nextgen/model_user_group.go +++ b/harness/nextgen/model_user_group.go @@ -10,25 +10,26 @@ package nextgen type UserGroup struct { - Id string `json:"id,omitempty"` - AccountIdentifier string `json:"accountIdentifier"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Identifier string `json:"identifier,omitempty"` - IsSsoLinked bool `json:"isSsoLinked,omitempty"` - LinkedSsoType string `json:"linkedSsoType,omitempty"` - LinkedSsoId string `json:"linkedSsoId,omitempty"` - LinkedSsoDisplayName string `json:"linkedSsoDisplayName,omitempty"` - SsoGroupId string `json:"ssoGroupId,omitempty"` - SsoGroupName string `json:"ssoGroupName,omitempty"` - Name string `json:"name,omitempty"` - Users []string `json:"users"` - NotificationConfigs []NotificationSettingConfig `json:"notificationConfigs"` - HarnessManaged bool `json:"harnessManaged,omitempty"` - Description string `json:"description"` - Tags []NgTag `json:"tags"` - CreatedAt int64 `json:"createdAt,omitempty"` - LastModifiedAt int64 `json:"lastModifiedAt,omitempty"` - Version int64 `json:"version,omitempty"` - Deleted bool `json:"deleted,omitempty"` + Uuid string `json:"uuid"` + AppId string `json:"appId"` + CreatedBy *EmbeddedUser `json:"createdBy,omitempty"` + CreatedAt int64 `json:"createdAt,omitempty"` + LastUpdatedBy *EmbeddedUser `json:"lastUpdatedBy,omitempty"` + LastUpdatedAt int64 `json:"lastUpdatedAt"` + Name string `json:"name,omitempty"` + Description string `json:"description,omitempty"` + LinkedSsoType string `json:"linkedSsoType,omitempty"` + LinkedSsoId string `json:"linkedSsoId,omitempty"` + LinkedSsoDisplayName string `json:"linkedSsoDisplayName,omitempty"` + SsoGroupId string `json:"ssoGroupId,omitempty"` + SsoGroupName string `json:"ssoGroupName,omitempty"` + ImportedByScim bool `json:"importedByScim,omitempty"` + AccountId string `json:"accountId,omitempty"` + MemberIds []string `json:"memberIds,omitempty"` + Members []User `json:"members,omitempty"` + AppPermissions []AppPermission `json:"appPermissions,omitempty"` + AccountPermissions *AccountPermissions `json:"accountPermissions,omitempty"` + NotificationSettings *NotificationSettings `json:"notificationSettings,omitempty"` + Default_ bool `json:"default,omitempty"` + SsoLinked bool `json:"ssoLinked,omitempty"` } diff --git a/harness/nextgen/model_user_group_aggregate_dto.go b/harness/nextgen/model_user_group_aggregate_dto.go deleted file mode 100644 index 1e8eaad1..00000000 --- a/harness/nextgen/model_user_group_aggregate_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type UserGroupAggregateDto struct { - UserGroupDTO *UserGroupDto `json:"userGroupDTO"` - Users []UserMetadataDto `json:"users,omitempty"` - RoleAssignmentsMetadataDTO []RoleAssignmentMetadataDto `json:"roleAssignmentsMetadataDTO,omitempty"` - LastModifiedAt int64 `json:"lastModifiedAt,omitempty"` -} diff --git a/harness/nextgen/model_user_group_dto.go b/harness/nextgen/model_user_group_dto.go deleted file mode 100644 index 70b3c04c..00000000 --- a/harness/nextgen/model_user_group_dto.go +++ /dev/null @@ -1,28 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type UserGroupDto struct { - AccountIdentifier string `json:"accountIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Identifier string `json:"identifier"` - Name string `json:"name"` - Users []string `json:"users,omitempty"` - NotificationConfigs []NotificationSettingConfigDto `json:"notificationConfigs,omitempty"` - IsSsoLinked bool `json:"isSsoLinked,omitempty"` - LinkedSsoId string `json:"linkedSsoId,omitempty"` - LinkedSsoDisplayName string `json:"linkedSsoDisplayName,omitempty"` - SsoGroupId string `json:"ssoGroupId,omitempty"` - SsoGroupName string `json:"ssoGroupName,omitempty"` - Description string `json:"description,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - SsoLinked bool `json:"ssoLinked,omitempty"` -} diff --git a/harness/nextgen/model_user_group_filter_dto.go b/harness/nextgen/model_user_group_filter_dto.go deleted file mode 100644 index 9cd05b77..00000000 --- a/harness/nextgen/model_user_group_filter_dto.go +++ /dev/null @@ -1,20 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type UserGroupFilterDto struct { - DatabaseIdFilter []string `json:"databaseIdFilter,omitempty"` - IdentifierFilter []string `json:"identifierFilter,omitempty"` - UserIdentifierFilter []string `json:"userIdentifierFilter,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - SearchTerm string `json:"searchTerm,omitempty"` -} diff --git a/harness/nextgen/model_user_metadata_dto.go b/harness/nextgen/model_user_metadata_dto.go deleted file mode 100644 index 1585b3b6..00000000 --- a/harness/nextgen/model_user_metadata_dto.go +++ /dev/null @@ -1,17 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type UserMetadataDto struct { - Name string `json:"name,omitempty"` - Email string `json:"email,omitempty"` - Uuid string `json:"uuid,omitempty"` - Locked bool `json:"locked,omitempty"` -} diff --git a/harness/nextgen/model_vault_config_dto.go b/harness/nextgen/model_vault_config_dto.go deleted file mode 100644 index 91c5dd7b..00000000 --- a/harness/nextgen/model_vault_config_dto.go +++ /dev/null @@ -1,37 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type VaultConfigDto struct { - Name string `json:"name,omitempty"` - AccountIdentifier string `json:"accountIdentifier,omitempty"` - OrgIdentifier string `json:"orgIdentifier,omitempty"` - ProjectIdentifier string `json:"projectIdentifier,omitempty"` - Tags map[string]string `json:"tags,omitempty"` - Identifier string `json:"identifier,omitempty"` - Description string `json:"description,omitempty"` - EncryptionType string `json:"encryptionType,omitempty"` - HarnessManaged bool `json:"harnessManaged,omitempty"` - Default_ bool `json:"default,omitempty"` - AuthToken string `json:"authToken,omitempty"` - BasePath string `json:"basePath,omitempty"` - Namespace string `json:"namespace,omitempty"` - SinkPath string `json:"sinkPath,omitempty"` - UseVaultAgent bool `json:"useVaultAgent,omitempty"` - VaultUrl string `json:"vaultUrl,omitempty"` - RenewalIntervalMinutes int64 `json:"renewalIntervalMinutes,omitempty"` - SecretEngineName string `json:"secretEngineName,omitempty"` - AppRoleId string `json:"appRoleId,omitempty"` - SecretId string `json:"secretId,omitempty"` - SecretEngineVersion int32 `json:"secretEngineVersion,omitempty"` - EngineManuallyEntered bool `json:"engineManuallyEntered,omitempty"` - DelegateSelectors []string `json:"delegateSelectors,omitempty"` - ReadOnly bool `json:"readOnly,omitempty"` -} diff --git a/harness/nextgen/model_verify_token_response_dto.go b/harness/nextgen/model_verify_token_response_dto.go deleted file mode 100644 index 66bd3704..00000000 --- a/harness/nextgen/model_verify_token_response_dto.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type VerifyTokenResponseDto struct { - AccountIdentifier string `json:"accountIdentifier,omitempty"` -} diff --git a/harness/nextgen/model_webhook_response.go b/harness/nextgen/model_webhook_response.go deleted file mode 100644 index eabd75ee..00000000 --- a/harness/nextgen/model_webhook_response.go +++ /dev/null @@ -1,32 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type WebhookResponse struct { - UnknownFields *UnknownFieldSet `json:"unknownFields,omitempty"` - Initialized bool `json:"initialized,omitempty"` - IdBytes *ByteString `json:"idBytes,omitempty"` - Active bool `json:"active,omitempty"` - NameBytes *ByteString `json:"nameBytes,omitempty"` - ParserForType *ParserWebhookResponse `json:"parserForType,omitempty"` - DefaultInstanceForType *WebhookResponse `json:"defaultInstanceForType,omitempty"` - SerializedSize int32 `json:"serializedSize,omitempty"` - SkipVerify bool `json:"skipVerify,omitempty"` - TargetBytes *ByteString `json:"targetBytes,omitempty"` - NativeEvents *NativeEvents `json:"nativeEvents,omitempty"` - NativeEventsOrBuilder *NativeEventsOrBuilder `json:"nativeEventsOrBuilder,omitempty"` - Name string `json:"name,omitempty"` - Id string `json:"id,omitempty"` - Target string `json:"target,omitempty"` - AllFields map[string]interface{} `json:"allFields,omitempty"` - InitializationErrorString string `json:"initializationErrorString,omitempty"` - DescriptorForType *Descriptor `json:"descriptorForType,omitempty"` - MemoizedSerializedSize int32 `json:"memoizedSerializedSize,omitempty"` -} diff --git a/harness/nextgen/model_workload_count_info.go b/harness/nextgen/model_workload_count_info.go deleted file mode 100644 index a009f95e..00000000 --- a/harness/nextgen/model_workload_count_info.go +++ /dev/null @@ -1,14 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type WorkloadCountInfo struct { - Count int64 `json:"count,omitempty"` -} diff --git a/harness/nextgen/model_workload_date_count_info.go b/harness/nextgen/model_workload_date_count_info.go deleted file mode 100644 index c53db15e..00000000 --- a/harness/nextgen/model_workload_date_count_info.go +++ /dev/null @@ -1,15 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type WorkloadDateCountInfo struct { - Date int64 `json:"date,omitempty"` - Execution *WorkloadCountInfo `json:"execution,omitempty"` -} diff --git a/harness/nextgen/model_workload_deployment_info.go b/harness/nextgen/model_workload_deployment_info.go deleted file mode 100644 index 5381cd8e..00000000 --- a/harness/nextgen/model_workload_deployment_info.go +++ /dev/null @@ -1,27 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type WorkloadDeploymentInfo struct { - ServiceName string `json:"serviceName,omitempty"` - ServiceId string `json:"serviceId,omitempty"` - LastExecuted *LastWorkloadInfo `json:"lastExecuted,omitempty"` - DeploymentTypeList []string `json:"deploymentTypeList,omitempty"` - TotalDeployments int64 `json:"totalDeployments,omitempty"` - TotalDeploymentChangeRate float64 `json:"totalDeploymentChangeRate,omitempty"` - PercentSuccess float64 `json:"percentSuccess,omitempty"` - RateSuccess float64 `json:"rateSuccess,omitempty"` - FailureRate float64 `json:"failureRate,omitempty"` - FailureRateChangeRate float64 `json:"failureRateChangeRate,omitempty"` - Frequency float64 `json:"frequency,omitempty"` - FrequencyChangeRate float64 `json:"frequencyChangeRate,omitempty"` - LastPipelineExecutionId string `json:"lastPipelineExecutionId,omitempty"` - Workload []WorkloadDateCountInfo `json:"workload,omitempty"` -} diff --git a/harness/nextgen/model_yaml_snippet_meta_data_dto.go b/harness/nextgen/model_yaml_snippet_meta_data_dto.go deleted file mode 100644 index ad2ded02..00000000 --- a/harness/nextgen/model_yaml_snippet_meta_data_dto.go +++ /dev/null @@ -1,19 +0,0 @@ -/* - * CD NextGen API Reference - * - * This is the Open Api Spec 3 for the NextGen Manager. This is under active development. Beware of the breaking change with respect to the generated code stub - * - * API version: 3.0 - * Contact: contact@harness.io - * Generated by: Swagger Codegen (https://github.com/swagger-api/swagger-codegen.git) - */ -package nextgen - -type YamlSnippetMetaDataDto struct { - Name string `json:"name,omitempty"` - Description string `json:"description,omitempty"` - Version string `json:"version,omitempty"` - Identifier string `json:"identifier,omitempty"` - Tags []string `json:"tags,omitempty"` - IconTag string `json:"iconTag,omitempty"` -}