datadog_api_client 2.45.0 → 2.46.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.generator/schemas/v1/openapi.yaml +81 -0
- data/.generator/schemas/v2/openapi.yaml +3968 -94
- data/.pre-commit-config.yaml +4 -0
- data/CHANGELOG.md +20 -0
- data/examples/v1/monitors/CreateMonitor_3541766733.rb +32 -0
- data/examples/v2/deployment-gates/CreateDeploymentGate.rb +20 -0
- data/examples/v2/deployment-gates/CreateDeploymentRule.rb +25 -0
- data/examples/v2/deployment-gates/DeleteDeploymentGate.rb +11 -0
- data/examples/v2/deployment-gates/DeleteDeploymentRule.rb +14 -0
- data/examples/v2/deployment-gates/GetDeploymentGate.rb +11 -0
- data/examples/v2/deployment-gates/GetDeploymentRule.rb +14 -0
- data/examples/v2/deployment-gates/UpdateDeploymentGate.rb +21 -0
- data/examples/v2/deployment-gates/UpdateDeploymentRule.rb +27 -0
- data/examples/v2/fleet-automation/GetFleetAgentInfo.rb +8 -0
- data/examples/v2/fleet-automation/ListFleetAgents.rb +8 -0
- data/examples/v2/logs-restriction-queries/AddRoleToRestrictionQuery.rb +21 -0
- data/examples/v2/logs-restriction-queries/CreateRestrictionQuery.rb +17 -0
- data/examples/v2/logs-restriction-queries/DeleteRestrictionQuery.rb +11 -0
- data/examples/v2/logs-restriction-queries/GetRestrictionQuery.rb +11 -0
- data/examples/v2/logs-restriction-queries/GetRoleRestrictionQuery.rb +11 -0
- data/examples/v2/logs-restriction-queries/ListRestrictionQueries.rb +8 -0
- data/examples/v2/logs-restriction-queries/ListRestrictionQueryRoles.rb +11 -0
- data/examples/v2/logs-restriction-queries/ListUserRestrictionQueries.rb +11 -0
- data/examples/v2/logs-restriction-queries/RemoveRoleFromRestrictionQuery.rb +21 -0
- data/examples/v2/logs-restriction-queries/ReplaceRestrictionQuery.rb +20 -0
- data/examples/v2/logs-restriction-queries/UpdateRestrictionQuery.rb +20 -0
- data/examples/v2/monitors/CreateMonitorNotificationRule_1379932371.rb +21 -0
- data/examples/v2/monitors/UpdateMonitorNotificationRule_1446058210.rb +24 -0
- data/examples/v2/on-call/CreateOnCallEscalationPolicy.rb +9 -0
- data/examples/v2/on-call/GetScheduleOnCallUser.rb +1 -1
- data/examples/v2/reference-tables/CreateReferenceTable.rb +23 -14
- data/examples/v2/reference-tables/DeleteRows.rb +14 -0
- data/examples/v2/reference-tables/UpsertRows.rb +19 -0
- data/examples/v2/security-monitoring/AttachCase.rb +26 -0
- data/examples/v2/security-monitoring/AttachCase_897782765.rb +22 -0
- data/examples/v2/security-monitoring/AttachJiraIssue.rb +34 -0
- data/examples/v2/security-monitoring/AttachJiraIssue_3042842144.rb +30 -0
- data/examples/v2/security-monitoring/CreateCases.rb +56 -0
- data/examples/v2/security-monitoring/CreateCases_2385516013.rb +33 -0
- data/examples/v2/security-monitoring/CreateCases_2798851680.rb +37 -0
- data/examples/v2/security-monitoring/CreateJiraIssues.rb +96 -0
- data/examples/v2/security-monitoring/CreateJiraIssues_379590688.rb +56 -0
- data/examples/v2/security-monitoring/CreateJiraIssues_829823123.rb +64 -0
- data/examples/v2/security-monitoring/DetachCase.rb +21 -0
- data/examples/v2/teams/AddTeamHierarchyLink.rb +31 -0
- data/examples/v2/{team-connections → teams}/CreateTeamConnections.rb +1 -1
- data/examples/v2/{team-connections → teams}/DeleteTeamConnections.rb +1 -1
- data/examples/v2/teams/GetTeamHierarchyLink.rb +8 -0
- data/examples/v2/teams/GetTeamSync.rb +8 -0
- data/examples/v2/{team-connections → teams}/ListTeamConnections.rb +1 -1
- data/examples/v2/{team-connections → teams}/ListTeamConnections_1473516764.rb +1 -1
- data/examples/v2/{team-connections → teams}/ListTeamConnections_2418873869.rb +1 -1
- data/examples/v2/teams/ListTeamHierarchyLinks.rb +15 -0
- data/examples/v2/teams/ListTeamHierarchyLinks_3360757486.rb +5 -0
- data/examples/v2/teams/RemoveTeamHierarchyLink.rb +8 -0
- data/lib/datadog_api_client/configuration.rb +25 -3
- data/lib/datadog_api_client/inflector.rb +141 -3
- data/lib/datadog_api_client/v1/api/monitors_api.rb +2 -0
- data/lib/datadog_api_client/v1/models/monitor.rb +13 -1
- data/lib/datadog_api_client/v1/models/monitor_asset.rb +186 -0
- data/lib/datadog_api_client/v1/models/monitor_asset_category.rb +26 -0
- data/lib/datadog_api_client/v1/models/monitor_asset_resource_type.rb +26 -0
- data/lib/datadog_api_client/v1/models/monitor_update_request.rb +14 -1
- data/lib/datadog_api_client/v1/models/usage_summary_date.rb +11 -1
- data/lib/datadog_api_client/v1/models/usage_summary_date_org.rb +11 -1
- data/lib/datadog_api_client/v1/models/usage_summary_response.rb +11 -1
- data/lib/datadog_api_client/v2/api/deployment_gates_api.rb +632 -0
- data/lib/datadog_api_client/v2/api/fleet_automation_api.rb +166 -1
- data/lib/datadog_api_client/v2/api/logs_restriction_queries_api.rb +842 -0
- data/lib/datadog_api_client/v2/api/on_call_api.rb +2 -2
- data/lib/datadog_api_client/v2/api/reference_tables_api.rb +144 -0
- data/lib/datadog_api_client/v2/api/security_monitoring_api.rb +355 -5
- data/lib/datadog_api_client/v2/api/teams_api.rb +628 -1
- data/lib/datadog_api_client/v2/models/attach_case_request.rb +105 -0
- data/lib/datadog_api_client/v2/models/attach_case_request_data.rb +154 -0
- data/lib/datadog_api_client/v2/models/attach_case_request_data_relationships.rb +123 -0
- data/lib/datadog_api_client/v2/models/attach_jira_issue_request.rb +105 -0
- data/lib/datadog_api_client/v2/models/attach_jira_issue_request_data.rb +153 -0
- data/lib/datadog_api_client/v2/models/attach_jira_issue_request_data_attributes.rb +123 -0
- data/lib/datadog_api_client/v2/models/attach_jira_issue_request_data_relationships.rb +144 -0
- data/lib/datadog_api_client/v2/models/batch_delete_rows_request_array.rb +129 -0
- data/lib/datadog_api_client/v2/models/batch_delete_rows_request_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/batch_upsert_rows_request_array.rb +129 -0
- data/lib/datadog_api_client/v2/models/batch_upsert_rows_request_data.rb +154 -0
- data/lib/datadog_api_client/v2/models/batch_upsert_rows_request_data_attributes.rb +123 -0
- data/lib/datadog_api_client/v2/models/case_data_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/case_insights_items.rb +125 -0
- data/lib/datadog_api_client/v2/models/case_management_project.rb +123 -0
- data/lib/datadog_api_client/v2/models/case_management_project_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/case_management_project_data_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/configured_schedule.rb +186 -0
- data/lib/datadog_api_client/v2/models/configured_schedule_target.rb +144 -0
- data/lib/datadog_api_client/v2/models/configured_schedule_target_attributes.rb +123 -0
- data/lib/datadog_api_client/v2/models/configured_schedule_target_relationships.rb +123 -0
- data/lib/datadog_api_client/v2/models/configured_schedule_target_relationships_schedule.rb +123 -0
- data/lib/datadog_api_client/v2/models/configured_schedule_target_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/create_case_request_array.rb +125 -0
- data/lib/datadog_api_client/v2/models/create_case_request_data.rb +153 -0
- data/lib/datadog_api_client/v2/models/create_case_request_data_attributes.rb +135 -0
- data/lib/datadog_api_client/v2/models/create_case_request_data_relationships.rb +144 -0
- data/lib/datadog_api_client/v2/models/create_deployment_gate_params.rb +123 -0
- data/lib/datadog_api_client/v2/models/create_deployment_gate_params_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/create_deployment_gate_params_data_attributes.rb +164 -0
- data/lib/datadog_api_client/v2/models/create_deployment_rule_params.rb +105 -0
- data/lib/datadog_api_client/v2/models/create_deployment_rule_params_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/create_deployment_rule_params_data_attributes.rb +175 -0
- data/lib/datadog_api_client/v2/models/create_jira_issue_request_array.rb +137 -0
- data/lib/datadog_api_client/v2/models/create_jira_issue_request_array_included.rb +64 -0
- data/lib/datadog_api_client/v2/models/create_jira_issue_request_data.rb +153 -0
- data/lib/datadog_api_client/v2/models/create_jira_issue_request_data_attributes.rb +105 -0
- data/lib/datadog_api_client/v2/models/create_jira_issue_request_data_attributes_fields.rb +105 -0
- data/lib/datadog_api_client/v2/models/create_jira_issue_request_data_relationships.rb +123 -0
- data/lib/datadog_api_client/v2/models/create_jira_issue_request_data_relationships_case.rb +123 -0
- data/lib/datadog_api_client/v2/models/create_jira_issue_request_data_relationships_case_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/deployment_gate_data_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/deployment_gate_response.rb +105 -0
- data/lib/datadog_api_client/v2/models/deployment_gate_response_data.rb +165 -0
- data/lib/datadog_api_client/v2/models/deployment_gate_response_data_attributes.rb +248 -0
- data/lib/datadog_api_client/v2/models/deployment_gate_response_data_attributes_created_by.rb +143 -0
- data/lib/datadog_api_client/v2/models/deployment_gate_response_data_attributes_updated_by.rb +143 -0
- data/lib/datadog_api_client/v2/models/deployment_rule_data_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/{table_result_v2_data_attributes_file_metadata_local_file.rb → deployment_rule_options_faulty_deployment_detection.rb} +21 -19
- data/lib/datadog_api_client/v2/models/deployment_rule_options_monitor.rb +108 -0
- data/lib/datadog_api_client/v2/models/deployment_rule_response.rb +105 -0
- data/lib/datadog_api_client/v2/models/deployment_rule_response_data.rb +165 -0
- data/lib/datadog_api_client/v2/models/deployment_rule_response_data_attributes.rb +269 -0
- data/lib/datadog_api_client/v2/models/deployment_rule_response_data_attributes_created_by.rb +143 -0
- data/lib/datadog_api_client/v2/models/deployment_rule_response_data_attributes_type.rb +27 -0
- data/lib/datadog_api_client/v2/models/deployment_rule_response_data_attributes_updated_by.rb +143 -0
- data/lib/datadog_api_client/v2/models/deployment_rules_options.rb +63 -0
- data/lib/datadog_api_client/v2/models/detach_case_request.rb +105 -0
- data/lib/datadog_api_client/v2/models/detach_case_request_data.rb +143 -0
- data/lib/datadog_api_client/v2/models/detach_case_request_data_relationships.rb +123 -0
- data/lib/datadog_api_client/v2/models/escalation_policy_create_request_data_attributes.rb +28 -1
- data/lib/datadog_api_client/v2/models/escalation_policy_create_request_data_attributes_steps_items.rb +16 -1
- data/lib/datadog_api_client/v2/models/escalation_policy_data_attributes.rb +20 -1
- data/lib/datadog_api_client/v2/models/escalation_policy_included.rb +3 -2
- data/lib/datadog_api_client/v2/models/escalation_policy_step_target.rb +12 -2
- data/lib/datadog_api_client/v2/models/escalation_policy_step_target_config.rb +105 -0
- data/lib/datadog_api_client/v2/models/escalation_policy_step_target_config_schedule.rb +105 -0
- data/lib/datadog_api_client/v2/models/escalation_policy_update_request_data_attributes.rb +28 -1
- data/lib/datadog_api_client/v2/models/escalation_policy_update_request_data_attributes_steps_items.rb +16 -1
- data/lib/datadog_api_client/v2/models/escalation_target.rb +3 -2
- data/lib/datadog_api_client/v2/models/finding_case_response.rb +105 -0
- data/lib/datadog_api_client/v2/models/finding_case_response_array.rb +125 -0
- data/lib/datadog_api_client/v2/models/finding_case_response_data.rb +153 -0
- data/lib/datadog_api_client/v2/models/finding_case_response_data_attributes.rb +277 -0
- data/lib/datadog_api_client/v2/models/finding_case_response_data_relationships.rb +125 -0
- data/lib/datadog_api_client/v2/models/finding_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/finding_data_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/finding_jira_issue.rb +125 -0
- data/lib/datadog_api_client/v2/models/finding_jira_issue_result.rb +135 -0
- data/lib/datadog_api_client/v2/models/findings.rb +107 -0
- data/lib/datadog_api_client/v2/models/fleet_agent_attributes.rb +327 -0
- data/lib/datadog_api_client/v2/models/fleet_agent_attributes_tags_items.rb +115 -0
- data/lib/datadog_api_client/v2/models/fleet_agent_info.rb +165 -0
- data/lib/datadog_api_client/v2/models/fleet_agent_info_attributes.rb +137 -0
- data/lib/datadog_api_client/v2/models/fleet_agent_info_details.rb +403 -0
- data/lib/datadog_api_client/v2/models/fleet_agent_info_resource_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/fleet_agent_info_response.rb +123 -0
- data/lib/datadog_api_client/v2/models/fleet_agents_response.rb +133 -0
- data/lib/datadog_api_client/v2/models/fleet_agents_response_data.rb +165 -0
- data/lib/datadog_api_client/v2/models/fleet_agents_response_data_attributes.rb +107 -0
- data/lib/datadog_api_client/v2/models/fleet_agents_response_meta.rb +105 -0
- data/lib/datadog_api_client/v2/models/fleet_configuration_file.rb +125 -0
- data/lib/datadog_api_client/v2/models/fleet_configuration_layer.rb +155 -0
- data/lib/datadog_api_client/v2/models/fleet_detected_integration.rb +115 -0
- data/lib/datadog_api_client/v2/models/fleet_integration_details.rb +197 -0
- data/lib/datadog_api_client/v2/models/fleet_integrations_by_status.rb +165 -0
- data/lib/datadog_api_client/v2/models/httpcd_gates_bad_request_response.rb +107 -0
- data/lib/datadog_api_client/v2/models/httpcd_gates_not_found_response.rb +107 -0
- data/lib/datadog_api_client/v2/models/httpcd_rules_not_found_response.rb +107 -0
- data/lib/datadog_api_client/v2/models/jira_issues_data_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/layer_attributes.rb +13 -3
- data/lib/datadog_api_client/v2/models/logs_restriction_queries_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/monitor_notification_rule_attributes.rb +2 -2
- data/lib/datadog_api_client/v2/models/monitor_notification_rule_condition.rb +1 -1
- data/lib/datadog_api_client/v2/models/monitor_notification_rule_conditional_recipients.rb +2 -2
- data/lib/datadog_api_client/v2/models/monitor_notification_rule_filter.rb +2 -1
- data/lib/datadog_api_client/v2/models/monitor_notification_rule_filter_scope.rb +106 -0
- data/lib/datadog_api_client/v2/models/monitor_notification_rule_filter_tags.rb +2 -2
- data/lib/datadog_api_client/v2/models/monitor_notification_rule_response_attributes.rb +2 -2
- data/lib/datadog_api_client/v2/models/observability_pipeline_google_chronicle_destination.rb +1 -12
- data/lib/datadog_api_client/v2/models/observability_pipeline_google_cloud_storage_destination.rb +2 -24
- data/lib/datadog_api_client/v2/models/observability_pipeline_google_pub_sub_source.rb +1 -12
- data/lib/datadog_api_client/v2/models/relationship_to_user_team_permission.rb +8 -0
- data/lib/datadog_api_client/v2/models/restriction_query_attributes.rb +165 -0
- data/lib/datadog_api_client/v2/models/restriction_query_create_attributes.rb +123 -0
- data/lib/datadog_api_client/v2/models/restriction_query_create_data.rb +115 -0
- data/lib/datadog_api_client/v2/models/restriction_query_create_payload.rb +105 -0
- data/lib/datadog_api_client/v2/models/restriction_query_list_response.rb +107 -0
- data/lib/datadog_api_client/v2/models/restriction_query_response_included_item.rb +62 -0
- data/lib/datadog_api_client/v2/models/restriction_query_role.rb +165 -0
- data/lib/datadog_api_client/v2/models/restriction_query_role_attribute.rb +105 -0
- data/lib/datadog_api_client/v2/models/restriction_query_roles_response.rb +107 -0
- data/lib/datadog_api_client/v2/models/restriction_query_update_attributes.rb +123 -0
- data/lib/datadog_api_client/v2/models/restriction_query_update_data.rb +115 -0
- data/lib/datadog_api_client/v2/models/restriction_query_update_payload.rb +105 -0
- data/lib/datadog_api_client/v2/models/restriction_query_with_relationships.rb +135 -0
- data/lib/datadog_api_client/v2/models/restriction_query_with_relationships_response.rb +117 -0
- data/lib/datadog_api_client/v2/models/restriction_query_without_relationships.rb +125 -0
- data/lib/datadog_api_client/v2/models/restriction_query_without_relationships_response.rb +105 -0
- data/lib/datadog_api_client/v2/models/schedule_create_request_data_attributes_layers_items.rb +13 -3
- data/lib/datadog_api_client/v2/models/schedule_target.rb +1 -1
- data/lib/datadog_api_client/v2/models/schedule_target_position.rb +28 -0
- data/lib/datadog_api_client/v2/models/schedule_update_request_data_attributes_layers_items.rb +13 -3
- data/lib/datadog_api_client/v2/models/table_result_v2_data_attributes.rb +8 -0
- data/lib/datadog_api_client/v2/models/table_result_v2_data_attributes_file_metadata.rb +101 -36
- data/lib/datadog_api_client/v2/models/team_attributes.rb +13 -1
- data/lib/datadog_api_client/v2/models/team_hierarchy_link.rb +175 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_attributes.rb +144 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_create.rb +144 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_create_relationships.rb +144 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_create_request.rb +123 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_create_team.rb +144 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_create_team_relationship.rb +123 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_relationships.rb +144 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_response.rb +127 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_team.rb +154 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_team_attributes.rb +223 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_team_relationship.rb +123 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_link_type.rb +26 -0
- data/lib/datadog_api_client/v2/models/team_hierarchy_links_response.rb +139 -0
- data/lib/datadog_api_client/v2/models/team_sync_attributes.rb +22 -2
- data/lib/datadog_api_client/v2/models/team_sync_attributes_frequency.rb +28 -0
- data/lib/datadog_api_client/v2/models/team_sync_attributes_type.rb +2 -1
- data/lib/datadog_api_client/v2/models/team_sync_data.rb +12 -2
- data/lib/datadog_api_client/v2/models/team_sync_request.rb +1 -1
- data/lib/datadog_api_client/v2/models/team_sync_response.rb +107 -0
- data/lib/datadog_api_client/v2/models/teams_hierarchy_links_response_links.rb +156 -0
- data/lib/datadog_api_client/v2/models/teams_hierarchy_links_response_meta.rb +105 -0
- data/lib/datadog_api_client/v2/models/teams_hierarchy_links_response_meta_page.rb +184 -0
- data/lib/datadog_api_client/v2/models/threat_hunting_job_response_attributes.rb +13 -3
- data/lib/datadog_api_client/v2/models/update_deployment_gate_params.rb +123 -0
- data/lib/datadog_api_client/v2/models/update_deployment_gate_params_data.rb +165 -0
- data/lib/datadog_api_client/v2/models/update_deployment_gate_params_data_attributes.rb +123 -0
- data/lib/datadog_api_client/v2/models/update_deployment_rule_params.rb +123 -0
- data/lib/datadog_api_client/v2/models/update_deployment_rule_params_data.rb +144 -0
- data/lib/datadog_api_client/v2/models/update_deployment_rule_params_data_attributes.rb +165 -0
- data/lib/datadog_api_client/version.rb +1 -1
- metadata +190 -9
- data/lib/datadog_api_client/v2/api/team_connections_api.rb +0 -272
- data/lib/datadog_api_client/v2/models/table_result_v2_data_attributes_file_metadata_cloud_storage.rb +0 -138
|
@@ -36,11 +36,16 @@ module DatadogAPIClient::V2
|
|
|
36
36
|
# Add a member team.
|
|
37
37
|
# Adds the team given by the `id` in the body as a member team of the super team.
|
|
38
38
|
#
|
|
39
|
+
# **Note**: This API is deprecated. For creating team hierarchy links, use the team hierarchy links API: `POST /api/v2/team-hierarchy-links`.
|
|
40
|
+
#
|
|
41
|
+
# @deprecated This API is deprecated.
|
|
42
|
+
#
|
|
39
43
|
# @param super_team_id [String] None
|
|
40
44
|
# @param body [AddMemberTeamRequest]
|
|
41
45
|
# @param opts [Hash] the optional parameters
|
|
42
46
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
43
47
|
def add_member_team_with_http_info(super_team_id, body, opts = {})
|
|
48
|
+
warn "[DEPRECATION] `AddMemberTeam` is deprecated."
|
|
44
49
|
unstable_enabled = @api_client.config.unstable_operations["v2.add_member_team".to_sym]
|
|
45
50
|
if unstable_enabled
|
|
46
51
|
@api_client.config.logger.warn format("Using unstable operation '%s'", "v2.add_member_team")
|
|
@@ -102,6 +107,73 @@ module DatadogAPIClient::V2
|
|
|
102
107
|
return data, status_code, headers
|
|
103
108
|
end
|
|
104
109
|
|
|
110
|
+
# Create a team hierarchy link.
|
|
111
|
+
#
|
|
112
|
+
# @see #add_team_hierarchy_link_with_http_info
|
|
113
|
+
def add_team_hierarchy_link(body, opts = {})
|
|
114
|
+
data, _status_code, _headers = add_team_hierarchy_link_with_http_info(body, opts)
|
|
115
|
+
data
|
|
116
|
+
end
|
|
117
|
+
|
|
118
|
+
# Create a team hierarchy link.
|
|
119
|
+
#
|
|
120
|
+
# Create a new team hierarchy link between a parent team and a sub team.
|
|
121
|
+
#
|
|
122
|
+
# @param body [TeamHierarchyLinkCreateRequest]
|
|
123
|
+
# @param opts [Hash] the optional parameters
|
|
124
|
+
# @return [Array<(TeamHierarchyLinkResponse, Integer, Hash)>] TeamHierarchyLinkResponse data, response status code and response headers
|
|
125
|
+
def add_team_hierarchy_link_with_http_info(body, opts = {})
|
|
126
|
+
|
|
127
|
+
if @api_client.config.debugging
|
|
128
|
+
@api_client.config.logger.debug 'Calling API: TeamsAPI.add_team_hierarchy_link ...'
|
|
129
|
+
end
|
|
130
|
+
# verify the required parameter 'body' is set
|
|
131
|
+
if @api_client.config.client_side_validation && body.nil?
|
|
132
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling TeamsAPI.add_team_hierarchy_link"
|
|
133
|
+
end
|
|
134
|
+
# resource path
|
|
135
|
+
local_var_path = '/api/v2/team-hierarchy-links'
|
|
136
|
+
|
|
137
|
+
# query parameters
|
|
138
|
+
query_params = opts[:query_params] || {}
|
|
139
|
+
|
|
140
|
+
# header parameters
|
|
141
|
+
header_params = opts[:header_params] || {}
|
|
142
|
+
# HTTP header 'Accept' (if needed)
|
|
143
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
144
|
+
# HTTP header 'Content-Type'
|
|
145
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
|
146
|
+
|
|
147
|
+
# form parameters
|
|
148
|
+
form_params = opts[:form_params] || {}
|
|
149
|
+
|
|
150
|
+
# http body (model)
|
|
151
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
|
|
152
|
+
|
|
153
|
+
# return_type
|
|
154
|
+
return_type = opts[:debug_return_type] || 'TeamHierarchyLinkResponse'
|
|
155
|
+
|
|
156
|
+
# auth_names
|
|
157
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
|
|
158
|
+
|
|
159
|
+
new_options = opts.merge(
|
|
160
|
+
:operation => :add_team_hierarchy_link,
|
|
161
|
+
:header_params => header_params,
|
|
162
|
+
:query_params => query_params,
|
|
163
|
+
:form_params => form_params,
|
|
164
|
+
:body => post_body,
|
|
165
|
+
:auth_names => auth_names,
|
|
166
|
+
:return_type => return_type,
|
|
167
|
+
:api_version => "V2"
|
|
168
|
+
)
|
|
169
|
+
|
|
170
|
+
data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, new_options)
|
|
171
|
+
if @api_client.config.debugging
|
|
172
|
+
@api_client.config.logger.debug "API called: TeamsAPI#add_team_hierarchy_link\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
173
|
+
end
|
|
174
|
+
return data, status_code, headers
|
|
175
|
+
end
|
|
176
|
+
|
|
105
177
|
# Create a team.
|
|
106
178
|
#
|
|
107
179
|
# @see #create_team_with_http_info
|
|
@@ -170,6 +242,79 @@ module DatadogAPIClient::V2
|
|
|
170
242
|
return data, status_code, headers
|
|
171
243
|
end
|
|
172
244
|
|
|
245
|
+
# Create team connections.
|
|
246
|
+
#
|
|
247
|
+
# @see #create_team_connections_with_http_info
|
|
248
|
+
def create_team_connections(body, opts = {})
|
|
249
|
+
data, _status_code, _headers = create_team_connections_with_http_info(body, opts)
|
|
250
|
+
data
|
|
251
|
+
end
|
|
252
|
+
|
|
253
|
+
# Create team connections.
|
|
254
|
+
#
|
|
255
|
+
# Create multiple team connections.
|
|
256
|
+
#
|
|
257
|
+
# @param body [TeamConnectionCreateRequest]
|
|
258
|
+
# @param opts [Hash] the optional parameters
|
|
259
|
+
# @return [Array<(TeamConnectionsResponse, Integer, Hash)>] TeamConnectionsResponse data, response status code and response headers
|
|
260
|
+
def create_team_connections_with_http_info(body, opts = {})
|
|
261
|
+
unstable_enabled = @api_client.config.unstable_operations["v2.create_team_connections".to_sym]
|
|
262
|
+
if unstable_enabled
|
|
263
|
+
@api_client.config.logger.warn format("Using unstable operation '%s'", "v2.create_team_connections")
|
|
264
|
+
else
|
|
265
|
+
raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.create_team_connections"))
|
|
266
|
+
end
|
|
267
|
+
|
|
268
|
+
if @api_client.config.debugging
|
|
269
|
+
@api_client.config.logger.debug 'Calling API: TeamsAPI.create_team_connections ...'
|
|
270
|
+
end
|
|
271
|
+
# verify the required parameter 'body' is set
|
|
272
|
+
if @api_client.config.client_side_validation && body.nil?
|
|
273
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling TeamsAPI.create_team_connections"
|
|
274
|
+
end
|
|
275
|
+
# resource path
|
|
276
|
+
local_var_path = '/api/v2/team/connections'
|
|
277
|
+
|
|
278
|
+
# query parameters
|
|
279
|
+
query_params = opts[:query_params] || {}
|
|
280
|
+
|
|
281
|
+
# header parameters
|
|
282
|
+
header_params = opts[:header_params] || {}
|
|
283
|
+
# HTTP header 'Accept' (if needed)
|
|
284
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
285
|
+
# HTTP header 'Content-Type'
|
|
286
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
|
287
|
+
|
|
288
|
+
# form parameters
|
|
289
|
+
form_params = opts[:form_params] || {}
|
|
290
|
+
|
|
291
|
+
# http body (model)
|
|
292
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
|
|
293
|
+
|
|
294
|
+
# return_type
|
|
295
|
+
return_type = opts[:debug_return_type] || 'TeamConnectionsResponse'
|
|
296
|
+
|
|
297
|
+
# auth_names
|
|
298
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
|
|
299
|
+
|
|
300
|
+
new_options = opts.merge(
|
|
301
|
+
:operation => :create_team_connections,
|
|
302
|
+
:header_params => header_params,
|
|
303
|
+
:query_params => query_params,
|
|
304
|
+
:form_params => form_params,
|
|
305
|
+
:body => post_body,
|
|
306
|
+
:auth_names => auth_names,
|
|
307
|
+
:return_type => return_type,
|
|
308
|
+
:api_version => "V2"
|
|
309
|
+
)
|
|
310
|
+
|
|
311
|
+
data, status_code, headers = @api_client.call_api(Net::HTTP::Post, local_var_path, new_options)
|
|
312
|
+
if @api_client.config.debugging
|
|
313
|
+
@api_client.config.logger.debug "API called: TeamsAPI#create_team_connections\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
314
|
+
end
|
|
315
|
+
return data, status_code, headers
|
|
316
|
+
end
|
|
317
|
+
|
|
173
318
|
# Create a team link.
|
|
174
319
|
#
|
|
175
320
|
# @see #create_team_link_with_http_info
|
|
@@ -379,6 +524,79 @@ module DatadogAPIClient::V2
|
|
|
379
524
|
return data, status_code, headers
|
|
380
525
|
end
|
|
381
526
|
|
|
527
|
+
# Delete team connections.
|
|
528
|
+
#
|
|
529
|
+
# @see #delete_team_connections_with_http_info
|
|
530
|
+
def delete_team_connections(body, opts = {})
|
|
531
|
+
delete_team_connections_with_http_info(body, opts)
|
|
532
|
+
nil
|
|
533
|
+
end
|
|
534
|
+
|
|
535
|
+
# Delete team connections.
|
|
536
|
+
#
|
|
537
|
+
# Delete multiple team connections.
|
|
538
|
+
#
|
|
539
|
+
# @param body [TeamConnectionDeleteRequest]
|
|
540
|
+
# @param opts [Hash] the optional parameters
|
|
541
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
542
|
+
def delete_team_connections_with_http_info(body, opts = {})
|
|
543
|
+
unstable_enabled = @api_client.config.unstable_operations["v2.delete_team_connections".to_sym]
|
|
544
|
+
if unstable_enabled
|
|
545
|
+
@api_client.config.logger.warn format("Using unstable operation '%s'", "v2.delete_team_connections")
|
|
546
|
+
else
|
|
547
|
+
raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.delete_team_connections"))
|
|
548
|
+
end
|
|
549
|
+
|
|
550
|
+
if @api_client.config.debugging
|
|
551
|
+
@api_client.config.logger.debug 'Calling API: TeamsAPI.delete_team_connections ...'
|
|
552
|
+
end
|
|
553
|
+
# verify the required parameter 'body' is set
|
|
554
|
+
if @api_client.config.client_side_validation && body.nil?
|
|
555
|
+
fail ArgumentError, "Missing the required parameter 'body' when calling TeamsAPI.delete_team_connections"
|
|
556
|
+
end
|
|
557
|
+
# resource path
|
|
558
|
+
local_var_path = '/api/v2/team/connections'
|
|
559
|
+
|
|
560
|
+
# query parameters
|
|
561
|
+
query_params = opts[:query_params] || {}
|
|
562
|
+
|
|
563
|
+
# header parameters
|
|
564
|
+
header_params = opts[:header_params] || {}
|
|
565
|
+
# HTTP header 'Accept' (if needed)
|
|
566
|
+
header_params['Accept'] = @api_client.select_header_accept(['*/*'])
|
|
567
|
+
# HTTP header 'Content-Type'
|
|
568
|
+
header_params['Content-Type'] = @api_client.select_header_content_type(['application/json'])
|
|
569
|
+
|
|
570
|
+
# form parameters
|
|
571
|
+
form_params = opts[:form_params] || {}
|
|
572
|
+
|
|
573
|
+
# http body (model)
|
|
574
|
+
post_body = opts[:debug_body] || @api_client.object_to_http_body(body)
|
|
575
|
+
|
|
576
|
+
# return_type
|
|
577
|
+
return_type = opts[:debug_return_type]
|
|
578
|
+
|
|
579
|
+
# auth_names
|
|
580
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
|
|
581
|
+
|
|
582
|
+
new_options = opts.merge(
|
|
583
|
+
:operation => :delete_team_connections,
|
|
584
|
+
:header_params => header_params,
|
|
585
|
+
:query_params => query_params,
|
|
586
|
+
:form_params => form_params,
|
|
587
|
+
:body => post_body,
|
|
588
|
+
:auth_names => auth_names,
|
|
589
|
+
:return_type => return_type,
|
|
590
|
+
:api_version => "V2"
|
|
591
|
+
)
|
|
592
|
+
|
|
593
|
+
data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, new_options)
|
|
594
|
+
if @api_client.config.debugging
|
|
595
|
+
@api_client.config.logger.debug "API called: TeamsAPI#delete_team_connections\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
596
|
+
end
|
|
597
|
+
return data, status_code, headers
|
|
598
|
+
end
|
|
599
|
+
|
|
382
600
|
# Remove a team link.
|
|
383
601
|
#
|
|
384
602
|
# @see #delete_team_link_with_http_info
|
|
@@ -584,6 +802,71 @@ module DatadogAPIClient::V2
|
|
|
584
802
|
return data, status_code, headers
|
|
585
803
|
end
|
|
586
804
|
|
|
805
|
+
# Get a team hierarchy link.
|
|
806
|
+
#
|
|
807
|
+
# @see #get_team_hierarchy_link_with_http_info
|
|
808
|
+
def get_team_hierarchy_link(link_id, opts = {})
|
|
809
|
+
data, _status_code, _headers = get_team_hierarchy_link_with_http_info(link_id, opts)
|
|
810
|
+
data
|
|
811
|
+
end
|
|
812
|
+
|
|
813
|
+
# Get a team hierarchy link.
|
|
814
|
+
#
|
|
815
|
+
# Get a single team hierarchy link for the given link_id.
|
|
816
|
+
#
|
|
817
|
+
# @param link_id [String] The team hierarchy link's identifier
|
|
818
|
+
# @param opts [Hash] the optional parameters
|
|
819
|
+
# @return [Array<(TeamHierarchyLinkResponse, Integer, Hash)>] TeamHierarchyLinkResponse data, response status code and response headers
|
|
820
|
+
def get_team_hierarchy_link_with_http_info(link_id, opts = {})
|
|
821
|
+
|
|
822
|
+
if @api_client.config.debugging
|
|
823
|
+
@api_client.config.logger.debug 'Calling API: TeamsAPI.get_team_hierarchy_link ...'
|
|
824
|
+
end
|
|
825
|
+
# verify the required parameter 'link_id' is set
|
|
826
|
+
if @api_client.config.client_side_validation && link_id.nil?
|
|
827
|
+
fail ArgumentError, "Missing the required parameter 'link_id' when calling TeamsAPI.get_team_hierarchy_link"
|
|
828
|
+
end
|
|
829
|
+
# resource path
|
|
830
|
+
local_var_path = '/api/v2/team-hierarchy-links/{link_id}'.sub('{link_id}', CGI.escape(link_id.to_s).gsub('%2F', '/'))
|
|
831
|
+
|
|
832
|
+
# query parameters
|
|
833
|
+
query_params = opts[:query_params] || {}
|
|
834
|
+
|
|
835
|
+
# header parameters
|
|
836
|
+
header_params = opts[:header_params] || {}
|
|
837
|
+
# HTTP header 'Accept' (if needed)
|
|
838
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
839
|
+
|
|
840
|
+
# form parameters
|
|
841
|
+
form_params = opts[:form_params] || {}
|
|
842
|
+
|
|
843
|
+
# http body (model)
|
|
844
|
+
post_body = opts[:debug_body]
|
|
845
|
+
|
|
846
|
+
# return_type
|
|
847
|
+
return_type = opts[:debug_return_type] || 'TeamHierarchyLinkResponse'
|
|
848
|
+
|
|
849
|
+
# auth_names
|
|
850
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
|
|
851
|
+
|
|
852
|
+
new_options = opts.merge(
|
|
853
|
+
:operation => :get_team_hierarchy_link,
|
|
854
|
+
:header_params => header_params,
|
|
855
|
+
:query_params => query_params,
|
|
856
|
+
:form_params => form_params,
|
|
857
|
+
:body => post_body,
|
|
858
|
+
:auth_names => auth_names,
|
|
859
|
+
:return_type => return_type,
|
|
860
|
+
:api_version => "V2"
|
|
861
|
+
)
|
|
862
|
+
|
|
863
|
+
data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
|
|
864
|
+
if @api_client.config.debugging
|
|
865
|
+
@api_client.config.logger.debug "API called: TeamsAPI#get_team_hierarchy_link\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
866
|
+
end
|
|
867
|
+
return data, status_code, headers
|
|
868
|
+
end
|
|
869
|
+
|
|
587
870
|
# Get a team link.
|
|
588
871
|
#
|
|
589
872
|
# @see #get_team_link_with_http_info
|
|
@@ -883,6 +1166,84 @@ module DatadogAPIClient::V2
|
|
|
883
1166
|
return data, status_code, headers
|
|
884
1167
|
end
|
|
885
1168
|
|
|
1169
|
+
# Get team sync configurations.
|
|
1170
|
+
#
|
|
1171
|
+
# @see #get_team_sync_with_http_info
|
|
1172
|
+
def get_team_sync(filter_source, opts = {})
|
|
1173
|
+
data, _status_code, _headers = get_team_sync_with_http_info(filter_source, opts)
|
|
1174
|
+
data
|
|
1175
|
+
end
|
|
1176
|
+
|
|
1177
|
+
# Get team sync configurations.
|
|
1178
|
+
#
|
|
1179
|
+
# Get all team synchronization configurations.
|
|
1180
|
+
# Returns a list of configurations used for linking or provisioning teams with external sources like GitHub.
|
|
1181
|
+
#
|
|
1182
|
+
# @param filter_source [TeamSyncAttributesSource] Filter by the external source platform for team synchronization
|
|
1183
|
+
# @param opts [Hash] the optional parameters
|
|
1184
|
+
# @return [Array<(TeamSyncResponse, Integer, Hash)>] TeamSyncResponse data, response status code and response headers
|
|
1185
|
+
def get_team_sync_with_http_info(filter_source, opts = {})
|
|
1186
|
+
unstable_enabled = @api_client.config.unstable_operations["v2.get_team_sync".to_sym]
|
|
1187
|
+
if unstable_enabled
|
|
1188
|
+
@api_client.config.logger.warn format("Using unstable operation '%s'", "v2.get_team_sync")
|
|
1189
|
+
else
|
|
1190
|
+
raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.get_team_sync"))
|
|
1191
|
+
end
|
|
1192
|
+
|
|
1193
|
+
if @api_client.config.debugging
|
|
1194
|
+
@api_client.config.logger.debug 'Calling API: TeamsAPI.get_team_sync ...'
|
|
1195
|
+
end
|
|
1196
|
+
# verify the required parameter 'filter_source' is set
|
|
1197
|
+
if @api_client.config.client_side_validation && filter_source.nil?
|
|
1198
|
+
fail ArgumentError, "Missing the required parameter 'filter_source' when calling TeamsAPI.get_team_sync"
|
|
1199
|
+
end
|
|
1200
|
+
# verify enum value
|
|
1201
|
+
allowable_values = ['github']
|
|
1202
|
+
if @api_client.config.client_side_validation && !allowable_values.include?(filter_source)
|
|
1203
|
+
fail ArgumentError, "invalid value for \"filter_source\", must be one of #{allowable_values}"
|
|
1204
|
+
end
|
|
1205
|
+
# resource path
|
|
1206
|
+
local_var_path = '/api/v2/team/sync'
|
|
1207
|
+
|
|
1208
|
+
# query parameters
|
|
1209
|
+
query_params = opts[:query_params] || {}
|
|
1210
|
+
query_params[:'filter[source]'] = filter_source
|
|
1211
|
+
|
|
1212
|
+
# header parameters
|
|
1213
|
+
header_params = opts[:header_params] || {}
|
|
1214
|
+
# HTTP header 'Accept' (if needed)
|
|
1215
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
1216
|
+
|
|
1217
|
+
# form parameters
|
|
1218
|
+
form_params = opts[:form_params] || {}
|
|
1219
|
+
|
|
1220
|
+
# http body (model)
|
|
1221
|
+
post_body = opts[:debug_body]
|
|
1222
|
+
|
|
1223
|
+
# return_type
|
|
1224
|
+
return_type = opts[:debug_return_type] || 'TeamSyncResponse'
|
|
1225
|
+
|
|
1226
|
+
# auth_names
|
|
1227
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
|
|
1228
|
+
|
|
1229
|
+
new_options = opts.merge(
|
|
1230
|
+
:operation => :get_team_sync,
|
|
1231
|
+
:header_params => header_params,
|
|
1232
|
+
:query_params => query_params,
|
|
1233
|
+
:form_params => form_params,
|
|
1234
|
+
:body => post_body,
|
|
1235
|
+
:auth_names => auth_names,
|
|
1236
|
+
:return_type => return_type,
|
|
1237
|
+
:api_version => "V2"
|
|
1238
|
+
)
|
|
1239
|
+
|
|
1240
|
+
data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
|
|
1241
|
+
if @api_client.config.debugging
|
|
1242
|
+
@api_client.config.logger.debug "API called: TeamsAPI#get_team_sync\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1243
|
+
end
|
|
1244
|
+
return data, status_code, headers
|
|
1245
|
+
end
|
|
1246
|
+
|
|
886
1247
|
# Get user memberships.
|
|
887
1248
|
#
|
|
888
1249
|
# @see #get_user_memberships_with_http_info
|
|
@@ -960,6 +1321,11 @@ module DatadogAPIClient::V2
|
|
|
960
1321
|
#
|
|
961
1322
|
# Get all member teams.
|
|
962
1323
|
#
|
|
1324
|
+
# **Note**: This API is deprecated. For team hierarchy relationships (parent-child
|
|
1325
|
+
# teams), use the team hierarchy links API: `GET /api/v2/team-hierarchy-links`.
|
|
1326
|
+
#
|
|
1327
|
+
# @deprecated This API is deprecated.
|
|
1328
|
+
#
|
|
963
1329
|
# @param super_team_id [String] None
|
|
964
1330
|
# @param opts [Hash] the optional parameters
|
|
965
1331
|
# @option opts [Integer] :page_size Size for a given page. The maximum allowed value is 100.
|
|
@@ -967,6 +1333,7 @@ module DatadogAPIClient::V2
|
|
|
967
1333
|
# @option opts [Array<TeamsField>] :fields_team List of fields that need to be fetched.
|
|
968
1334
|
# @return [Array<(TeamsResponse, Integer, Hash)>] TeamsResponse data, response status code and response headers
|
|
969
1335
|
def list_member_teams_with_http_info(super_team_id, opts = {})
|
|
1336
|
+
warn "[DEPRECATION] `ListMemberTeams` is deprecated."
|
|
970
1337
|
unstable_enabled = @api_client.config.unstable_operations["v2.list_member_teams".to_sym]
|
|
971
1338
|
if unstable_enabled
|
|
972
1339
|
@api_client.config.logger.warn format("Using unstable operation '%s'", "v2.list_member_teams")
|
|
@@ -1047,6 +1414,196 @@ module DatadogAPIClient::V2
|
|
|
1047
1414
|
end
|
|
1048
1415
|
end
|
|
1049
1416
|
|
|
1417
|
+
# List team connections.
|
|
1418
|
+
#
|
|
1419
|
+
# @see #list_team_connections_with_http_info
|
|
1420
|
+
def list_team_connections(opts = {})
|
|
1421
|
+
data, _status_code, _headers = list_team_connections_with_http_info(opts)
|
|
1422
|
+
data
|
|
1423
|
+
end
|
|
1424
|
+
|
|
1425
|
+
# List team connections.
|
|
1426
|
+
#
|
|
1427
|
+
# Returns all team connections.
|
|
1428
|
+
#
|
|
1429
|
+
# @param opts [Hash] the optional parameters
|
|
1430
|
+
# @option opts [Integer] :page_size Size for a given page. The maximum allowed value is 100.
|
|
1431
|
+
# @option opts [Integer] :page_number Specific page number to return.
|
|
1432
|
+
# @option opts [Array<String>] :filter_sources Filter team connections by external source systems.
|
|
1433
|
+
# @option opts [Array<String>] :filter_team_ids Filter team connections by Datadog team IDs.
|
|
1434
|
+
# @option opts [Array<String>] :filter_connected_team_ids Filter team connections by connected team IDs from external systems.
|
|
1435
|
+
# @option opts [Array<String>] :filter_connection_ids Filter team connections by connection IDs.
|
|
1436
|
+
# @return [Array<(TeamConnectionsResponse, Integer, Hash)>] TeamConnectionsResponse data, response status code and response headers
|
|
1437
|
+
def list_team_connections_with_http_info(opts = {})
|
|
1438
|
+
unstable_enabled = @api_client.config.unstable_operations["v2.list_team_connections".to_sym]
|
|
1439
|
+
if unstable_enabled
|
|
1440
|
+
@api_client.config.logger.warn format("Using unstable operation '%s'", "v2.list_team_connections")
|
|
1441
|
+
else
|
|
1442
|
+
raise DatadogAPIClient::APIError.new(message: format("Unstable operation '%s' is disabled", "v2.list_team_connections"))
|
|
1443
|
+
end
|
|
1444
|
+
|
|
1445
|
+
if @api_client.config.debugging
|
|
1446
|
+
@api_client.config.logger.debug 'Calling API: TeamsAPI.list_team_connections ...'
|
|
1447
|
+
end
|
|
1448
|
+
# resource path
|
|
1449
|
+
local_var_path = '/api/v2/team/connections'
|
|
1450
|
+
|
|
1451
|
+
# query parameters
|
|
1452
|
+
query_params = opts[:query_params] || {}
|
|
1453
|
+
query_params[:'page[size]'] = opts[:'page_size'] if !opts[:'page_size'].nil?
|
|
1454
|
+
query_params[:'page[number]'] = opts[:'page_number'] if !opts[:'page_number'].nil?
|
|
1455
|
+
query_params[:'filter[sources]'] = @api_client.build_collection_param(opts[:'filter_sources'], :csv) if !opts[:'filter_sources'].nil?
|
|
1456
|
+
query_params[:'filter[team_ids]'] = @api_client.build_collection_param(opts[:'filter_team_ids'], :csv) if !opts[:'filter_team_ids'].nil?
|
|
1457
|
+
query_params[:'filter[connected_team_ids]'] = @api_client.build_collection_param(opts[:'filter_connected_team_ids'], :csv) if !opts[:'filter_connected_team_ids'].nil?
|
|
1458
|
+
query_params[:'filter[connection_ids]'] = @api_client.build_collection_param(opts[:'filter_connection_ids'], :csv) if !opts[:'filter_connection_ids'].nil?
|
|
1459
|
+
|
|
1460
|
+
# header parameters
|
|
1461
|
+
header_params = opts[:header_params] || {}
|
|
1462
|
+
# HTTP header 'Accept' (if needed)
|
|
1463
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
1464
|
+
|
|
1465
|
+
# form parameters
|
|
1466
|
+
form_params = opts[:form_params] || {}
|
|
1467
|
+
|
|
1468
|
+
# http body (model)
|
|
1469
|
+
post_body = opts[:debug_body]
|
|
1470
|
+
|
|
1471
|
+
# return_type
|
|
1472
|
+
return_type = opts[:debug_return_type] || 'TeamConnectionsResponse'
|
|
1473
|
+
|
|
1474
|
+
# auth_names
|
|
1475
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
|
|
1476
|
+
|
|
1477
|
+
new_options = opts.merge(
|
|
1478
|
+
:operation => :list_team_connections,
|
|
1479
|
+
:header_params => header_params,
|
|
1480
|
+
:query_params => query_params,
|
|
1481
|
+
:form_params => form_params,
|
|
1482
|
+
:body => post_body,
|
|
1483
|
+
:auth_names => auth_names,
|
|
1484
|
+
:return_type => return_type,
|
|
1485
|
+
:api_version => "V2"
|
|
1486
|
+
)
|
|
1487
|
+
|
|
1488
|
+
data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
|
|
1489
|
+
if @api_client.config.debugging
|
|
1490
|
+
@api_client.config.logger.debug "API called: TeamsAPI#list_team_connections\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1491
|
+
end
|
|
1492
|
+
return data, status_code, headers
|
|
1493
|
+
end
|
|
1494
|
+
|
|
1495
|
+
# List team connections.
|
|
1496
|
+
#
|
|
1497
|
+
# Provide a paginated version of {#list_team_connections}, returning all items.
|
|
1498
|
+
#
|
|
1499
|
+
# To use it you need to use a block: list_team_connections_with_pagination { |item| p item }
|
|
1500
|
+
#
|
|
1501
|
+
# @yield [TeamConnection] Paginated items
|
|
1502
|
+
def list_team_connections_with_pagination(opts = {})
|
|
1503
|
+
api_version = "V2"
|
|
1504
|
+
page_size = @api_client.get_attribute_from_path(opts, "page_size", 10)
|
|
1505
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_size", Integer, page_size)
|
|
1506
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_number", Integer, 0)
|
|
1507
|
+
while true do
|
|
1508
|
+
response = list_team_connections(opts)
|
|
1509
|
+
@api_client.get_attribute_from_path(response, "data").each { |item| yield(item) }
|
|
1510
|
+
if @api_client.get_attribute_from_path(response, "data").length < page_size
|
|
1511
|
+
break
|
|
1512
|
+
end
|
|
1513
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_number", Integer, @api_client.get_attribute_from_path(opts, "page_number", 0) + 1)
|
|
1514
|
+
end
|
|
1515
|
+
end
|
|
1516
|
+
|
|
1517
|
+
# Get team hierarchy links.
|
|
1518
|
+
#
|
|
1519
|
+
# @see #list_team_hierarchy_links_with_http_info
|
|
1520
|
+
def list_team_hierarchy_links(opts = {})
|
|
1521
|
+
data, _status_code, _headers = list_team_hierarchy_links_with_http_info(opts)
|
|
1522
|
+
data
|
|
1523
|
+
end
|
|
1524
|
+
|
|
1525
|
+
# Get team hierarchy links.
|
|
1526
|
+
#
|
|
1527
|
+
# List all team hierarchy links that match the provided filters.
|
|
1528
|
+
#
|
|
1529
|
+
# @param opts [Hash] the optional parameters
|
|
1530
|
+
# @option opts [Integer] :page_number Specific page number to return.
|
|
1531
|
+
# @option opts [Integer] :page_size Size for a given page. The maximum allowed value is 100.
|
|
1532
|
+
# @option opts [String] :filter_parent_team Filter by parent team ID
|
|
1533
|
+
# @option opts [String] :filter_sub_team Filter by sub team ID
|
|
1534
|
+
# @return [Array<(TeamHierarchyLinksResponse, Integer, Hash)>] TeamHierarchyLinksResponse data, response status code and response headers
|
|
1535
|
+
def list_team_hierarchy_links_with_http_info(opts = {})
|
|
1536
|
+
|
|
1537
|
+
if @api_client.config.debugging
|
|
1538
|
+
@api_client.config.logger.debug 'Calling API: TeamsAPI.list_team_hierarchy_links ...'
|
|
1539
|
+
end
|
|
1540
|
+
# resource path
|
|
1541
|
+
local_var_path = '/api/v2/team-hierarchy-links'
|
|
1542
|
+
|
|
1543
|
+
# query parameters
|
|
1544
|
+
query_params = opts[:query_params] || {}
|
|
1545
|
+
query_params[:'page[number]'] = opts[:'page_number'] if !opts[:'page_number'].nil?
|
|
1546
|
+
query_params[:'page[size]'] = opts[:'page_size'] if !opts[:'page_size'].nil?
|
|
1547
|
+
query_params[:'filter[parent_team]'] = opts[:'filter_parent_team'] if !opts[:'filter_parent_team'].nil?
|
|
1548
|
+
query_params[:'filter[sub_team]'] = opts[:'filter_sub_team'] if !opts[:'filter_sub_team'].nil?
|
|
1549
|
+
|
|
1550
|
+
# header parameters
|
|
1551
|
+
header_params = opts[:header_params] || {}
|
|
1552
|
+
# HTTP header 'Accept' (if needed)
|
|
1553
|
+
header_params['Accept'] = @api_client.select_header_accept(['application/json'])
|
|
1554
|
+
|
|
1555
|
+
# form parameters
|
|
1556
|
+
form_params = opts[:form_params] || {}
|
|
1557
|
+
|
|
1558
|
+
# http body (model)
|
|
1559
|
+
post_body = opts[:debug_body]
|
|
1560
|
+
|
|
1561
|
+
# return_type
|
|
1562
|
+
return_type = opts[:debug_return_type] || 'TeamHierarchyLinksResponse'
|
|
1563
|
+
|
|
1564
|
+
# auth_names
|
|
1565
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
|
|
1566
|
+
|
|
1567
|
+
new_options = opts.merge(
|
|
1568
|
+
:operation => :list_team_hierarchy_links,
|
|
1569
|
+
:header_params => header_params,
|
|
1570
|
+
:query_params => query_params,
|
|
1571
|
+
:form_params => form_params,
|
|
1572
|
+
:body => post_body,
|
|
1573
|
+
:auth_names => auth_names,
|
|
1574
|
+
:return_type => return_type,
|
|
1575
|
+
:api_version => "V2"
|
|
1576
|
+
)
|
|
1577
|
+
|
|
1578
|
+
data, status_code, headers = @api_client.call_api(Net::HTTP::Get, local_var_path, new_options)
|
|
1579
|
+
if @api_client.config.debugging
|
|
1580
|
+
@api_client.config.logger.debug "API called: TeamsAPI#list_team_hierarchy_links\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1581
|
+
end
|
|
1582
|
+
return data, status_code, headers
|
|
1583
|
+
end
|
|
1584
|
+
|
|
1585
|
+
# Get team hierarchy links.
|
|
1586
|
+
#
|
|
1587
|
+
# Provide a paginated version of {#list_team_hierarchy_links}, returning all items.
|
|
1588
|
+
#
|
|
1589
|
+
# To use it you need to use a block: list_team_hierarchy_links_with_pagination { |item| p item }
|
|
1590
|
+
#
|
|
1591
|
+
# @yield [TeamHierarchyLink] Paginated items
|
|
1592
|
+
def list_team_hierarchy_links_with_pagination(opts = {})
|
|
1593
|
+
api_version = "V2"
|
|
1594
|
+
page_size = @api_client.get_attribute_from_path(opts, "page_size", 10)
|
|
1595
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_size", Integer, page_size)
|
|
1596
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_number", Integer, 0)
|
|
1597
|
+
while true do
|
|
1598
|
+
response = list_team_hierarchy_links(opts)
|
|
1599
|
+
@api_client.get_attribute_from_path(response, "data").each { |item| yield(item) }
|
|
1600
|
+
if @api_client.get_attribute_from_path(response, "data").length < page_size
|
|
1601
|
+
break
|
|
1602
|
+
end
|
|
1603
|
+
@api_client.set_attribute_from_path(api_version, opts, "page_number", Integer, @api_client.get_attribute_from_path(opts, "page_number", 0) + 1)
|
|
1604
|
+
end
|
|
1605
|
+
end
|
|
1606
|
+
|
|
1050
1607
|
# Get all teams.
|
|
1051
1608
|
#
|
|
1052
1609
|
# @see #list_teams_with_http_info
|
|
@@ -1161,11 +1718,16 @@ module DatadogAPIClient::V2
|
|
|
1161
1718
|
#
|
|
1162
1719
|
# Remove a super team's member team identified by `member_team_id`.
|
|
1163
1720
|
#
|
|
1721
|
+
# **Note**: This API is deprecated. For deleting team hierarchy links, use the team hierarchy links API: `DELETE /api/v2/team-hierarchy-links/{link_id}`.
|
|
1722
|
+
#
|
|
1723
|
+
# @deprecated This API is deprecated.
|
|
1724
|
+
#
|
|
1164
1725
|
# @param super_team_id [String] None
|
|
1165
1726
|
# @param member_team_id [String] None
|
|
1166
1727
|
# @param opts [Hash] the optional parameters
|
|
1167
1728
|
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
1168
1729
|
def remove_member_team_with_http_info(super_team_id, member_team_id, opts = {})
|
|
1730
|
+
warn "[DEPRECATION] `RemoveMemberTeam` is deprecated."
|
|
1169
1731
|
unstable_enabled = @api_client.config.unstable_operations["v2.remove_member_team".to_sym]
|
|
1170
1732
|
if unstable_enabled
|
|
1171
1733
|
@api_client.config.logger.warn format("Using unstable operation '%s'", "v2.remove_member_team")
|
|
@@ -1225,6 +1787,71 @@ module DatadogAPIClient::V2
|
|
|
1225
1787
|
return data, status_code, headers
|
|
1226
1788
|
end
|
|
1227
1789
|
|
|
1790
|
+
# Remove a team hierarchy link.
|
|
1791
|
+
#
|
|
1792
|
+
# @see #remove_team_hierarchy_link_with_http_info
|
|
1793
|
+
def remove_team_hierarchy_link(link_id, opts = {})
|
|
1794
|
+
remove_team_hierarchy_link_with_http_info(link_id, opts)
|
|
1795
|
+
nil
|
|
1796
|
+
end
|
|
1797
|
+
|
|
1798
|
+
# Remove a team hierarchy link.
|
|
1799
|
+
#
|
|
1800
|
+
# Remove a team hierarchy link by the given link_id.
|
|
1801
|
+
#
|
|
1802
|
+
# @param link_id [String] The team hierarchy link's identifier
|
|
1803
|
+
# @param opts [Hash] the optional parameters
|
|
1804
|
+
# @return [Array<(nil, Integer, Hash)>] nil, response status code and response headers
|
|
1805
|
+
def remove_team_hierarchy_link_with_http_info(link_id, opts = {})
|
|
1806
|
+
|
|
1807
|
+
if @api_client.config.debugging
|
|
1808
|
+
@api_client.config.logger.debug 'Calling API: TeamsAPI.remove_team_hierarchy_link ...'
|
|
1809
|
+
end
|
|
1810
|
+
# verify the required parameter 'link_id' is set
|
|
1811
|
+
if @api_client.config.client_side_validation && link_id.nil?
|
|
1812
|
+
fail ArgumentError, "Missing the required parameter 'link_id' when calling TeamsAPI.remove_team_hierarchy_link"
|
|
1813
|
+
end
|
|
1814
|
+
# resource path
|
|
1815
|
+
local_var_path = '/api/v2/team-hierarchy-links/{link_id}'.sub('{link_id}', CGI.escape(link_id.to_s).gsub('%2F', '/'))
|
|
1816
|
+
|
|
1817
|
+
# query parameters
|
|
1818
|
+
query_params = opts[:query_params] || {}
|
|
1819
|
+
|
|
1820
|
+
# header parameters
|
|
1821
|
+
header_params = opts[:header_params] || {}
|
|
1822
|
+
# HTTP header 'Accept' (if needed)
|
|
1823
|
+
header_params['Accept'] = @api_client.select_header_accept(['*/*'])
|
|
1824
|
+
|
|
1825
|
+
# form parameters
|
|
1826
|
+
form_params = opts[:form_params] || {}
|
|
1827
|
+
|
|
1828
|
+
# http body (model)
|
|
1829
|
+
post_body = opts[:debug_body]
|
|
1830
|
+
|
|
1831
|
+
# return_type
|
|
1832
|
+
return_type = opts[:debug_return_type]
|
|
1833
|
+
|
|
1834
|
+
# auth_names
|
|
1835
|
+
auth_names = opts[:debug_auth_names] || [:apiKeyAuth, :appKeyAuth, :AuthZ]
|
|
1836
|
+
|
|
1837
|
+
new_options = opts.merge(
|
|
1838
|
+
:operation => :remove_team_hierarchy_link,
|
|
1839
|
+
:header_params => header_params,
|
|
1840
|
+
:query_params => query_params,
|
|
1841
|
+
:form_params => form_params,
|
|
1842
|
+
:body => post_body,
|
|
1843
|
+
:auth_names => auth_names,
|
|
1844
|
+
:return_type => return_type,
|
|
1845
|
+
:api_version => "V2"
|
|
1846
|
+
)
|
|
1847
|
+
|
|
1848
|
+
data, status_code, headers = @api_client.call_api(Net::HTTP::Delete, local_var_path, new_options)
|
|
1849
|
+
if @api_client.config.debugging
|
|
1850
|
+
@api_client.config.logger.debug "API called: TeamsAPI#remove_team_hierarchy_link\nData: #{data.inspect}\nStatus code: #{status_code}\nHeaders: #{headers}"
|
|
1851
|
+
end
|
|
1852
|
+
return data, status_code, headers
|
|
1853
|
+
end
|
|
1854
|
+
|
|
1228
1855
|
# Link Teams with GitHub Teams.
|
|
1229
1856
|
#
|
|
1230
1857
|
# @see #sync_teams_with_http_info
|
|
@@ -1245,7 +1872,7 @@ module DatadogAPIClient::V2
|
|
|
1245
1872
|
# [A GitHub organization must be connected to your Datadog account](https://docs.datadoghq.com/integrations/github/),
|
|
1246
1873
|
# and the GitHub App integrated with Datadog must have the `Members Read` permission. Matching is performed by comparing the Datadog team handle to the GitHub team slug
|
|
1247
1874
|
# using a normalized exact match; case is ignored and spaces are removed. No modifications are made
|
|
1248
|
-
# to teams in GitHub. This
|
|
1875
|
+
# to teams in GitHub. This only creates new teams in Datadog when type is set to `provision`.
|
|
1249
1876
|
#
|
|
1250
1877
|
# @param body [TeamSyncRequest]
|
|
1251
1878
|
# @param opts [Hash] the optional parameters
|